Revert "Merge pull request #9151 from hyperlogic/bug-fix/reset-sensor-in-desktop-mode"

This reverts commit 119653bceb, reversing
changes made to a69d77ffbe.
This commit is contained in:
Anthony J. Thibault 2016-12-05 15:16:49 -08:00
parent 119653bceb
commit e8b5b56df7
3 changed files with 4 additions and 8 deletions

View file

@ -4733,13 +4733,13 @@ void Application::renderRearViewMirror(RenderArgs* renderArgs, const QRect& regi
renderArgs->_viewport = originalViewport;
}
void Application::resetSensors(bool andRecenter) {
void Application::resetSensors(bool andReload) {
DependencyManager::get<Faceshift>()->reset();
DependencyManager::get<DdeFaceTracker>()->reset();
DependencyManager::get<EyeTracker>()->reset();
getActiveDisplayPlugin()->resetSensors();
_overlayConductor.centerUI();
getMyAvatar()->reset(andRecenter);
getMyAvatar()->reset(andReload);
QMetaObject::invokeMethod(DependencyManager::get<AudioClient>().data(), "reset", Qt::QueuedConnection);
}

View file

@ -317,7 +317,7 @@ public slots:
void openUrl(const QUrl& url) const;
void resetSensors(bool andRecenter = false);
void resetSensors(bool andReload = false);
void setActiveFaceTracker() const;
#if (PR_BUILD || DEV_BUILD)

View file

@ -254,10 +254,6 @@ void MyAvatar::centerBody() {
return;
}
if (!qApp->isHMDMode()) {
return;
}
// derive the desired body orientation from the current hmd orientation, before the sensor reset.
auto newBodySensorMatrix = deriveBodyFromHMDSensor(); // Based on current cached HMD position/rotation..
@ -312,7 +308,7 @@ void MyAvatar::reset(bool andRecenter, bool andReload, bool andHead) {
}
setThrust(glm::vec3(0.0f));
if (andRecenter && qApp->isHMDMode()) {
if (andRecenter) {
// derive the desired body orientation from the *old* hmd orientation, before the sensor reset.
auto newBodySensorMatrix = deriveBodyFromHMDSensor(); // Based on current cached HMD position/rotation..