mirror of
https://github.com/overte-org/overte.git
synced 2025-06-18 22:20:57 +02:00
fix viveControllerManager not registering the vive input is no hand controllers are present
This commit is contained in:
parent
068b93fc30
commit
039abff861
1 changed files with 2 additions and 2 deletions
|
@ -274,13 +274,13 @@ void ViveControllerManager::pluginUpdate(float deltaTime, const controller::Inpu
|
||||||
_inputDevice->update(deltaTime, inputCalibrationData);
|
_inputDevice->update(deltaTime, inputCalibrationData);
|
||||||
});
|
});
|
||||||
|
|
||||||
if (_inputDevice->_trackedControllers == 0 && _registeredWithInputMapper) {
|
if (isDesktopMode() && _registeredWithInputMapper) {
|
||||||
userInputMapper->removeDevice(_inputDevice->_deviceID);
|
userInputMapper->removeDevice(_inputDevice->_deviceID);
|
||||||
_registeredWithInputMapper = false;
|
_registeredWithInputMapper = false;
|
||||||
_inputDevice->_poseStateMap.clear();
|
_inputDevice->_poseStateMap.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!_registeredWithInputMapper && _inputDevice->_trackedControllers > 0) {
|
if (!_registeredWithInputMapper && !isDesktopMode()) {
|
||||||
userInputMapper->registerDevice(_inputDevice);
|
userInputMapper->registerDevice(_inputDevice);
|
||||||
_registeredWithInputMapper = true;
|
_registeredWithInputMapper = true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue