Skip to main content

QWR API Reference

This page provides a comprehensive API reference for the DPVR Unity Plugin specifically designed for VROneEdu educational VR headset development.

QWRCameraRig​

The main camera rig component optimized for VROneEdu with educational-specific features.

Properties​

NameTypeDescription
HeadPositionVector3The current head position.
HeadRotationQuaternionThe current head rotation.
HeadVelocityVector3The current head velocity.
HeadAngularVelocityVector3The current head angular velocity.
ComfortLevelComfortLevelThe current comfort level setting.
IPDfloatThe interpupillary distance.
IsEducationalModeEnabledboolWhether educational mode is enabled.

Methods​

NameReturn TypeParametersDescription
GetHeadPosition()Vector3NoneGets the current head position.
GetHeadRotation()QuaternionNoneGets the current head rotation.
GetHeadVelocity()Vector3NoneGets the current head velocity.
GetHeadAngularVelocity()Vector3NoneGets the current head angular velocity.
SetComfortSettings(ComfortLevel level)voidlevel: The comfort level to setSets the comfort level for extended use.
GetComfortLevel()ComfortLevelNoneGets the current comfort level.
SetIPD(float ipd)voidipd: The IPD value in metersSets the interpupillary distance.
GetIPD()floatNoneGets the current IPD value.
SetEducationalMode(bool enabled)voidenabled: Whether to enable educational modeEnables educational-specific features.
SetSpatialAudio(bool enabled)voidenabled: Whether to enable spatial audioEnables or disables spatial audio.
SetUIInteraction(bool enabled)voidenabled: Whether to enable UI interactionEnables or disables UI interaction features.

Events​

NameEvent TypeDescription
OnHeadTrackingAcquiredActionTriggered when head tracking is acquired.
OnHeadTrackingLostActionTriggered when head tracking is lost.
OnComfortLevelChangedAction<ComfortLevel>Triggered when comfort level changes.

QWRController​

Controller input handling specifically designed for VROneEdu educational applications.

Properties​

NameTypeDescription
IsControllerConnectedboolWhether a controller is connected.
ControllerPositionVector3The current controller position.
ControllerRotationQuaternionThe current controller rotation.

Methods​

NameReturn TypeParametersDescription
GetButton(DPVRButton button)boolbutton: The button to checkChecks if a button is currently pressed.
GetButtonDown(DPVRButton button)boolbutton: The button to checkChecks if a button was pressed this frame.
GetButtonUp(DPVRButton button)boolbutton: The button to checkChecks if a button was released this frame.
GetAxis(DPVRAxis axis)Vector2axis: The axis to checkGets the value of a 2D axis (like touchpad).
GetAxisValue(DPVRAxis axis)floataxis: The axis to checkGets the value of a 1D axis.
TriggerHaptic(float intensity, float duration)voidintensity: Haptic intensity (0-1), duration: Duration in secondsTriggers haptic feedback.
StopHaptic()voidNoneStops all haptic feedback.
IsControllerConnected()boolNoneChecks if a controller is connected.
GetControllerPosition()Vector3NoneGets the current controller position.
GetControllerRotation()QuaternionNoneGets the current controller rotation.

Events​

NameEvent TypeDescription
OnButtonPressedAction<DPVRButton>Triggered when a button is pressed.
OnButtonReleasedAction<DPVRButton>Triggered when a button is released.
OnAxisChangedAction<DPVRAxis, Vector2>Triggered when an axis value changes.
OnControllerConnectedActionTriggered when a controller is connected.
OnControllerDisconnectedActionTriggered when a controller is disconnected.

For more detailed information about specific components, check out the following pages:


This API reference provides comprehensive information about the DPVR Unity Plugin components and APIs specifically designed for VROneEdu educational VR headset development.