The vrOpenVRController class is a proxy class for an OpenVRController.
You only pass the name of the OpenVR Controller to the constructor to
connect this proxy class to a controller. Controllers are named
Controller0 for the first controller, Controller1 for the second
controller and so on. The generic tracker can also be accessed and are
named GenericTracker0, GenericTracker1 and so on. Additional to functions
and signals matched to the default OpenVR Controller this class also
provides a generic interface to the OpenVRController using the same ids
as the OpenVR library.
The following buttons are defined: OVRButton_System,
OVRButton_ApplicationMenu, OVRButton_Grip, OVRButton_DPad_Left,
OVRButton_DPad_Up,OVRButton_DPad_Right, OVRButton_DPad_Down, OVRButton_A,
OVRButton_ProximitySensor,OVRButton_Axis0, OVRButton_Axis1,
OVRButton_Axis2, OVRButton_Axis3, OVRButton_Axis4.
|
__init__(name)
The constructor of the vrOpenVRController class. |
|
|
|
|
|
|
|
|
|
|
|
|
|
controllerMoved()
SIGNAL is called constantly when the controller moves. |
|
|
Vec2f
|
|
int
|
getHandRole()
Get whether this controller is detected as left or right hand. |
|
|
Vec2f
|
|
floatf
|
|
int
|
|
list of floats (32bit)
|
getWorldMatrix()
Returns the world space transformation matrix of the controller. |
|
|
|
gripPressed()
SIGNAL is called when the grip is pressed. |
|
|
|
gripReleased()
SIGNAL is called when the grip is released. |
|
|
|
handPoseStarted(poseId)
SIGNAL is called when a hand pose is detected in Hand visualization
mode. |
|
|
|
handPoseStopped(poseId)
SIGNAL is called when a hand pose stops in Hand visualization mode. |
|
|
|
handRoleChanged(role)
SIGNAL is called when the hand role has changed, after the hand model
has been loaded. |
|
|
|
handTouchContinues(touchedNodeId,
fingerId)
SIGNAL is called when the finger continues touching the node. |
|
|
|
handTouchStarted(touchedNodeId,
fingerId)
SIGNAL is called when a finger of this controller's hand has touched
a node in the scene that was made interactable with
setNodeInteractableInVR(node, True). |
|
|
|
handTouchStopped(touchedNodeId,
fingerId)
SIGNAL is called when the finger stops touching the node. |
|
|
bool
|
|
bool
|
|
bool
|
|
bool
|
|
bool
|
isHandAnimationEnabled()
Get whether the finger joints are transfomed when the user pressed or
touches buttons in Hand visualization mode. |
|
|
bool
|
isHandInteractionEnabled()
Get whether the interaction with Web engines and Touch sensors is
enabled in Hand visualization mode. |
|
|
|
|
bool
|
|
bool
|
|
bool
|
|
bool
|
|
bool
|
|
bool
|
isVisible()
Gets the visibility of the visualization (geometry or hands) of this
controller. |
|
|
|
menuButtonPressed()
SIGNAL is called when the menu button is pressed. |
|
|
|
menuButtonReleased()
SIGNAL is called when the menu button is released. |
|
|
vrNodePtr
|
pickNode()
Performs a selection along the picking axis of the controller and
returns the nearest node along the picking ray. |
|
|
tuple<vrNodePtr, Pnt3f, Vec3f, Pnt2f>
|
pickNodeEx()
Performs a selection along the picking axis of the controller and
returns the nearest node along the picking ray. |
|
|
tuple<vrNodePtr, Pnt3f, Vec3f, Pnt2f>
|
pickNodeWithFinger(fingerId)
Performs a selection with a ray emenating from the finger tip and
returns the nearest node along the picking ray. |
|
|
|
|
|
setHandAnimationEnabled(enabled)
Enables or disables transformation of finger joints when the user
pressed or touches buttons in Hand visualization mode. |
|
|
|
setHandInteractionEnabled(enabled)
Enables or disables the interaction with Web engines and Touch
sensors in Hand visualization mode. |
|
|
|
setHandRole(role)
Set this controller to left, right or undefined (no) hand role. |
|
|
|
|
|
setPickingAxis(axis)
Sets the axis used for picking on this controller. |
|
|
|
setVisible(visible)
Sets the visibility of the visualization (geometry or hands) of this
controller. |
|
|
|
setVisualizationMode(mode)
Sets how the controller should be visualized (controller geometry or
hands). |
|
|
|
|
|
|
|
touchpadPressed()
SIGNAL is called when the touchpad is pressed. |
|
|
|
touchpadReleased()
SIGNAL is called when the touchpad is released. |
|
|
|
touchpadTouched()
SIGNAL is called when the touchpad is pressed. |
|
|
|
touchpadUntouched()
SIGNAL is called when the touchpad is untouched. |
|
|
|
|
|
triggerPressed()
SIGNAL is called when the trigger is pressed. |
|
|
|
triggerReleased()
SIGNAL is called when the trigger is released. |
|
|
Inherited from vrAEBase.vrAEBase :
__reduce__ ,
addLoop ,
callAllConnected ,
connect ,
connectSignal ,
emitSignal ,
getModuleName ,
isActive ,
loop ,
recEvent ,
removeConnections ,
setActive ,
setUpdateGUIEnabled ,
subLoop
Inherited from unreachable.instance :
__new__
|