mirror of
https://github.com/overte-org/overte.git
synced 2025-06-16 01:40:25 +02:00
Fix Valve Index Controller trackpad regression
This commit is contained in:
parent
3184e9373a
commit
a6c59ad75d
2 changed files with 6 additions and 2 deletions
|
@ -2070,10 +2070,14 @@ controller::Input::NamedVector ViveControllerManager::InputDevice::getAvailableI
|
||||||
QString ViveControllerManager::InputDevice::getDefaultMappingConfig() const {
|
QString ViveControllerManager::InputDevice::getDefaultMappingConfig() const {
|
||||||
QString name(getOpenVrDeviceName().c_str());
|
QString name(getOpenVrDeviceName().c_str());
|
||||||
QString MAPPING_JSON;
|
QString MAPPING_JSON;
|
||||||
if (name.contains(QString("HTC")) || name.contains(QString("Vive"))) {
|
// Workaround for having to press the thumbstick to be able to move.
|
||||||
|
// On HTC Vive wands we want to need to press the touchpad to move.
|
||||||
|
// On Valve Index controllers the thumbsticks don't need to be pressed, but the touchpad does. Valve seems to have already thought of this.
|
||||||
|
if (name.contains(QString("HTC")) || name.contains(QString("Vive")) || name.contains(QString("Valve"))) {
|
||||||
MAPPING_JSON = PathUtils::resourcesPath() + "/controllers/vive.json";
|
MAPPING_JSON = PathUtils::resourcesPath() + "/controllers/vive.json";
|
||||||
|
// Other HMDs need a different mapping to not need the thumbstick to be pressed.
|
||||||
} else {
|
} else {
|
||||||
MAPPING_JSON = PathUtils::resourcesPath() + "/controllers/index.json";
|
MAPPING_JSON = PathUtils::resourcesPath() + "/controllers/openvr_alternative.json";
|
||||||
}
|
}
|
||||||
return MAPPING_JSON;
|
return MAPPING_JSON;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue