mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 09:08:47 +02:00
Stylistic updates.
This commit is contained in:
parent
f5ccf508c9
commit
9a2084425d
1 changed files with 3 additions and 2 deletions
|
@ -62,6 +62,8 @@ static const int SECOND_FOOT = 1;
|
||||||
static const int HIP = 2;
|
static const int HIP = 2;
|
||||||
static const int CHEST = 3;
|
static const int CHEST = 3;
|
||||||
|
|
||||||
|
static const float POINTING_THRESHOLD = 0.75f;
|
||||||
|
|
||||||
const char* ViveControllerManager::NAME { "OpenVR" };
|
const char* ViveControllerManager::NAME { "OpenVR" };
|
||||||
|
|
||||||
const std::map<vr::ETrackingResult, QString> TRACKING_RESULT_TO_STRING = {
|
const std::map<vr::ETrackingResult, QString> TRACKING_RESULT_TO_STRING = {
|
||||||
|
@ -810,8 +812,7 @@ void ViveControllerManager::InputDevice::handleAxisEvent(float deltaTime, uint32
|
||||||
_axisStateMap[isLeftHand ? LX : RX] = stick.x;
|
_axisStateMap[isLeftHand ? LX : RX] = stick.x;
|
||||||
_axisStateMap[isLeftHand ? LY : RY] = stick.y;
|
_axisStateMap[isLeftHand ? LY : RY] = stick.y;
|
||||||
|
|
||||||
if (stick.y > 0.75f)
|
if (stick.y > POINTING_THRESHOLD) {
|
||||||
{
|
|
||||||
// Simulate pointing gesture from the oculus controller
|
// Simulate pointing gesture from the oculus controller
|
||||||
_buttonPressedMap.insert(isLeftHand ? LEFT_INDEX_POINT : RIGHT_INDEX_POINT);
|
_buttonPressedMap.insert(isLeftHand ? LEFT_INDEX_POINT : RIGHT_INDEX_POINT);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue