History

Merge branch 'master' of https://github.com/worklist/hifi into 19494

stojce committed 12 years ago

Commit d5b87fb2 parents ab4164a 04cda4c22 files · +231 −292Browse files

Showing the changes to interface/src/Application.cpp (1 of 22 files). Show all

Unified · Split

interface/src/Application.cpp+26−14
@@ -2180,15 +2180,6 @@ void Application::updateThreads(float deltaTime) { · 2179 unmodified lines
2180 }2180 }
2181}2181}
2182 2182
2183void Application::updateParticles(float deltaTime) {
2184 bool showWarnings = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);
2185 PerformanceWarning warn(showWarnings, "Application::updateParticles()");
2186
2187 if (Menu::getInstance()->isOptionChecked(MenuOption::ParticleCloud)) {
2188 _cloud.simulate(deltaTime);
2189 }
2190}
2191
2192void Application::updateMetavoxels(float deltaTime) {2183void Application::updateMetavoxels(float deltaTime) {
2193 bool showWarnings = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);2184 bool showWarnings = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);
2194 PerformanceWarning warn(showWarnings, "Application::updateMetavoxels()");2185 PerformanceWarning warn(showWarnings, "Application::updateMetavoxels()");
@@ -2310,7 +2301,6 @@ void Application::update(float deltaTime) { · 115 unmodified lines
2310 updateMyAvatar(deltaTime); // Sample hardware, update view frustum if needed, and send avatar data to mixer/nodes2301 updateMyAvatar(deltaTime); // Sample hardware, update view frustum if needed, and send avatar data to mixer/nodes
2311 updateThreads(deltaTime); // If running non-threaded, then give the threads some time to process...2302 updateThreads(deltaTime); // If running non-threaded, then give the threads some time to process...
2312 _avatarManager.updateOtherAvatars(deltaTime); //loop through all the other avatars and simulate them...2303 _avatarManager.updateOtherAvatars(deltaTime); //loop through all the other avatars and simulate them...
2313 updateParticles(deltaTime); // Simulate particle cloud movements
2314 updateMetavoxels(deltaTime); // update metavoxels2304 updateMetavoxels(deltaTime); // update metavoxels
2315 updateCamera(deltaTime); // handle various camera tweaks like off axis projection2305 updateCamera(deltaTime); // handle various camera tweaks like off axis projection
2316 updateDialogs(deltaTime); // update various stats dialogs if present2306 updateDialogs(deltaTime); // update various stats dialogs if present
@@ -2745,10 +2735,6 @@ void Application::displaySide(Camera& whichCamera, bool selfAvatarOnly) { · 428 unmodified lines
2745 // disable specular lighting for ground and voxels2735 // disable specular lighting for ground and voxels
2746 glMaterialfv(GL_FRONT, GL_SPECULAR, NO_SPECULAR_COLOR);2736 glMaterialfv(GL_FRONT, GL_SPECULAR, NO_SPECULAR_COLOR);
2747 2737
2748 // Draw Cloud Particles
2749 if (Menu::getInstance()->isOptionChecked(MenuOption::ParticleCloud)) {
2750 _cloud.render();
2751 }
2752 // Draw voxels2738 // Draw voxels
2753 if (Menu::getInstance()->isOptionChecked(MenuOption::Voxels)) {2739 if (Menu::getInstance()->isOptionChecked(MenuOption::Voxels)) {
2754 PerformanceWarning warn(Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings),2740 PerformanceWarning warn(Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings),
@@ -4032,6 +4018,32 @@ void Application::saveScripts() { · 1277 unmodified lines
4032 settings->endArray();4018 settings->endArray();
4033}4019}
4034 4020
4021void Application::stopAllScripts() {
4022 // stops all current running scripts
4023 QList<QAction*> scriptActions = Menu::getInstance()->getActiveScriptsMenu()->actions();
4024 foreach (QAction* scriptAction, scriptActions) {
4025 scriptAction->activate(QAction::Trigger);
4026 qDebug() << "stopping script..." << scriptAction->text();
4027 }
4028 _activeScripts.clear();
4029}
4030
4031void Application::reloadAllScripts() {
4032 // remember all the current scripts so we can reload them
4033 QStringList reloadList = _activeScripts;
4034 // reloads all current running scripts
4035 QList<QAction*> scriptActions = Menu::getInstance()->getActiveScriptsMenu()->actions();
4036 foreach (QAction* scriptAction, scriptActions) {
4037 scriptAction->activate(QAction::Trigger);
4038 qDebug() << "stopping script..." << scriptAction->text();
4039 }
4040 _activeScripts.clear();
4041 foreach (QString scriptName, reloadList){
4042 qDebug() << "reloading script..." << scriptName;
4043 loadScript(scriptName);
4044 }
4045}
4046
4035void Application::removeScriptName(const QString& fileNameString) {4047void Application::removeScriptName(const QString& fileNameString) {
4036 _activeScripts.removeOne(fileNameString);4048 _activeScripts.removeOne(fileNameString);
4037}4049}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t