Update OpenVR to 1.6.10
This commit is contained in:
Vendored
+206
-87
@@ -15,8 +15,8 @@
|
||||
namespace vr
|
||||
{
|
||||
static const uint32_t k_nSteamVRVersionMajor = 1;
|
||||
static const uint32_t k_nSteamVRVersionMinor = 4;
|
||||
static const uint32_t k_nSteamVRVersionBuild = 18;
|
||||
static const uint32_t k_nSteamVRVersionMinor = 6;
|
||||
static const uint32_t k_nSteamVRVersionBuild = 10;
|
||||
} // namespace vr
|
||||
|
||||
// vrtypes.h
|
||||
@@ -354,6 +354,7 @@ enum ETrackedDeviceProperty
|
||||
Prop_BootloaderVersion_Uint64 = 1044,
|
||||
Prop_AdditionalSystemReportData_String = 1045, // additional string to include in system reports about a tracked device
|
||||
Prop_CompositeFirmwareVersion_String = 1046, // additional FW components from a device that gets propagated into reports
|
||||
Prop_Firmware_RemindUpdate_Bool = 1047,
|
||||
|
||||
// Properties that are unique to TrackedDeviceClass_HMD
|
||||
Prop_ReportsTimeSinceVSync_Bool = 2000,
|
||||
@@ -408,7 +409,7 @@ enum ETrackedDeviceProperty
|
||||
Prop_NamedIconPathControllerLeftDeviceOff_String = 2051, // placeholder icon for "left" controller if not yet detected/loaded
|
||||
Prop_NamedIconPathControllerRightDeviceOff_String = 2052, // placeholder icon for "right" controller if not yet detected/loaded
|
||||
Prop_NamedIconPathTrackingReferenceDeviceOff_String = 2053, // placeholder icon for sensor/base if not yet detected/loaded
|
||||
Prop_DoNotApplyPrediction_Bool = 2054,
|
||||
Prop_DoNotApplyPrediction_Bool = 2054, // currently no effect. was used to disable HMD pose prediction on MR, which is now done by MR driver setting velocity=0
|
||||
Prop_CameraToHeadTransforms_Matrix34_Array = 2055,
|
||||
Prop_DistortionMeshResolution_Int32 = 2056, // custom resolution of compositor calls to IVRSystem::ComputeDistortion
|
||||
Prop_DriverIsDrawingControllers_Bool = 2057,
|
||||
@@ -429,9 +430,14 @@ enum ETrackedDeviceProperty
|
||||
Prop_CameraDistortionFunction_Int32_Array = 2072, // Prop_NumCameras_Int32-sized array of vr::EVRDistortionFunctionType values (max size is vr::k_unMaxCameras)
|
||||
Prop_CameraDistortionCoefficients_Float_Array = 2073, // Prop_NumCameras_Int32-sized array of double[vr::k_unMaxDistortionFunctionParameters] (max size is vr::k_unMaxCameras)
|
||||
Prop_ExpectedControllerType_String = 2074,
|
||||
Prop_HmdTrackingStyle_Int32 = 2075, // one of EHmdTrackingStyle
|
||||
Prop_DriverProvidedChaperoneVisibility_Bool = 2076,
|
||||
|
||||
|
||||
Prop_DisplayAvailableFrameRates_Float_Array = 2080, // populated by compositor from actual EDID list when available from GPU driver
|
||||
Prop_DisplaySupportsMultipleFramerates_Bool = 2081, // if this is true but Prop_DisplayAvailableFrameRates_Float_Array is empty, explain to user
|
||||
Prop_DisplayColorMultLeft_Vector3 = 2082,
|
||||
Prop_DisplayColorMultRight_Vector3 = 2083,
|
||||
|
||||
Prop_DashboardLayoutPathName_String = 2090,
|
||||
|
||||
@@ -527,6 +533,15 @@ enum ETrackedPropertyError
|
||||
TrackedProp_IPCReadFailure = 13,
|
||||
};
|
||||
|
||||
/** Used to drive certain text in the UI when talking about the tracking system for the HMD */
|
||||
enum EHmdTrackingStyle
|
||||
{
|
||||
HmdTrackingStyle_Unknown = 0,
|
||||
|
||||
HmdTrackingStyle_Lighthouse = 1, // base stations and lasers
|
||||
HmdTrackingStyle_OutsideInCameras = 2, // Cameras and LED, Rift 1 style
|
||||
HmdTrackingStyle_InsideOutCameras = 3, // Cameras on HMD looking at the world
|
||||
};
|
||||
|
||||
typedef uint64_t VRActionHandle_t;
|
||||
typedef uint64_t VRActionSetHandle_t;
|
||||
@@ -1110,6 +1125,7 @@ enum EShowUIType
|
||||
// ShowUI_QuickStart = 2, // Deprecated
|
||||
ShowUI_Pairing = 3,
|
||||
ShowUI_Settings = 4,
|
||||
ShowUI_DebugCommands = 5,
|
||||
};
|
||||
|
||||
struct VREvent_ShowUI_t
|
||||
@@ -1514,6 +1530,7 @@ enum EVRInitError
|
||||
VRInitError_Init_TrackerManagerInitFailed = 142,
|
||||
VRInitError_Init_AlreadyRunning = 143,
|
||||
VRInitError_Init_FailedForVrMonitor = 144,
|
||||
VRInitError_Init_PropertyManagerInitFailed = 145,
|
||||
|
||||
VRInitError_Driver_Failed = 200,
|
||||
VRInitError_Driver_Unknown = 201,
|
||||
@@ -1539,6 +1556,8 @@ enum EVRInitError
|
||||
VRInitError_IPC_CompositorConnectFailed = 306,
|
||||
VRInitError_IPC_CompositorInvalidConnectResponse = 307,
|
||||
VRInitError_IPC_ConnectFailedAfterMultipleAttempts = 308,
|
||||
VRInitError_IPC_ConnectFailedAfterTargetExited = 309,
|
||||
VRInitError_IPC_NamespaceUnavailable = 310,
|
||||
|
||||
VRInitError_Compositor_Failed = 400,
|
||||
VRInitError_Compositor_D3D11HardwareRequired = 401,
|
||||
@@ -1625,6 +1644,8 @@ enum EVRInitError
|
||||
VRInitError_Compositor_CreateTextIndexBuffer = 482,
|
||||
VRInitError_Compositor_CreateMirrorTextures = 483,
|
||||
VRInitError_Compositor_CreateLastFrameRenderTexture = 484,
|
||||
VRInitError_Compositor_CreateMirrorOverlay = 485,
|
||||
VRInitError_Compositor_FailedToCreateVirtualDisplayBackbuffer = 486,
|
||||
|
||||
VRInitError_VendorSpecific_UnableToConnectToOculusRuntime = 1000,
|
||||
VRInitError_VendorSpecific_WindowsNotInDevMode = 1001,
|
||||
@@ -1642,6 +1663,7 @@ enum EVRInitError
|
||||
VRInitError_VendorSpecific_HmdFound_UserDataAddressRange = 1111,
|
||||
VRInitError_VendorSpecific_HmdFound_UserDataError = 1112,
|
||||
VRInitError_VendorSpecific_HmdFound_ConfigFailedSanityCheck = 1113,
|
||||
VRInitError_VendorSpecific_OculusRuntimeBadInstall = 1114,
|
||||
|
||||
VRInitError_Steam_SteamInstallationNotFound = 2000,
|
||||
|
||||
@@ -1735,6 +1757,75 @@ typedef uint32_t ScreenshotHandle_t;
|
||||
|
||||
static const uint32_t k_unScreenshotHandleInvalid = 0;
|
||||
|
||||
/** Compositor frame timing reprojection flags. */
|
||||
const uint32_t VRCompositor_ReprojectionReason_Cpu = 0x01;
|
||||
const uint32_t VRCompositor_ReprojectionReason_Gpu = 0x02;
|
||||
const uint32_t VRCompositor_ReprojectionAsync = 0x04; // This flag indicates the async reprojection mode is active,
|
||||
// but does not indicate if reprojection actually happened or not.
|
||||
// Use the ReprojectionReason flags above to check if reprojection
|
||||
// was actually applied (i.e. scene texture was reused).
|
||||
// NumFramePresents > 1 also indicates the scene texture was reused,
|
||||
// and also the number of times that it was presented in total.
|
||||
|
||||
const uint32_t VRCompositor_ReprojectionMotion = 0x08; // This flag indicates whether or not motion smoothing was triggered for this frame
|
||||
|
||||
const uint32_t VRCompositor_PredictionMask = 0x30; // The runtime may predict more than one frame (up to four) ahead if
|
||||
// it detects the application is taking too long to render. These two
|
||||
// bits will contain the count of additional frames (normally zero).
|
||||
// Use the VR_COMPOSITOR_ADDITIONAL_PREDICTED_FRAMES macro to read from
|
||||
// the latest frame timing entry.
|
||||
|
||||
const uint32_t VRCompositor_ThrottleMask = 0xC0; // Number of frames the compositor is throttling the application.
|
||||
// Use the VR_COMPOSITOR_NUMBER_OF_THROTTLED_FRAMES macro to read from
|
||||
// the latest frame timing entry.
|
||||
|
||||
#define VR_COMPOSITOR_ADDITIONAL_PREDICTED_FRAMES( timing ) ( ( ( timing ).m_nReprojectionFlags & vr::VRCompositor_PredictionMask ) >> 4 )
|
||||
#define VR_COMPOSITOR_NUMBER_OF_THROTTLED_FRAMES( timing ) ( ( ( timing ).m_nReprojectionFlags & vr::VRCompositor_ThrottleMask ) >> 6 )
|
||||
|
||||
/** Provides a single frame's timing information to the app */
|
||||
struct Compositor_FrameTiming
|
||||
{
|
||||
uint32_t m_nSize; // Set to sizeof( Compositor_FrameTiming )
|
||||
uint32_t m_nFrameIndex;
|
||||
uint32_t m_nNumFramePresents; // number of times this frame was presented
|
||||
uint32_t m_nNumMisPresented; // number of times this frame was presented on a vsync other than it was originally predicted to
|
||||
uint32_t m_nNumDroppedFrames; // number of additional times previous frame was scanned out
|
||||
uint32_t m_nReprojectionFlags;
|
||||
|
||||
/** Absolute time reference for comparing frames. This aligns with the vsync that running start is relative to. */
|
||||
double m_flSystemTimeInSeconds;
|
||||
|
||||
/** These times may include work from other processes due to OS scheduling.
|
||||
* The fewer packets of work these are broken up into, the less likely this will happen.
|
||||
* GPU work can be broken up by calling Flush. This can sometimes be useful to get the GPU started
|
||||
* processing that work earlier in the frame. */
|
||||
float m_flPreSubmitGpuMs; // time spent rendering the scene (gpu work submitted between WaitGetPoses and second Submit)
|
||||
float m_flPostSubmitGpuMs; // additional time spent rendering by application (e.g. companion window)
|
||||
float m_flTotalRenderGpuMs; // time between work submitted immediately after present (ideally vsync) until the end of compositor submitted work
|
||||
float m_flCompositorRenderGpuMs; // time spend performing distortion correction, rendering chaperone, overlays, etc.
|
||||
float m_flCompositorRenderCpuMs; // time spent on cpu submitting the above work for this frame
|
||||
float m_flCompositorIdleCpuMs; // time spent waiting for running start (application could have used this much more time)
|
||||
|
||||
/** Miscellaneous measured intervals. */
|
||||
float m_flClientFrameIntervalMs; // time between calls to WaitGetPoses
|
||||
float m_flPresentCallCpuMs; // time blocked on call to present (usually 0.0, but can go long)
|
||||
float m_flWaitForPresentCpuMs; // time spent spin-waiting for frame index to change (not near-zero indicates wait object failure)
|
||||
float m_flSubmitFrameMs; // time spent in IVRCompositor::Submit (not near-zero indicates driver issue)
|
||||
|
||||
/** The following are all relative to this frame's SystemTimeInSeconds */
|
||||
float m_flWaitGetPosesCalledMs;
|
||||
float m_flNewPosesReadyMs;
|
||||
float m_flNewFrameReadyMs; // second call to IVRCompositor::Submit
|
||||
float m_flCompositorUpdateStartMs;
|
||||
float m_flCompositorUpdateEndMs;
|
||||
float m_flCompositorRenderStartMs;
|
||||
|
||||
vr::TrackedDevicePose_t m_HmdPose; // pose used by app to render this frame
|
||||
|
||||
uint32_t m_nNumVSyncsReadyForUse;
|
||||
uint32_t m_nNumVSyncsToFirstView;
|
||||
};
|
||||
|
||||
/** Frame timing data provided by direct mode drivers. */
|
||||
struct DriverDirectMode_FrameTiming
|
||||
{
|
||||
@@ -2101,15 +2192,6 @@ public:
|
||||
* its own workload. One common way to do this is to reduce the size of the render target provided for each eye. */
|
||||
virtual bool ShouldApplicationReduceRenderingWork() = 0;
|
||||
|
||||
// ------------------------------------
|
||||
// Debug Methods
|
||||
// ------------------------------------
|
||||
|
||||
/** Sends a request to the driver for the specified device and returns the response. The maximum response size is 32k,
|
||||
* but this method can be called with a smaller buffer. If the response exceeds the size of the buffer, it is truncated.
|
||||
* The size of the response including its terminating null is returned. */
|
||||
virtual uint32_t DriverDebugRequest( vr::TrackedDeviceIndex_t unDeviceIndex, const char *pchRequest, VR_OUT_STRING() char *pchResponseBuffer, uint32_t unResponseBufferSize ) = 0;
|
||||
|
||||
// ------------------------------------
|
||||
// Firmware methods
|
||||
// ------------------------------------
|
||||
@@ -2134,9 +2216,29 @@ public:
|
||||
* prompt the user to save and then exit afterward, otherwise the user will be left in a confusing state. */
|
||||
virtual void AcknowledgeQuit_UserPrompt() = 0;
|
||||
|
||||
// -------------------------------------
|
||||
// App container sandbox methods
|
||||
// -------------------------------------
|
||||
|
||||
/** Retrieves a null-terminated, semicolon-delimited list of UTF8 file paths that an application
|
||||
* must have read access to when running inside of an app container. Returns the number of bytes
|
||||
* needed to hold the list. */
|
||||
virtual uint32_t GetAppContainerFilePaths( VR_OUT_STRING() char *pchBuffer, uint32_t unBufferSize ) = 0;
|
||||
|
||||
// -------------------------------------
|
||||
// System methods
|
||||
// -------------------------------------
|
||||
|
||||
/** Returns the current version of the SteamVR runtime. The returned string will remain valid until VR_Shutdown is called.
|
||||
*
|
||||
* NOTE: Is it not appropriate to use this version to test for the presence of any SteamVR feature. Only use this version
|
||||
* number for logging or showing to a user, and not to try to detect anything at runtime. When appropriate, feature-specific
|
||||
* presence information is provided by other APIs. */
|
||||
virtual const char *GetRuntimeVersion() = 0;
|
||||
|
||||
};
|
||||
|
||||
static const char * const IVRSystem_Version = "IVRSystem_019";
|
||||
static const char * const IVRSystem_Version = "IVRSystem_020";
|
||||
|
||||
}
|
||||
|
||||
@@ -2506,7 +2608,7 @@ namespace vr
|
||||
static const char * const k_pch_SteamVR_ActivateMultipleDrivers_Bool = "activateMultipleDrivers";
|
||||
static const char * const k_pch_SteamVR_UsingSpeakers_Bool = "usingSpeakers";
|
||||
static const char * const k_pch_SteamVR_SpeakersForwardYawOffsetDegrees_Float = "speakersForwardYawOffsetDegrees";
|
||||
static const char * const k_pch_SteamVR_BaseStationPowerManagement_Bool = "basestationPowerManagement";
|
||||
static const char * const k_pch_SteamVR_BaseStationPowerManagement_Int32 = "basestationPowerManagement";
|
||||
static const char * const k_pch_SteamVR_NeverKillProcesses_Bool = "neverKillProcesses";
|
||||
static const char * const k_pch_SteamVR_SupersampleScale_Float = "supersampleScale";
|
||||
static const char * const k_pch_SteamVR_MaxRecommendedResolution_Int32 = "maxRecommendedResolution";
|
||||
@@ -2534,13 +2636,15 @@ namespace vr
|
||||
static const char * const k_pch_SteamVR_DebugInput = "debugInput";
|
||||
static const char * const k_pch_SteamVR_DebugInputBinding = "debugInputBinding";
|
||||
static const char * const k_pch_SteamVR_DoNotFadeToGrid = "doNotFadeToGrid";
|
||||
static const char * const k_pch_SteamVR_InputBindingUIBlock = "inputBindingUI";
|
||||
static const char * const k_pch_SteamVR_RenderCameraMode = "renderCameraMode";
|
||||
static const char * const k_pch_SteamVR_EnableSharedResourceJournaling = "enableSharedResourceJournaling";
|
||||
static const char * const k_pch_SteamVR_EnableSafeMode = "enableSafeMode";
|
||||
static const char * const k_pch_SteamVR_PreferredRefreshRate = "preferredRefreshRate";
|
||||
static const char * const k_pch_SteamVR_LastVersionNotice = "lastVersionNotice";
|
||||
static const char * const k_pch_SteamVR_LastVersionNoticeDate = "lastVersionNoticeDate";
|
||||
static const char * const k_pch_SteamVR_HmdDisplayColorGainR_Float = "hmdDisplayColorGainR";
|
||||
static const char * const k_pch_SteamVR_HmdDisplayColorGainG_Float = "hmdDisplayColorGainG";
|
||||
static const char * const k_pch_SteamVR_HmdDisplayColorGainB_Float = "hmdDisplayColorGainB";
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// direct mode keys
|
||||
@@ -2678,6 +2782,7 @@ namespace vr
|
||||
//-----------------------------------------------------------------------------
|
||||
// driver keys - These could be checked in any driver_<name> section
|
||||
static const char * const k_pch_Driver_Enable_Bool = "enable";
|
||||
static const char * const k_pch_Driver_LoadPriority_Int32 = "loadPriority";
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// web interface keys
|
||||
@@ -2720,6 +2825,14 @@ namespace vr
|
||||
// Dismissed warnings
|
||||
static const char * const k_pch_DismissedWarnings_Section = "DismissedWarnings";
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Input Settings
|
||||
static const char * const k_pch_Input_Section = "input";
|
||||
static const char* const k_pch_Input_LeftThumbstickRotation_Float = "leftThumbstickRotation";
|
||||
static const char* const k_pch_Input_RightThumbstickRotation_Float = "rightThumbstickRotation";
|
||||
static const char* const k_pch_Input_ThumbstickDeadzone_Float = "thumbstickDeadzone";
|
||||
|
||||
|
||||
} // namespace vr
|
||||
|
||||
// ivrchaperone.h
|
||||
@@ -2922,74 +3035,6 @@ enum EVRCompositorTimingMode
|
||||
VRCompositorTimingMode_Explicit_ApplicationPerformsPostPresentHandoff = 2,
|
||||
};
|
||||
|
||||
const uint32_t VRCompositor_ReprojectionReason_Cpu = 0x01;
|
||||
const uint32_t VRCompositor_ReprojectionReason_Gpu = 0x02;
|
||||
const uint32_t VRCompositor_ReprojectionAsync = 0x04; // This flag indicates the async reprojection mode is active,
|
||||
// but does not indicate if reprojection actually happened or not.
|
||||
// Use the ReprojectionReason flags above to check if reprojection
|
||||
// was actually applied (i.e. scene texture was reused).
|
||||
// NumFramePresents > 1 also indicates the scene texture was reused,
|
||||
// and also the number of times that it was presented in total.
|
||||
|
||||
const uint32_t VRCompositor_ReprojectionMotion = 0x08; // This flag indicates whether or not motion smoothing was triggered for this frame
|
||||
|
||||
const uint32_t VRCompositor_PredictionMask = 0x30; // The runtime may predict more than one frame (up to four) ahead if
|
||||
// it detects the application is taking too long to render. These two
|
||||
// bits will contain the count of additional frames (normally zero).
|
||||
// Use the VR_COMPOSITOR_ADDITIONAL_PREDICTED_FRAMES macro to read from
|
||||
// the latest frame timing entry.
|
||||
|
||||
const uint32_t VRCompositor_ThrottleMask = 0xC0; // Number of frames the compositor is throttling the application.
|
||||
// Use the VR_COMPOSITOR_NUMBER_OF_THROTTLED_FRAMES macro to read from
|
||||
// the latest frame timing entry.
|
||||
|
||||
#define VR_COMPOSITOR_ADDITIONAL_PREDICTED_FRAMES( timing ) ( ( ( timing ).m_nReprojectionFlags & vr::VRCompositor_PredictionMask ) >> 4 )
|
||||
#define VR_COMPOSITOR_NUMBER_OF_THROTTLED_FRAMES( timing ) ( ( ( timing ).m_nReprojectionFlags & vr::VRCompositor_ThrottleMask ) >> 6 )
|
||||
|
||||
/** Provides a single frame's timing information to the app */
|
||||
struct Compositor_FrameTiming
|
||||
{
|
||||
uint32_t m_nSize; // Set to sizeof( Compositor_FrameTiming )
|
||||
uint32_t m_nFrameIndex;
|
||||
uint32_t m_nNumFramePresents; // number of times this frame was presented
|
||||
uint32_t m_nNumMisPresented; // number of times this frame was presented on a vsync other than it was originally predicted to
|
||||
uint32_t m_nNumDroppedFrames; // number of additional times previous frame was scanned out
|
||||
uint32_t m_nReprojectionFlags;
|
||||
|
||||
/** Absolute time reference for comparing frames. This aligns with the vsync that running start is relative to. */
|
||||
double m_flSystemTimeInSeconds;
|
||||
|
||||
/** These times may include work from other processes due to OS scheduling.
|
||||
* The fewer packets of work these are broken up into, the less likely this will happen.
|
||||
* GPU work can be broken up by calling Flush. This can sometimes be useful to get the GPU started
|
||||
* processing that work earlier in the frame. */
|
||||
float m_flPreSubmitGpuMs; // time spent rendering the scene (gpu work submitted between WaitGetPoses and second Submit)
|
||||
float m_flPostSubmitGpuMs; // additional time spent rendering by application (e.g. companion window)
|
||||
float m_flTotalRenderGpuMs; // time between work submitted immediately after present (ideally vsync) until the end of compositor submitted work
|
||||
float m_flCompositorRenderGpuMs; // time spend performing distortion correction, rendering chaperone, overlays, etc.
|
||||
float m_flCompositorRenderCpuMs; // time spent on cpu submitting the above work for this frame
|
||||
float m_flCompositorIdleCpuMs; // time spent waiting for running start (application could have used this much more time)
|
||||
|
||||
/** Miscellaneous measured intervals. */
|
||||
float m_flClientFrameIntervalMs; // time between calls to WaitGetPoses
|
||||
float m_flPresentCallCpuMs; // time blocked on call to present (usually 0.0, but can go long)
|
||||
float m_flWaitForPresentCpuMs; // time spent spin-waiting for frame index to change (not near-zero indicates wait object failure)
|
||||
float m_flSubmitFrameMs; // time spent in IVRCompositor::Submit (not near-zero indicates driver issue)
|
||||
|
||||
/** The following are all relative to this frame's SystemTimeInSeconds */
|
||||
float m_flWaitGetPosesCalledMs;
|
||||
float m_flNewPosesReadyMs;
|
||||
float m_flNewFrameReadyMs; // second call to IVRCompositor::Submit
|
||||
float m_flCompositorUpdateStartMs;
|
||||
float m_flCompositorUpdateEndMs;
|
||||
float m_flCompositorRenderStartMs;
|
||||
|
||||
vr::TrackedDevicePose_t m_HmdPose; // pose used by app to render this frame
|
||||
|
||||
uint32_t m_nNumVSyncsReadyForUse;
|
||||
uint32_t m_nNumVSyncsToFirstView;
|
||||
};
|
||||
|
||||
/** Cumulative stats for current application. These are not cleared until a new app connects,
|
||||
* but they do stop accumulating once the associated app disconnects. */
|
||||
struct Compositor_CumulativeStats
|
||||
@@ -3141,13 +3186,14 @@ public:
|
||||
/** Returns true if the current process has the scene focus */
|
||||
virtual bool CanRenderScene() = 0;
|
||||
|
||||
/** Creates a window on the primary monitor to display what is being shown in the headset. */
|
||||
/** Opens the headset view (as either a window or docked widget depending on user's preferences) that displays what the user
|
||||
* sees in the headset. */
|
||||
virtual void ShowMirrorWindow() = 0;
|
||||
|
||||
/** Closes the mirror window. */
|
||||
/** Closes the headset view, either as a window or docked widget. */
|
||||
virtual void HideMirrorWindow() = 0;
|
||||
|
||||
/** Returns true if the mirror window is shown. */
|
||||
/** Returns true if the headset view (either as a window or docked widget) is shown. */
|
||||
virtual bool IsMirrorWindowVisible() = 0;
|
||||
|
||||
/** Writes back buffer and stereo left/right pair from the application to a 'screenshots' folder in the SteamVR runtime root. */
|
||||
@@ -3409,6 +3455,9 @@ namespace vr
|
||||
// If this is set the overlay will receive smooth VREvent_ScrollSmooth that emulate trackpad scrolling.
|
||||
// Requires mouse input mode.
|
||||
VROverlayFlags_SendVRSmoothScrollEvents = 17,
|
||||
|
||||
// If this is set, the overlay texture will be protected content, preventing unauthorized reads.
|
||||
VROverlayFlags_ProtectedContent = 18,
|
||||
};
|
||||
|
||||
enum VRMessageOverlayResponse
|
||||
@@ -4271,6 +4320,8 @@ public:
|
||||
virtual uint32_t GetDriverName( vr::DriverId_t nDriver, VR_OUT_STRING() char *pchValue, uint32_t unBufferSize ) = 0;
|
||||
|
||||
virtual DriverHandle_t GetDriverHandle( const char *pchDriverName ) = 0;
|
||||
|
||||
virtual bool IsEnabled( vr::DriverId_t nDriver ) const = 0;
|
||||
};
|
||||
|
||||
static const char * const IVRDriverManager_Version = "IVRDriverManager_001";
|
||||
@@ -4409,6 +4460,14 @@ namespace vr
|
||||
char rchRenderModelComponentName[128];
|
||||
};
|
||||
|
||||
struct InputBindingInfo_t
|
||||
{
|
||||
char rchDevicePathName[128];
|
||||
char rchInputPathName[128];
|
||||
char rchModeName[128];
|
||||
char rchSlotName[128];
|
||||
};
|
||||
|
||||
struct VRActiveActionSet_t
|
||||
{
|
||||
/** This is the handle of the action set to activate for this frame. */
|
||||
@@ -4543,6 +4602,9 @@ namespace vr
|
||||
/** Retrieves useful information for the origin of this action */
|
||||
virtual EVRInputError GetOriginTrackedDeviceInfo( VRInputValueHandle_t origin, InputOriginInfo_t *pOriginInfo, uint32_t unOriginInfoSize ) = 0;
|
||||
|
||||
/** Retrieves useful information about the bindings for an action */
|
||||
virtual EVRInputError GetActionBindingInfo( VRActionHandle_t action, InputBindingInfo_t *pOriginInfo, uint32_t unBindingInfoSize, uint32_t unBindingInfoCount, uint32_t *punReturnedBindingInfoCount ) = 0;
|
||||
|
||||
/** Shows the current binding for the action in-headset */
|
||||
virtual EVRInputError ShowActionOrigins( VRActionSetHandle_t actionSetHandle, VRActionHandle_t ulActionHandle ) = 0;
|
||||
|
||||
@@ -4553,7 +4615,7 @@ namespace vr
|
||||
virtual bool IsUsingLegacyInput() = 0;
|
||||
};
|
||||
|
||||
static const char * const IVRInput_Version = "IVRInput_006";
|
||||
static const char * const IVRInput_Version = "IVRInput_007";
|
||||
|
||||
} // namespace vr
|
||||
|
||||
@@ -4660,6 +4722,49 @@ namespace vr
|
||||
|
||||
static const char * const IVRSpatialAnchors_Version = "IVRSpatialAnchors_001";
|
||||
|
||||
} // namespace vr
|
||||
|
||||
// ivrdebug.h
|
||||
namespace vr
|
||||
{
|
||||
enum EVRDebugError
|
||||
{
|
||||
VRDebugError_Success = 0,
|
||||
VRDebugError_BadParameter
|
||||
};
|
||||
|
||||
/** Handle for vr profiler events */
|
||||
typedef uint64_t VrProfilerEventHandle_t;
|
||||
|
||||
class IVRDebug
|
||||
{
|
||||
public:
|
||||
|
||||
/** Create a vr profiler discrete event (point)
|
||||
* The event will be associated with the message provided in pchMessage, and the current
|
||||
* time will be used as the event timestamp. */
|
||||
virtual EVRDebugError EmitVrProfilerEvent( const char *pchMessage ) = 0;
|
||||
|
||||
/** Create an vr profiler duration event (line)
|
||||
* The current time will be used as the timestamp for the start of the line.
|
||||
* On success, pHandleOut will contain a handle valid for terminating this event. */
|
||||
virtual EVRDebugError BeginVrProfilerEvent( VrProfilerEventHandle_t *pHandleOut ) = 0;
|
||||
|
||||
/** Terminate a vr profiler event
|
||||
* The event associated with hHandle will be considered completed when this method is called.
|
||||
* The current time will be used assocaited to the termination time of the event, and
|
||||
* pchMessage will be used as the event title. */
|
||||
virtual EVRDebugError FinishVrProfilerEvent( VrProfilerEventHandle_t hHandle, const char *pchMessage ) = 0;
|
||||
|
||||
/** Sends a request to the driver for the specified device and returns the response. The maximum response size is 32k,
|
||||
* but this method can be called with a smaller buffer. If the response exceeds the size of the buffer, it is truncated.
|
||||
* The size of the response including its terminating null is returned. */
|
||||
virtual uint32_t DriverDebugRequest( vr::TrackedDeviceIndex_t unDeviceIndex, const char *pchRequest, VR_OUT_STRING() char *pchResponseBuffer, uint32_t unResponseBufferSize ) = 0;
|
||||
|
||||
};
|
||||
|
||||
static const char * const IVRDebug_Version = "IVRDebug_001";
|
||||
|
||||
} // namespace vr
|
||||
// End
|
||||
|
||||
@@ -4929,6 +5034,17 @@ namespace vr
|
||||
return m_pVRSpatialAnchors;
|
||||
}
|
||||
|
||||
IVRDebug *VRDebug()
|
||||
{
|
||||
CheckClear();
|
||||
if ( !m_pVRDebug )
|
||||
{
|
||||
EVRInitError eError;
|
||||
m_pVRDebug = (IVRDebug *)VR_GetGenericInterface( IVRDebug_Version, &eError );
|
||||
}
|
||||
return m_pVRDebug;
|
||||
}
|
||||
|
||||
IVRNotifications *VRNotifications()
|
||||
{
|
||||
CheckClear();
|
||||
@@ -4957,6 +5073,7 @@ namespace vr
|
||||
IVRInput *m_pVRInput;
|
||||
IVRIOBuffer *m_pVRIOBuffer;
|
||||
IVRSpatialAnchors *m_pVRSpatialAnchors;
|
||||
IVRDebug *m_pVRDebug;
|
||||
IVRNotifications *m_pVRNotifications;
|
||||
};
|
||||
|
||||
@@ -4983,6 +5100,7 @@ namespace vr
|
||||
inline IVRIOBuffer *VR_CALLTYPE VRIOBuffer() { return OpenVRInternal_ModuleContext().VRIOBuffer(); }
|
||||
inline IVRSpatialAnchors *VR_CALLTYPE VRSpatialAnchors() { return OpenVRInternal_ModuleContext().VRSpatialAnchors(); }
|
||||
inline IVRNotifications *VR_CALLTYPE VRNotifications() { return OpenVRInternal_ModuleContext().VRNotifications(); }
|
||||
inline IVRDebug *VR_CALLTYPE VRDebug() { return OpenVRInternal_ModuleContext().VRDebug(); }
|
||||
|
||||
inline void COpenVRContext::Clear()
|
||||
{
|
||||
@@ -5003,6 +5121,7 @@ namespace vr
|
||||
m_pVRIOBuffer = nullptr;
|
||||
m_pVRSpatialAnchors = nullptr;
|
||||
m_pVRNotifications = nullptr;
|
||||
m_pVRDebug = nullptr;
|
||||
}
|
||||
|
||||
VR_INTERFACE uint32_t VR_CALLTYPE VR_InitInternal2( EVRInitError *peError, EVRApplicationType eApplicationType, const char *pStartupInfo );
|
||||
|
||||
Reference in New Issue
Block a user