History

Merge branch 'master' of github.com:highfidelity/hifi into avatars-can-collide

Seth Alves committed 11 years ago

Commit a254f012 parents 8eec66c 0a7429169 files · +157 −25330Browse files

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

Unified · Split

interface/src/Application.cpp+8−30
@@ -52,6 +52,7 @@ · 51 unmodified lines
5252 #include <QMediaPlayer>
5353 #include <QMimeData>
5454 #include <QMessageBox>
55+#include <QJsonDocument>
5556
5657 #include <AddressManager.h>
5758 #include <AccountManager.h>
@@ -75,7 +76,7 @@ · 17 unmodified lines
7576 #include <PhysicsEngine.h>
7677 #include <ProgramObject.h>
7778 #include <ResourceCache.h>
78−#include <ScriptCache.h>
79+//#include <ScriptCache.h>
7980 #include <SettingHandle.h>
8081 #include <SoundCache.h>
8182 #include <TextRenderer.h>
@@ -220,7 +221,7 @@ bool setupEssentials(int& argc, char** argv) { · 138 unmodified lines
220221 auto addressManager = DependencyManager::set<AddressManager>();
221222 auto nodeList = DependencyManager::set<NodeList>(NodeType::Agent, listenPort);
222223 auto geometryCache = DependencyManager::set<GeometryCache>();
223− auto scriptCache = DependencyManager::set<ScriptCache>();
224+ //auto scriptCache = DependencyManager::set<ScriptCache>();
224225 auto soundCache = DependencyManager::set<SoundCache>();
225226 auto glowEffect = DependencyManager::set<GlowEffect>();
226227 auto faceshift = DependencyManager::set<Faceshift>();
@@ -417,8 +418,7 @@ Application::Application(int& argc, char** argv, QElapsedTimer &startup_time) : · 190 unmodified lines
417418
418419 // tell the NodeList instance who to tell the domain server we care about
419420 nodeList->addSetOfNodeTypesToNodeInterestSet(NodeSet() << NodeType::AudioMixer << NodeType::AvatarMixer
420− << NodeType::EntityServer
421− << NodeType::MetavoxelServer);
421+ << NodeType::EntityServer);
422422
423423 // connect to the packet sent signal of the _entityEditSender
424424 connect(&_entityEditSender, &EntityEditPacketSender::packetSent, this, &Application::packetSent);
@@ -601,7 +601,7 @@ Application::~Application() { · 176 unmodified lines
601601 DependencyManager::destroy<AnimationCache>();
602602 DependencyManager::destroy<TextureCache>();
603603 DependencyManager::destroy<GeometryCache>();
604− DependencyManager::destroy<ScriptCache>();
604+ //DependencyManager::destroy<ScriptCache>();
605605 DependencyManager::destroy<SoundCache>();
606606
607607 qInstallMessageHandler(NULL); // NOTE: Do this as late as possible so we continue to get our log messages
@@ -774,8 +774,9 @@ void Application::paintGL() { · 166 unmodified lines
774774
775775 {
776776 PerformanceTimer perfTimer("renderOverlay");
777+ // PrioVR will only work if renderOverlay is called, calibration is connected to Application::renderingOverlay()
778+ _applicationOverlay.renderOverlay(true);
777779 if (Menu::getInstance()->isOptionChecked(MenuOption::UserInterface)) {
778− _applicationOverlay.renderOverlay(true);
779780 _applicationOverlay.displayOverlayTexture();
780781 }
781782 }
@@ -1448,8 +1449,7 @@ void Application::sendPingPackets() { · 666 unmodified lines
14481449 QByteArray pingPacket = DependencyManager::get<NodeList>()->constructPingPacket();
14491450 controlledBroadcastToNodes(pingPacket, NodeSet()
14501451 << NodeType::EntityServer
1451− << NodeType::AudioMixer << NodeType::AvatarMixer
1452− << NodeType::MetavoxelServer);
1452+ << NodeType::AudioMixer << NodeType::AvatarMixer);
14531453 }
14541454
14551455 // Every second, check the frame rates and other stuff
@@ -1792,8 +1792,6 @@ void Application::init() { · 336 unmodified lines
17921792 _entityClipboardRenderer.setViewFrustum(getViewFrustum());
17931793 _entityClipboardRenderer.setTree(&_entityClipboard);
17941794
1795− _metavoxels.init();
1796−
17971795 _rearMirrorTools = new RearMirrorTools(_glWidget, _mirrorViewRect);
17981796
17991797 connect(_rearMirrorTools, SIGNAL(closeView()), SLOT(closeMirrorView()));
@@ -1956,16 +1954,6 @@ void Application::updateThreads(float deltaTime) { · 156 unmodified lines
19561954 }
19571955 }
19581956
1959−void Application::updateMetavoxels(float deltaTime) {
1960− PerformanceTimer perfTimer("updateMetavoxels");
1961− bool showWarnings = Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings);
1962− PerformanceWarning warn(showWarnings, "Application::updateMetavoxels()");
1963−
1964− if (Menu::getInstance()->isOptionChecked(MenuOption::Metavoxels)) {
1965− _metavoxels.simulate(deltaTime);
1966− }
1967−}
1968−
19691957 void Application::cameraMenuChanged() {
19701958 if (Menu::getInstance()->isOptionChecked(MenuOption::FullscreenMirror)) {
19711959 if (_myCamera.getMode() != CAMERA_MODE_MIRROR) {
@@ -2065,7 +2053,6 @@ void Application::update(float deltaTime) { · 93 unmodified lines
20652053
20662054 DependencyManager::get<AvatarManager>()->updateOtherAvatars(deltaTime); //loop through all the other avatars and simulate them...
20672055
2068− updateMetavoxels(deltaTime); // update metavoxels
20692056 updateCamera(deltaTime); // handle various camera tweaks like off axis projection
20702057 updateDialogs(deltaTime); // update various stats dialogs if present
20712058 updateCursor(deltaTime); // Handle cursor updates
@@ -2815,14 +2802,6 @@ void Application::displaySide(Camera& theCamera, bool selfAvatarOnly, RenderArgs · 743 unmodified lines
28152802 float originSphereRadius = 0.05f;
28162803 DependencyManager::get<GeometryCache>()->renderSphere(originSphereRadius, 15, 15, glm::vec4(1.0f, 0.0f, 0.0f, 1.0f));
28172804
2818− // also, metavoxels
2819− if (Menu::getInstance()->isOptionChecked(MenuOption::Metavoxels)) {
2820− PerformanceTimer perfTimer("metavoxels");
2821− PerformanceWarning warn(Menu::getInstance()->isOptionChecked(MenuOption::PipelineWarnings),
2822− "Application::displaySide() ... metavoxels...");
2823− _metavoxels.render();
2824− }
2825−
28262805 // render models...
28272806 if (Menu::getInstance()->isOptionChecked(MenuOption::Entities)) {
28282807 PerformanceTimer perfTimer("entities");
@@ -3499,7 +3478,6 @@ void Application::registerScriptEngineWithApplicationServices(ScriptEngine* scri · 670 unmodified lines
34993478 scriptEngine->registerGlobalObject("AnimationCache", DependencyManager::get<AnimationCache>().data());
35003479 scriptEngine->registerGlobalObject("SoundCache", DependencyManager::get<SoundCache>().data());
35013480 scriptEngine->registerGlobalObject("Account", AccountScriptingInterface::getInstance());
3502− scriptEngine->registerGlobalObject("Metavoxels", &_metavoxels);
35033481
35043482 scriptEngine->registerGlobalObject("GlobalServices", GlobalServicesScriptingInterface::getInstance());
35053483 qScriptRegisterMetaType(scriptEngine, DownloadInfoResultToScriptValue, DownloadInfoResultFromScriptValue);

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