Monado OpenXR Runtime
Context Class Referencefinal
Inheritance diagram for Context:
Collaboration diagram for Context:

Public Member Functions

void maybe_run_frame (uint64_t new_frame)
 
void add_haptic_event (vr::VREvent_HapticVibration_t event)
 
void Log (const char *pchLogMessage) override
 
void * GetGenericInterface (const char *pchInterfaceVersion, vr::EVRInitError *peError) override
 
vr::DriverHandle_t GetDriverHandle () override
 
bool TrackedDeviceAdded (const char *pchDeviceSerialNumber, vr::ETrackedDeviceClass eDeviceClass, vr::ITrackedDeviceServerDriver *pDriver) override
 
void TrackedDevicePoseUpdated (uint32_t unWhichDevice, const vr::DriverPose_t &newPose, uint32_t unPoseStructSize) override
 
void VsyncEvent (double vsyncTimeOffsetSeconds) override
 
void VendorSpecificEvent (uint32_t unWhichDevice, vr::EVREventType eventType, const vr::VREvent_Data_t &eventData, double eventTimeOffset) override
 
bool IsExiting () override
 
bool PollNextEvent (vr::VREvent_t *pEvent, uint32_t uncbVREvent) override
 
void GetRawTrackedDevicePoses (float fPredictedSecondsFromNow, vr::TrackedDevicePose_t *pTrackedDevicePoseArray, uint32_t unTrackedDevicePoseArrayCount) override
 
void RequestRestart (const char *pchLocalizedReason, const char *pchExecutableToStart, const char *pchArguments, const char *pchWorkingDirectory) override
 
uint32_t GetFrameTimings (vr::Compositor_FrameTiming *pTiming, uint32_t nFrames) override
 
void SetDisplayEyeToHead (uint32_t unWhichDevice, const vr::HmdMatrix34_t &eyeToHeadLeft, const vr::HmdMatrix34_t &eyeToHeadRight) override
 
void SetDisplayProjectionRaw (uint32_t unWhichDevice, const vr::HmdRect2_t &eyeLeft, const vr::HmdRect2_t &eyeRight) override
 
void SetRecommendedRenderTargetSize (uint32_t unWhichDevice, uint32_t nWidth, uint32_t nHeight) override
 
vr::EVRInputError CreateBooleanComponent (vr::PropertyContainerHandle_t ulContainer, const char *pchName, vr::VRInputComponentHandle_t *pHandle) override
 
vr::EVRInputError UpdateBooleanComponent (vr::VRInputComponentHandle_t ulComponent, bool bNewValue, double fTimeOffset) override
 
vr::EVRInputError CreateScalarComponent (vr::PropertyContainerHandle_t ulContainer, const char *pchName, vr::VRInputComponentHandle_t *pHandle, vr::EVRScalarType eType, vr::EVRScalarUnits eUnits) override
 
vr::EVRInputError UpdateScalarComponent (vr::VRInputComponentHandle_t ulComponent, float fNewValue, double fTimeOffset) override
 
vr::EVRInputError CreateHapticComponent (vr::PropertyContainerHandle_t ulContainer, const char *pchName, vr::VRInputComponentHandle_t *pHandle) override
 
vr::EVRInputError CreateSkeletonComponent (vr::PropertyContainerHandle_t ulContainer, const char *pchName, const char *pchSkeletonPath, const char *pchBasePosePath, vr::EVRSkeletalTrackingLevel eSkeletalTrackingLevel, const vr::VRBoneTransform_t *pGripLimitTransforms, uint32_t unGripLimitTransformCount, vr::VRInputComponentHandle_t *pHandle) override
 
vr::EVRInputError UpdateSkeletonComponent (vr::VRInputComponentHandle_t ulComponent, vr::EVRSkeletalMotionRange eMotionRange, const vr::VRBoneTransform_t *pTransforms, uint32_t unTransformCount) override
 
vr::ETrackedPropertyError ReadPropertyBatch (vr::PropertyContainerHandle_t ulContainerHandle, vr::PropertyRead_t *pBatch, uint32_t unBatchEntryCount) override
 
vr::ETrackedPropertyError WritePropertyBatch (vr::PropertyContainerHandle_t ulContainerHandle, vr::PropertyWrite_t *pBatch, uint32_t unBatchEntryCount) override
 
const char * GetPropErrorNameFromEnum (vr::ETrackedPropertyError error) override
 
vr::PropertyContainerHandle_t TrackedDeviceToPropertyContainer (vr::TrackedDeviceIndex_t nDevice) override
 

Static Public Member Functions

static std::shared_ptr< Contextcreate (const std::string &steam_install, const std::string &steamvr_install, vr::IServerTrackedDeviceProvider *p)
 Since only the devices will live after our get_devices function is called, we make our Context a shared ptr that is owned by the devices that exist, so that it is also cleaned up by the devices that exist when they are all destroyed. More...
 

Data Fields

class HmdDevicehmd {nullptr}
 
class ControllerDevicecontroller [16] {nullptr}
 
const u_logging_level log_level
 
- Data Fields inherited from xrt_tracking_origin
char name [256]
 For debugging. More...
 
enum xrt_tracking_type type
 What can the state tracker expect from this tracking system. More...
 
struct xrt_pose offset
 Read and written to by the state-tracker using the device(s) this tracking system is tracking. More...
 

Protected Member Functions

 Context (const std::string &steam_install, const std::string &steamvr_install, u_logging_level level)
 

Member Function Documentation

◆ create()

std::shared_ptr< Context > Context::create ( const std::string &  steam_install,
const std::string &  steamvr_install,
vr::IServerTrackedDeviceProvider *  p 
)
static

Since only the devices will live after our get_devices function is called, we make our Context a shared ptr that is owned by the devices that exist, so that it is also cleaned up by the devices that exist when they are all destroyed.

References xrt_tracking_origin::name.

Referenced by steamvr_lh_get_devices().


The documentation for this class was generated from the following files: