History

Merge branch 'master' of github.com:highfidelity/hifi into cauterize-head-av-entities-1

Seth Alves committed 8 years ago

Commit bce9b5f2 parents 6aa389c b08f1ea65 files · +973 −847Browse files

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

Unified · Split

interface/src/Application.cpp+9−4
@@ -573,8 +573,7 @@ bool setupEssentials(int& argc, char** argv, bool runningMarkerExisted) { · 572 unmodified lines
573573 }
574574 };
575575 reportAndQuit("--protocolVersion", [&](FILE* fp) {
576− DependencyManager::set<AddressManager>();
577− auto version = DependencyManager::get<AddressManager>()->protocolVersion();
576+ auto version = protocolVersionsSignatureBase64();
578577 fputs(version.toLatin1().data(), fp);
579578 });
580579 reportAndQuit("--version", [&](FILE* fp) {
@@ -2093,6 +2092,11 @@ void Application::cleanupBeforeQuit() { · 1512 unmodified lines
20932092 DependencyManager::destroy<AudioInjectorManager>();
20942093 DependencyManager::destroy<AudioScriptingInterface>();
20952094
2095+ // The PointerManager must be destroyed before the PickManager because when a Pointer is deleted,
2096+ // it accesses the PickManager to delete its associated Pick
2097+ DependencyManager::destroy<PointerManager>();
2098+ DependencyManager::destroy<PickManager>();
2099+
20962100 qCDebug(interfaceapp) << "Application::cleanupBeforeQuit() complete";
20972101 }
20982102
@@ -4351,8 +4355,9 @@ void Application::updateLOD(float deltaTime) const { · 2252 unmodified lines
43514355 float presentTime = getActiveDisplayPlugin()->getAveragePresentTime();
43524356 float engineRunTime = (float)(_renderEngine->getConfiguration().get()->getCPURunTime());
43534357 float gpuTime = getGPUContext()->getFrameTimerGPUAverage();
4354− float maxRenderTime = glm::max(gpuTime, glm::max(presentTime, engineRunTime));
4355− DependencyManager::get<LODManager>()->autoAdjustLOD(maxRenderTime, deltaTime);
4358+ auto lodManager = DependencyManager::get<LODManager>();
4359+ lodManager->setRenderTimes(presentTime, engineRunTime, gpuTime);
4360+ lodManager->autoAdjustLOD(deltaTime);
43564361 } else {
43574362 DependencyManager::get<LODManager>()->resetLODAdjust();
43584363 }