Chaperone Tab Update (#101)

* added actions for haptics

* Haptic WIP #1 crash on haptic event

* haptics rough implemented

* fixed action names and prox sensor work-around

* added workaround to catch-all in begineer chaperone switch

* added idle work-around to alarm warning

* changed visibility slider values to reflect new API limits

* added disable chaperone

* added display Logic

* fixed visibility slider display and some saving fade distance when chaperone disabled

* fixed warnings not always working (hopefully) centralized action/input keys into ivrinput.h

* default bindings for HMD's

* chaperone input re-factor

* refactored ivrinput class

* fixed naming errors commented out prox testing

* formatting removed commented code

* format

* fixed compiler warnings

* updated documentation

* Reduced reload chaperone calls

* adjusted haptics for chaperone bounds warnings
This commit is contained in:
ykeara
2019-03-15 15:19:23 -05:00
committed by GitHub
parent 55b6d5de66
commit 3c5cab72e5
14 changed files with 425 additions and 77 deletions
@@ -78,6 +78,8 @@ class ChaperoneTabController : public QObject
setPlaySpaceMarker NOTIFY playSpaceMarkerChanged )
Q_PROPERTY( bool forceBounds READ forceBounds WRITE setForceBounds NOTIFY
forceBoundsChanged )
Q_PROPERTY( bool disableChaperone READ disableChaperone WRITE
setDisableChaperone NOTIFY disableChaperoneChanged )
Q_PROPERTY( bool chaperoneSwitchToBeginnerEnabled READ
isChaperoneSwitchToBeginnerEnabled WRITE
@@ -142,6 +144,8 @@ private:
bool m_centerMarker = false;
bool m_playSpaceMarker = false;
bool m_forceBounds = false;
bool m_disableChaperone = false;
float m_fadeDistanceRemembered = 0.0f;
bool m_enableChaperoneSwitchToBeginner = false;
float m_chaperoneSwitchToBeginnerDistance = 0.5f;
@@ -169,6 +173,16 @@ private:
unsigned settingsUpdateCounter = 0;
bool m_isHapticGood = true;
bool m_isHMDActive = false;
int m_updateTicksChaperoneReload = 0;
vr::VRActionHandle_t m_rightActionHandle;
vr::VRActionHandle_t m_leftActionHandle;
vr::VRInputValueHandle_t m_leftInputHandle;
vr::VRInputValueHandle_t m_rightInputHandle;
std::vector<ChaperoneProfile> chaperoneProfiles;
public:
@@ -189,6 +203,12 @@ public:
bool centerMarker() const;
bool playSpaceMarker() const;
bool forceBounds() const;
bool disableChaperone() const;
void setRightHapticActionHandle( vr::VRActionHandle_t handle );
void setLeftHapticActionHandle( vr::VRActionHandle_t handle );
void setRightInputHandle( vr::VRInputValueHandle_t handle );
void setLeftInputHandle( vr::VRInputValueHandle_t handle );
bool isChaperoneSwitchToBeginnerEnabled() const;
float chaperoneSwitchToBeginnerDistance() const;
@@ -223,6 +243,7 @@ public slots:
void setCenterMarker( bool value, bool notify = true );
void setPlaySpaceMarker( bool value, bool notify = true );
void setForceBounds( bool value, bool notify = true );
void setDisableChaperone( bool value, bool notify = true );
void setChaperoneSwitchToBeginnerEnabled( bool value, bool notify = true );
void setChaperoneSwitchToBeginnerDistance( float value,
@@ -270,6 +291,7 @@ signals:
void centerMarkerChanged( bool value );
void playSpaceMarkerChanged( bool value );
void forceBoundsChanged( bool value );
void disableChaperoneChanged( bool value );
void chaperoneSwitchToBeginnerEnabledChanged( bool value );
void chaperoneSwitchToBeginnerDistanceChanged( float value );