GameApi 28
Library used by GameApi Builder tool
Loading...
Searching...
No Matches
vr::IVROverlay Class Reference

#include <openvr_mingw.h>

Public Member Functions

EVROverlayError FindOverlay (const char *pchOverlayKey, VROverlayHandle_t *pOverlayHandle)
EVROverlayError CreateOverlay (const char *pchOverlayKey, const char *pchOverlayName, VROverlayHandle_t *pOverlayHandle)
EVROverlayError DestroyOverlay (VROverlayHandle_t ulOverlayHandle)
EVROverlayError SetHighQualityOverlay (VROverlayHandle_t ulOverlayHandle)
vr::VROverlayHandle_t GetHighQualityOverlay ()
uint32_t GetOverlayKey (VROverlayHandle_t ulOverlayHandle, VR_OUT_STRING() char *pchValue, uint32_t unBufferSize, EVROverlayError *pError=0L)
uint32_t GetOverlayName (VROverlayHandle_t ulOverlayHandle, VR_OUT_STRING() char *pchValue, uint32_t unBufferSize, EVROverlayError *pError=0L)
EVROverlayError SetOverlayName (VROverlayHandle_t ulOverlayHandle, const char *pchName)
EVROverlayError GetOverlayImageData (VROverlayHandle_t ulOverlayHandle, void *pvBuffer, uint32_t unBufferSize, uint32_t *punWidth, uint32_t *punHeight)
const char * GetOverlayErrorNameFromEnum (EVROverlayError error)
EVROverlayError SetOverlayRenderingPid (VROverlayHandle_t ulOverlayHandle, uint32_t unPID)
uint32_t GetOverlayRenderingPid (VROverlayHandle_t ulOverlayHandle)
EVROverlayError SetOverlayFlag (VROverlayHandle_t ulOverlayHandle, VROverlayFlags eOverlayFlag, bool bEnabled)
EVROverlayError GetOverlayFlag (VROverlayHandle_t ulOverlayHandle, VROverlayFlags eOverlayFlag, bool *pbEnabled)
EVROverlayError SetOverlayColor (VROverlayHandle_t ulOverlayHandle, float fRed, float fGreen, float fBlue)
EVROverlayError GetOverlayColor (VROverlayHandle_t ulOverlayHandle, float *pfRed, float *pfGreen, float *pfBlue)
EVROverlayError SetOverlayAlpha (VROverlayHandle_t ulOverlayHandle, float fAlpha)
EVROverlayError GetOverlayAlpha (VROverlayHandle_t ulOverlayHandle, float *pfAlpha)
EVROverlayError SetOverlayTexelAspect (VROverlayHandle_t ulOverlayHandle, float fTexelAspect)
EVROverlayError GetOverlayTexelAspect (VROverlayHandle_t ulOverlayHandle, float *pfTexelAspect)
EVROverlayError SetOverlaySortOrder (VROverlayHandle_t ulOverlayHandle, uint32_t unSortOrder)
EVROverlayError GetOverlaySortOrder (VROverlayHandle_t ulOverlayHandle, uint32_t *punSortOrder)
EVROverlayError SetOverlayWidthInMeters (VROverlayHandle_t ulOverlayHandle, float fWidthInMeters)
EVROverlayError GetOverlayWidthInMeters (VROverlayHandle_t ulOverlayHandle, float *pfWidthInMeters)
EVROverlayError SetOverlayAutoCurveDistanceRangeInMeters (VROverlayHandle_t ulOverlayHandle, float fMinDistanceInMeters, float fMaxDistanceInMeters)
EVROverlayError GetOverlayAutoCurveDistanceRangeInMeters (VROverlayHandle_t ulOverlayHandle, float *pfMinDistanceInMeters, float *pfMaxDistanceInMeters)
EVROverlayError SetOverlayTextureColorSpace (VROverlayHandle_t ulOverlayHandle, EColorSpace eTextureColorSpace)
EVROverlayError GetOverlayTextureColorSpace (VROverlayHandle_t ulOverlayHandle, EColorSpace *peTextureColorSpace)
EVROverlayError SetOverlayTextureBounds (VROverlayHandle_t ulOverlayHandle, const VRTextureBounds_t *pOverlayTextureBounds)
EVROverlayError GetOverlayTextureBounds (VROverlayHandle_t ulOverlayHandle, VRTextureBounds_t *pOverlayTextureBounds)
uint32_t GetOverlayRenderModel (vr::VROverlayHandle_t ulOverlayHandle, VR_OUT_STRING() char *pchValue, uint32_t unBufferSize, HmdColor_t *pColor, vr::EVROverlayError *pError)
vr::EVROverlayError SetOverlayRenderModel (vr::VROverlayHandle_t ulOverlayHandle, const char *pchRenderModel, const HmdColor_t *pColor)
EVROverlayError GetOverlayTransformType (VROverlayHandle_t ulOverlayHandle, VROverlayTransformType *peTransformType)
EVROverlayError SetOverlayTransformAbsolute (VROverlayHandle_t ulOverlayHandle, ETrackingUniverseOrigin eTrackingOrigin, const HmdMatrix34_t *pmatTrackingOriginToOverlayTransform)
EVROverlayError GetOverlayTransformAbsolute (VROverlayHandle_t ulOverlayHandle, ETrackingUniverseOrigin *peTrackingOrigin, HmdMatrix34_t *pmatTrackingOriginToOverlayTransform)
EVROverlayError SetOverlayTransformTrackedDeviceRelative (VROverlayHandle_t ulOverlayHandle, TrackedDeviceIndex_t unTrackedDevice, const HmdMatrix34_t *pmatTrackedDeviceToOverlayTransform)
EVROverlayError GetOverlayTransformTrackedDeviceRelative (VROverlayHandle_t ulOverlayHandle, TrackedDeviceIndex_t *punTrackedDevice, HmdMatrix34_t *pmatTrackedDeviceToOverlayTransform)
EVROverlayError SetOverlayTransformTrackedDeviceComponent (VROverlayHandle_t ulOverlayHandle, TrackedDeviceIndex_t unDeviceIndex, const char *pchComponentName)
EVROverlayError GetOverlayTransformTrackedDeviceComponent (VROverlayHandle_t ulOverlayHandle, TrackedDeviceIndex_t *punDeviceIndex, VR_OUT_STRING() char *pchComponentName, uint32_t unComponentNameSize)
vr::EVROverlayError GetOverlayTransformOverlayRelative (VROverlayHandle_t ulOverlayHandle, VROverlayHandle_t *ulOverlayHandleParent, HmdMatrix34_t *pmatParentOverlayToOverlayTransform)
vr::EVROverlayError SetOverlayTransformOverlayRelative (VROverlayHandle_t ulOverlayHandle, VROverlayHandle_t ulOverlayHandleParent, const HmdMatrix34_t *pmatParentOverlayToOverlayTransform)
EVROverlayError ShowOverlay (VROverlayHandle_t ulOverlayHandle)
EVROverlayError HideOverlay (VROverlayHandle_t ulOverlayHandle)
bool IsOverlayVisible (VROverlayHandle_t ulOverlayHandle)
EVROverlayError GetTransformForOverlayCoordinates (VROverlayHandle_t ulOverlayHandle, ETrackingUniverseOrigin eTrackingOrigin, HmdVector2_t coordinatesInOverlay, HmdMatrix34_t *pmatTransform)
bool PollNextOverlayEvent (VROverlayHandle_t ulOverlayHandle, VREvent_t *pEvent, uint32_t uncbVREvent)
EVROverlayError GetOverlayInputMethod (VROverlayHandle_t ulOverlayHandle, VROverlayInputMethod *peInputMethod)
EVROverlayError SetOverlayInputMethod (VROverlayHandle_t ulOverlayHandle, VROverlayInputMethod eInputMethod)
EVROverlayError GetOverlayMouseScale (VROverlayHandle_t ulOverlayHandle, HmdVector2_t *pvecMouseScale)
EVROverlayError SetOverlayMouseScale (VROverlayHandle_t ulOverlayHandle, const HmdVector2_t *pvecMouseScale)
bool ComputeOverlayIntersection (VROverlayHandle_t ulOverlayHandle, const VROverlayIntersectionParams_t *pParams, VROverlayIntersectionResults_t *pResults)
bool IsHoverTargetOverlay (VROverlayHandle_t ulOverlayHandle)
vr::VROverlayHandle_t GetGamepadFocusOverlay ()
EVROverlayError SetGamepadFocusOverlay (VROverlayHandle_t ulNewFocusOverlay)
EVROverlayError SetOverlayNeighbor (EOverlayDirection eDirection, VROverlayHandle_t ulFrom, VROverlayHandle_t ulTo)
EVROverlayError MoveGamepadFocusToNeighbor (EOverlayDirection eDirection, VROverlayHandle_t ulFrom)
EVROverlayError SetOverlayDualAnalogTransform (VROverlayHandle_t ulOverlay, EDualAnalogWhich eWhich, const HmdVector2_t &vCenter, float fRadius)
EVROverlayError GetOverlayDualAnalogTransform (VROverlayHandle_t ulOverlay, EDualAnalogWhich eWhich, HmdVector2_t *pvCenter, float *pfRadius)
EVROverlayError SetOverlayTexture (VROverlayHandle_t ulOverlayHandle, const Texture_t *pTexture)
EVROverlayError ClearOverlayTexture (VROverlayHandle_t ulOverlayHandle)
EVROverlayError SetOverlayRaw (VROverlayHandle_t ulOverlayHandle, void *pvBuffer, uint32_t unWidth, uint32_t unHeight, uint32_t unDepth)
EVROverlayError SetOverlayFromFile (VROverlayHandle_t ulOverlayHandle, const char *pchFilePath)
EVROverlayError GetOverlayTexture (VROverlayHandle_t ulOverlayHandle, void **pNativeTextureHandle, void *pNativeTextureRef, uint32_t *pWidth, uint32_t *pHeight, uint32_t *pNativeFormat, ETextureType *pAPIType, EColorSpace *pColorSpace, VRTextureBounds_t *pTextureBounds)
EVROverlayError ReleaseNativeOverlayHandle (VROverlayHandle_t ulOverlayHandle, void *pNativeTextureHandle)
EVROverlayError GetOverlayTextureSize (VROverlayHandle_t ulOverlayHandle, uint32_t *pWidth, uint32_t *pHeight)
EVROverlayError CreateDashboardOverlay (const char *pchOverlayKey, const char *pchOverlayFriendlyName, VROverlayHandle_t *pMainHandle, VROverlayHandle_t *pThumbnailHandle)
bool IsDashboardVisible ()
bool IsActiveDashboardOverlay (VROverlayHandle_t ulOverlayHandle)
EVROverlayError SetDashboardOverlaySceneProcess (VROverlayHandle_t ulOverlayHandle, uint32_t unProcessId)
EVROverlayError GetDashboardOverlaySceneProcess (VROverlayHandle_t ulOverlayHandle, uint32_t *punProcessId)
void ShowDashboard (const char *pchOverlayToShow)
vr::TrackedDeviceIndex_t GetPrimaryDashboardDevice ()
EVROverlayError ShowKeyboard (EGamepadTextInputMode eInputMode, EGamepadTextInputLineMode eLineInputMode, const char *pchDescription, uint32_t unCharMax, const char *pchExistingText, bool bUseMinimalMode, uint64_t uUserValue)
EVROverlayError ShowKeyboardForOverlay (VROverlayHandle_t ulOverlayHandle, EGamepadTextInputMode eInputMode, EGamepadTextInputLineMode eLineInputMode, const char *pchDescription, uint32_t unCharMax, const char *pchExistingText, bool bUseMinimalMode, uint64_t uUserValue)
uint32_t GetKeyboardText (VR_OUT_STRING() char *pchText, uint32_t cchText)
void HideKeyboard ()
void SetKeyboardTransformAbsolute (ETrackingUniverseOrigin eTrackingOrigin, const HmdMatrix34_t *pmatTrackingOriginToKeyboardTransform)
void SetKeyboardPositionForOverlay (VROverlayHandle_t ulOverlayHandle, HmdRect2_t avoidRect)
EVROverlayError SetOverlayIntersectionMask (VROverlayHandle_t ulOverlayHandle, VROverlayIntersectionMaskPrimitive_t *pMaskPrimitives, uint32_t unNumMaskPrimitives, uint32_t unPrimitiveSize=sizeof(VROverlayIntersectionMaskPrimitive_t))
EVROverlayError GetOverlayFlags (VROverlayHandle_t ulOverlayHandle, uint32_t *pFlags)
VRMessageOverlayResponse ShowMessageOverlay (const char *pchText, const char *pchCaption, const char *pchButton0Text, const char *pchButton1Text=nullptr, const char *pchButton2Text=nullptr, const char *pchButton3Text=nullptr)
void CloseMessageOverlay ()

Member Function Documentation

◆ ClearOverlayTexture()

EVROverlayError vr::IVROverlay::ClearOverlayTexture ( VROverlayHandle_t ulOverlayHandle)
inline

Use this to tell the overlay system to release the texture set for this overlay.

◆ CloseMessageOverlay()

void vr::IVROverlay::CloseMessageOverlay ( )
inline

If the calling process owns the overlay and it's open, this will close it.

◆ ComputeOverlayIntersection()

bool vr::IVROverlay::ComputeOverlayIntersection ( VROverlayHandle_t ulOverlayHandle,
const VROverlayIntersectionParams_t * pParams,
VROverlayIntersectionResults_t * pResults )
inline

Computes the overlay-space pixel coordinates of where the ray intersects the overlay with the specified settings. Returns false if there is no intersection.

◆ CreateDashboardOverlay()

EVROverlayError vr::IVROverlay::CreateDashboardOverlay ( const char * pchOverlayKey,
const char * pchOverlayFriendlyName,
VROverlayHandle_t * pMainHandle,
VROverlayHandle_t * pThumbnailHandle )
inline

Creates a dashboard overlay and returns its handle

◆ CreateOverlay()

EVROverlayError vr::IVROverlay::CreateOverlay ( const char * pchOverlayKey,
const char * pchOverlayName,
VROverlayHandle_t * pOverlayHandle )
inline

Creates a new named overlay. All overlays start hidden and with default settings.

◆ DestroyOverlay()

EVROverlayError vr::IVROverlay::DestroyOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

Destroys the specified overlay. When an application calls VR_Shutdown all overlays created by that app are automatically destroyed.

◆ FindOverlay()

EVROverlayError vr::IVROverlay::FindOverlay ( const char * pchOverlayKey,
VROverlayHandle_t * pOverlayHandle )
inline

Finds an existing overlay with the specified key.

◆ GetDashboardOverlaySceneProcess()

EVROverlayError vr::IVROverlay::GetDashboardOverlaySceneProcess ( VROverlayHandle_t ulOverlayHandle,
uint32_t * punProcessId )
inline

Gets the process ID that this dashboard overlay requires to have scene focus

◆ GetGamepadFocusOverlay()

vr::VROverlayHandle_t vr::IVROverlay::GetGamepadFocusOverlay ( )
inline

Returns the current Gamepad focus overlay

◆ GetHighQualityOverlay()

vr::VROverlayHandle_t vr::IVROverlay::GetHighQualityOverlay ( )
inline

Returns the overlay handle of the current overlay being rendered using the single high quality overlay render path. Otherwise it will return k_ulOverlayHandleInvalid.

◆ GetKeyboardText()

uint32_t vr::IVROverlay::GetKeyboardText ( VR_OUT_STRING() char * pchText,
uint32_t cchText )
inline

Get the text that was entered into the text input

◆ GetOverlayAlpha()

EVROverlayError vr::IVROverlay::GetOverlayAlpha ( VROverlayHandle_t ulOverlayHandle,
float * pfAlpha )
inline

Gets the alpha of the overlay quad. By default overlays are rendering at 100 percent alpha (1.0).

◆ GetOverlayAutoCurveDistanceRangeInMeters()

EVROverlayError vr::IVROverlay::GetOverlayAutoCurveDistanceRangeInMeters ( VROverlayHandle_t ulOverlayHandle,
float * pfMinDistanceInMeters,
float * pfMaxDistanceInMeters )
inline

For high-quality curved overlays only, gets the distance range in meters from the overlay used to automatically curve the surface around the viewer. Min is distance is when the surface will be most curved. Max is when least curved.

◆ GetOverlayColor()

EVROverlayError vr::IVROverlay::GetOverlayColor ( VROverlayHandle_t ulOverlayHandle,
float * pfRed,
float * pfGreen,
float * pfBlue )
inline

Gets the color tint of the overlay quad.

◆ GetOverlayDualAnalogTransform()

EVROverlayError vr::IVROverlay::GetOverlayDualAnalogTransform ( VROverlayHandle_t ulOverlay,
EDualAnalogWhich eWhich,
HmdVector2_t * pvCenter,
float * pfRadius )
inline

Gets the analog input to Dual Analog coordinate scale for the specified overlay.

◆ GetOverlayErrorNameFromEnum()

const char * vr::IVROverlay::GetOverlayErrorNameFromEnum ( EVROverlayError error)
inline

returns a string that corresponds with the specified overlay error. The string will be the name of the error enum value for all valid error codes

◆ GetOverlayFlag()

EVROverlayError vr::IVROverlay::GetOverlayFlag ( VROverlayHandle_t ulOverlayHandle,
VROverlayFlags eOverlayFlag,
bool * pbEnabled )
inline

Sets flag setting for a given overlay

◆ GetOverlayFlags()

EVROverlayError vr::IVROverlay::GetOverlayFlags ( VROverlayHandle_t ulOverlayHandle,
uint32_t * pFlags )
inline

◆ GetOverlayImageData()

EVROverlayError vr::IVROverlay::GetOverlayImageData ( VROverlayHandle_t ulOverlayHandle,
void * pvBuffer,
uint32_t unBufferSize,
uint32_t * punWidth,
uint32_t * punHeight )
inline

Gets the raw image data from an overlay. Overlay image data is always returned as RGBA data, 4 bytes per pixel. If the buffer is not large enough, width and height will be set and VROverlayError_ArrayTooSmall is returned.

◆ GetOverlayInputMethod()

EVROverlayError vr::IVROverlay::GetOverlayInputMethod ( VROverlayHandle_t ulOverlayHandle,
VROverlayInputMethod * peInputMethod )
inline

Returns the current input settings for the specified overlay.

◆ GetOverlayKey()

uint32_t vr::IVROverlay::GetOverlayKey ( VROverlayHandle_t ulOverlayHandle,
VR_OUT_STRING() char * pchValue,
uint32_t unBufferSize,
EVROverlayError * pError = 0L )
inline

Fills the provided buffer with the string key of the overlay. Returns the size of buffer required to store the key, including the terminating null character. k_unVROverlayMaxKeyLength will be enough bytes to fit the string.

◆ GetOverlayMouseScale()

EVROverlayError vr::IVROverlay::GetOverlayMouseScale ( VROverlayHandle_t ulOverlayHandle,
HmdVector2_t * pvecMouseScale )
inline

Gets the mouse scaling factor that is used for mouse events. The actual texture may be a different size, but this is typically the size of the underlying UI in pixels.

◆ GetOverlayName()

uint32_t vr::IVROverlay::GetOverlayName ( VROverlayHandle_t ulOverlayHandle,
VR_OUT_STRING() char * pchValue,
uint32_t unBufferSize,
EVROverlayError * pError = 0L )
inline

Fills the provided buffer with the friendly name of the overlay. Returns the size of buffer required to store the key, including the terminating null character. k_unVROverlayMaxNameLength will be enough bytes to fit the string.

◆ GetOverlayRenderingPid()

uint32_t vr::IVROverlay::GetOverlayRenderingPid ( VROverlayHandle_t ulOverlayHandle)
inline

Gets the pid that is allowed to render to this overlay

◆ GetOverlayRenderModel()

uint32_t vr::IVROverlay::GetOverlayRenderModel ( vr::VROverlayHandle_t ulOverlayHandle,
VR_OUT_STRING() char * pchValue,
uint32_t unBufferSize,
HmdColor_t * pColor,
vr::EVROverlayError * pError )
inline

Gets render model to draw behind this overlay

◆ GetOverlaySortOrder()

EVROverlayError vr::IVROverlay::GetOverlaySortOrder ( VROverlayHandle_t ulOverlayHandle,
uint32_t * punSortOrder )
inline

Gets the sort order of the overlay. See SetOverlaySortOrder for how this works.

◆ GetOverlayTexelAspect()

EVROverlayError vr::IVROverlay::GetOverlayTexelAspect ( VROverlayHandle_t ulOverlayHandle,
float * pfTexelAspect )
inline

Gets the aspect ratio of the texels in the overlay. Defaults to 1.0

◆ GetOverlayTexture()

EVROverlayError vr::IVROverlay::GetOverlayTexture ( VROverlayHandle_t ulOverlayHandle,
void ** pNativeTextureHandle,
void * pNativeTextureRef,
uint32_t * pWidth,
uint32_t * pHeight,
uint32_t * pNativeFormat,
ETextureType * pAPIType,
EColorSpace * pColorSpace,
VRTextureBounds_t * pTextureBounds )
inline

Get the native texture handle/device for an overlay you have created. On windows this handle will be a ID3D11ShaderResourceView with a ID3D11Texture2D bound.

The texture will always be sized to match the backing texture you supplied in SetOverlayTexture above.

You MUST call ReleaseNativeOverlayHandle() with pNativeTextureHandle once you are done with this texture.

pNativeTextureHandle is an OUTPUT, it will be a pointer to a ID3D11ShaderResourceView *. pNativeTextureRef is an INPUT and should be a ID3D11Resource *. The device used by pNativeTextureRef will be used to bind pNativeTextureHandle.

◆ GetOverlayTextureBounds()

EVROverlayError vr::IVROverlay::GetOverlayTextureBounds ( VROverlayHandle_t ulOverlayHandle,
VRTextureBounds_t * pOverlayTextureBounds )
inline

Gets the part of the texture to use for the overlay. UV Min is the upper left corner and UV Max is the lower right corner.

◆ GetOverlayTextureColorSpace()

EVROverlayError vr::IVROverlay::GetOverlayTextureColorSpace ( VROverlayHandle_t ulOverlayHandle,
EColorSpace * peTextureColorSpace )
inline

Gets the overlay's current colorspace setting.

◆ GetOverlayTextureSize()

EVROverlayError vr::IVROverlay::GetOverlayTextureSize ( VROverlayHandle_t ulOverlayHandle,
uint32_t * pWidth,
uint32_t * pHeight )
inline

Get the size of the overlay texture

◆ GetOverlayTransformAbsolute()

EVROverlayError vr::IVROverlay::GetOverlayTransformAbsolute ( VROverlayHandle_t ulOverlayHandle,
ETrackingUniverseOrigin * peTrackingOrigin,
HmdMatrix34_t * pmatTrackingOriginToOverlayTransform )
inline

Gets the transform if it is absolute. Returns an error if the transform is some other type.

◆ GetOverlayTransformOverlayRelative()

vr::EVROverlayError vr::IVROverlay::GetOverlayTransformOverlayRelative ( VROverlayHandle_t ulOverlayHandle,
VROverlayHandle_t * ulOverlayHandleParent,
HmdMatrix34_t * pmatParentOverlayToOverlayTransform )
inline

Gets the transform if it is relative to another overlay. Returns an error if the transform is some other type.

◆ GetOverlayTransformTrackedDeviceComponent()

EVROverlayError vr::IVROverlay::GetOverlayTransformTrackedDeviceComponent ( VROverlayHandle_t ulOverlayHandle,
TrackedDeviceIndex_t * punDeviceIndex,
VR_OUT_STRING() char * pchComponentName,
uint32_t unComponentNameSize )
inline

Gets the transform information when the overlay is rendering on a component.

◆ GetOverlayTransformTrackedDeviceRelative()

EVROverlayError vr::IVROverlay::GetOverlayTransformTrackedDeviceRelative ( VROverlayHandle_t ulOverlayHandle,
TrackedDeviceIndex_t * punTrackedDevice,
HmdMatrix34_t * pmatTrackedDeviceToOverlayTransform )
inline

Gets the transform if it is relative to a tracked device. Returns an error if the transform is some other type.

◆ GetOverlayTransformType()

EVROverlayError vr::IVROverlay::GetOverlayTransformType ( VROverlayHandle_t ulOverlayHandle,
VROverlayTransformType * peTransformType )
inline

Returns the transform type of this overlay.

◆ GetOverlayWidthInMeters()

EVROverlayError vr::IVROverlay::GetOverlayWidthInMeters ( VROverlayHandle_t ulOverlayHandle,
float * pfWidthInMeters )
inline

Returns the width of the overlay quad in meters. By default overlays are rendered on a quad that is 1 meter across

◆ GetPrimaryDashboardDevice()

vr::TrackedDeviceIndex_t vr::IVROverlay::GetPrimaryDashboardDevice ( )
inline

Returns the tracked device that has the laser pointer in the dashboard

◆ GetTransformForOverlayCoordinates()

EVROverlayError vr::IVROverlay::GetTransformForOverlayCoordinates ( VROverlayHandle_t ulOverlayHandle,
ETrackingUniverseOrigin eTrackingOrigin,
HmdVector2_t coordinatesInOverlay,
HmdMatrix34_t * pmatTransform )
inline

Get the transform in 3d space associated with a specific 2d point in the overlay's coordinate space (where 0,0 is the lower left). -Z points out of the overlay

◆ HideKeyboard()

void vr::IVROverlay::HideKeyboard ( )
inline

Hide the virtual keyboard

◆ HideOverlay()

EVROverlayError vr::IVROverlay::HideOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

Hides the VR overlay. For dashboard overlays, only the Dashboard Manager is allowed to call this.

◆ IsActiveDashboardOverlay()

bool vr::IVROverlay::IsActiveDashboardOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

returns true if the dashboard is visible and the specified overlay is the active system Overlay

◆ IsDashboardVisible()

bool vr::IVROverlay::IsDashboardVisible ( )
inline

Returns true if the dashboard is visible

◆ IsHoverTargetOverlay()

bool vr::IVROverlay::IsHoverTargetOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

Returns true if the specified overlay is the hover target. An overlay is the hover target when it is the last overlay "moused over" by the virtual mouse pointer

◆ IsOverlayVisible()

bool vr::IVROverlay::IsOverlayVisible ( VROverlayHandle_t ulOverlayHandle)
inline

Returns true if the overlay is visible.

◆ MoveGamepadFocusToNeighbor()

EVROverlayError vr::IVROverlay::MoveGamepadFocusToNeighbor ( EOverlayDirection eDirection,
VROverlayHandle_t ulFrom )
inline

Changes the Gamepad focus from one overlay to one of its neighbors. Returns VROverlayError_NoNeighbor if there is no neighbor in that direction

◆ PollNextOverlayEvent()

bool vr::IVROverlay::PollNextOverlayEvent ( VROverlayHandle_t ulOverlayHandle,
VREvent_t * pEvent,
uint32_t uncbVREvent )
inline

Returns true and fills the event with the next event on the overlay's event queue, if there is one. If there are no events this method returns false. uncbVREvent should be the size in bytes of the VREvent_t struct

◆ ReleaseNativeOverlayHandle()

EVROverlayError vr::IVROverlay::ReleaseNativeOverlayHandle ( VROverlayHandle_t ulOverlayHandle,
void * pNativeTextureHandle )
inline

Release the pNativeTextureHandle provided from the GetOverlayTexture call, this allows the system to free the underlying GPU resources for this object, so only do it once you stop rendering this texture.

◆ SetDashboardOverlaySceneProcess()

EVROverlayError vr::IVROverlay::SetDashboardOverlaySceneProcess ( VROverlayHandle_t ulOverlayHandle,
uint32_t unProcessId )
inline

Sets the dashboard overlay to only appear when the specified process ID has scene focus

◆ SetGamepadFocusOverlay()

EVROverlayError vr::IVROverlay::SetGamepadFocusOverlay ( VROverlayHandle_t ulNewFocusOverlay)
inline

Sets the current Gamepad focus overlay

◆ SetHighQualityOverlay()

EVROverlayError vr::IVROverlay::SetHighQualityOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

Specify which overlay to use the high quality render path. This overlay will be composited in during the distortion pass which results in it drawing on top of everything else, but also at a higher quality as it samples the source texture directly rather than rasterizing into each eye's render texture first. Because if this, only one of these is supported at any given time. It is most useful for overlays that are expected to take up most of the user's view (e.g. streaming video). This mode does not support mouse input to your overlay.

◆ SetKeyboardPositionForOverlay()

void vr::IVROverlay::SetKeyboardPositionForOverlay ( VROverlayHandle_t ulOverlayHandle,
HmdRect2_t avoidRect )
inline

Set the position of the keyboard in overlay space by telling it to avoid a rectangle in the overlay. Rectangle coords have (0,0) in the bottom left

◆ SetKeyboardTransformAbsolute()

void vr::IVROverlay::SetKeyboardTransformAbsolute ( ETrackingUniverseOrigin eTrackingOrigin,
const HmdMatrix34_t * pmatTrackingOriginToKeyboardTransform )
inline

Set the position of the keyboard in world space

◆ SetOverlayAlpha()

EVROverlayError vr::IVROverlay::SetOverlayAlpha ( VROverlayHandle_t ulOverlayHandle,
float fAlpha )
inline

Sets the alpha of the overlay quad. Use 1.0 for 100 percent opacity to 0.0 for 0 percent opacity.

◆ SetOverlayAutoCurveDistanceRangeInMeters()

EVROverlayError vr::IVROverlay::SetOverlayAutoCurveDistanceRangeInMeters ( VROverlayHandle_t ulOverlayHandle,
float fMinDistanceInMeters,
float fMaxDistanceInMeters )
inline

For high-quality curved overlays only, sets the distance range in meters from the overlay used to automatically curve the surface around the viewer. Min is distance is when the surface will be most curved. Max is when least curved.

◆ SetOverlayColor()

EVROverlayError vr::IVROverlay::SetOverlayColor ( VROverlayHandle_t ulOverlayHandle,
float fRed,
float fGreen,
float fBlue )
inline

Sets the color tint of the overlay quad. Use 0.0 to 1.0 per channel.

◆ SetOverlayDualAnalogTransform()

EVROverlayError vr::IVROverlay::SetOverlayDualAnalogTransform ( VROverlayHandle_t ulOverlay,
EDualAnalogWhich eWhich,
const HmdVector2_t & vCenter,
float fRadius )
inline

Sets the analog input to Dual Analog coordinate scale for the specified overlay.

◆ SetOverlayFlag()

EVROverlayError vr::IVROverlay::SetOverlayFlag ( VROverlayHandle_t ulOverlayHandle,
VROverlayFlags eOverlayFlag,
bool bEnabled )
inline

Specify flag setting for a given overlay

◆ SetOverlayFromFile()

EVROverlayError vr::IVROverlay::SetOverlayFromFile ( VROverlayHandle_t ulOverlayHandle,
const char * pchFilePath )
inline

Separate interface for providing the image through a filename: can be png or jpg, and should not be bigger than 1920x1080. This function can only be called by the overlay's renderer process

◆ SetOverlayInputMethod()

EVROverlayError vr::IVROverlay::SetOverlayInputMethod ( VROverlayHandle_t ulOverlayHandle,
VROverlayInputMethod eInputMethod )
inline

Sets the input settings for the specified overlay.

◆ SetOverlayIntersectionMask()

EVROverlayError vr::IVROverlay::SetOverlayIntersectionMask ( VROverlayHandle_t ulOverlayHandle,
VROverlayIntersectionMaskPrimitive_t * pMaskPrimitives,
uint32_t unNumMaskPrimitives,
uint32_t unPrimitiveSize = sizeof( VROverlayIntersectionMaskPrimitive_t ) )
inline

Sets a list of primitives to be used for controller ray intersection typically the size of the underlying UI in pixels (not in world space).

◆ SetOverlayMouseScale()

EVROverlayError vr::IVROverlay::SetOverlayMouseScale ( VROverlayHandle_t ulOverlayHandle,
const HmdVector2_t * pvecMouseScale )
inline

Sets the mouse scaling factor that is used for mouse events. The actual texture may be a different size, but this is typically the size of the underlying UI in pixels (not in world space).

◆ SetOverlayName()

EVROverlayError vr::IVROverlay::SetOverlayName ( VROverlayHandle_t ulOverlayHandle,
const char * pchName )
inline

set the name to use for this overlay

◆ SetOverlayNeighbor()

EVROverlayError vr::IVROverlay::SetOverlayNeighbor ( EOverlayDirection eDirection,
VROverlayHandle_t ulFrom,
VROverlayHandle_t ulTo )
inline

Sets an overlay's neighbor. This will also set the neighbor of the "to" overlay to point back to the "from" overlay. If an overlay's neighbor is set to invalid both ends will be cleared

◆ SetOverlayRaw()

EVROverlayError vr::IVROverlay::SetOverlayRaw ( VROverlayHandle_t ulOverlayHandle,
void * pvBuffer,
uint32_t unWidth,
uint32_t unHeight,
uint32_t unDepth )
inline

Separate interface for providing the data as a stream of bytes, but there is an upper bound on data that can be sent. This function can only be called by the overlay's renderer process.

◆ SetOverlayRenderingPid()

EVROverlayError vr::IVROverlay::SetOverlayRenderingPid ( VROverlayHandle_t ulOverlayHandle,
uint32_t unPID )
inline

Sets the pid that is allowed to render to this overlay (the creator pid is always allow to render), by default this is the pid of the process that made the overlay

◆ SetOverlayRenderModel()

vr::EVROverlayError vr::IVROverlay::SetOverlayRenderModel ( vr::VROverlayHandle_t ulOverlayHandle,
const char * pchRenderModel,
const HmdColor_t * pColor )
inline

Sets render model to draw behind this overlay and the vertex color to use, pass null for pColor to match the overlays vertex color. The model is scaled by the same amount as the overlay, with a default of 1m.

◆ SetOverlaySortOrder()

EVROverlayError vr::IVROverlay::SetOverlaySortOrder ( VROverlayHandle_t ulOverlayHandle,
uint32_t unSortOrder )
inline

Sets the rendering sort order for the overlay. Overlays are rendered this order: Overlays owned by the scene application Overlays owned by some other application

Within a category overlays are rendered lowest sort order to highest sort order. Overlays with the same sort order are rendered back to front base on distance from the HMD.

Sort order defaults to 0.

◆ SetOverlayTexelAspect()

EVROverlayError vr::IVROverlay::SetOverlayTexelAspect ( VROverlayHandle_t ulOverlayHandle,
float fTexelAspect )
inline

Sets the aspect ratio of the texels in the overlay. 1.0 means the texels are square. 2.0 means the texels are twice as wide as they are tall. Defaults to 1.0.

◆ SetOverlayTexture()

EVROverlayError vr::IVROverlay::SetOverlayTexture ( VROverlayHandle_t ulOverlayHandle,
const Texture_t * pTexture )
inline

Texture to draw for the overlay. This function can only be called by the overlay's creator or renderer process (see SetOverlayRenderingPid) .

OpenGL dirty state: glBindTexture

◆ SetOverlayTextureBounds()

EVROverlayError vr::IVROverlay::SetOverlayTextureBounds ( VROverlayHandle_t ulOverlayHandle,
const VRTextureBounds_t * pOverlayTextureBounds )
inline

Sets the part of the texture to use for the overlay. UV Min is the upper left corner and UV Max is the lower right corner.

◆ SetOverlayTextureColorSpace()

EVROverlayError vr::IVROverlay::SetOverlayTextureColorSpace ( VROverlayHandle_t ulOverlayHandle,
EColorSpace eTextureColorSpace )
inline

Sets the colorspace the overlay texture's data is in. Defaults to 'auto'. If the texture needs to be resolved, you should call SetOverlayTexture with the appropriate colorspace instead.

◆ SetOverlayTransformAbsolute()

EVROverlayError vr::IVROverlay::SetOverlayTransformAbsolute ( VROverlayHandle_t ulOverlayHandle,
ETrackingUniverseOrigin eTrackingOrigin,
const HmdMatrix34_t * pmatTrackingOriginToOverlayTransform )
inline

Sets the transform to absolute tracking origin.

◆ SetOverlayTransformOverlayRelative()

vr::EVROverlayError vr::IVROverlay::SetOverlayTransformOverlayRelative ( VROverlayHandle_t ulOverlayHandle,
VROverlayHandle_t ulOverlayHandleParent,
const HmdMatrix34_t * pmatParentOverlayToOverlayTransform )
inline

Sets the transform to relative to the transform of the specified overlay. This overlays visibility will also track the parents visibility

◆ SetOverlayTransformTrackedDeviceComponent()

EVROverlayError vr::IVROverlay::SetOverlayTransformTrackedDeviceComponent ( VROverlayHandle_t ulOverlayHandle,
TrackedDeviceIndex_t unDeviceIndex,
const char * pchComponentName )
inline

Sets the transform to draw the overlay on a rendermodel component mesh instead of a quad. This will only draw when the system is drawing the device. Overlays with this transform type cannot receive mouse events.

◆ SetOverlayTransformTrackedDeviceRelative()

EVROverlayError vr::IVROverlay::SetOverlayTransformTrackedDeviceRelative ( VROverlayHandle_t ulOverlayHandle,
TrackedDeviceIndex_t unTrackedDevice,
const HmdMatrix34_t * pmatTrackedDeviceToOverlayTransform )
inline

Sets the transform to relative to the transform of the specified tracked device.

◆ SetOverlayWidthInMeters()

EVROverlayError vr::IVROverlay::SetOverlayWidthInMeters ( VROverlayHandle_t ulOverlayHandle,
float fWidthInMeters )
inline

Sets the width of the overlay quad in meters. By default overlays are rendered on a quad that is 1 meter across

◆ ShowDashboard()

void vr::IVROverlay::ShowDashboard ( const char * pchOverlayToShow)
inline

Shows the dashboard.

◆ ShowKeyboard()

EVROverlayError vr::IVROverlay::ShowKeyboard ( EGamepadTextInputMode eInputMode,
EGamepadTextInputLineMode eLineInputMode,
const char * pchDescription,
uint32_t unCharMax,
const char * pchExistingText,
bool bUseMinimalMode,
uint64_t uUserValue )
inline

Show the virtual keyboard to accept input

◆ ShowKeyboardForOverlay()

EVROverlayError vr::IVROverlay::ShowKeyboardForOverlay ( VROverlayHandle_t ulOverlayHandle,
EGamepadTextInputMode eInputMode,
EGamepadTextInputLineMode eLineInputMode,
const char * pchDescription,
uint32_t unCharMax,
const char * pchExistingText,
bool bUseMinimalMode,
uint64_t uUserValue )
inline

◆ ShowMessageOverlay()

VRMessageOverlayResponse vr::IVROverlay::ShowMessageOverlay ( const char * pchText,
const char * pchCaption,
const char * pchButton0Text,
const char * pchButton1Text = nullptr,
const char * pchButton2Text = nullptr,
const char * pchButton3Text = nullptr )
inline

Show the message overlay. This will block and return you a result.

◆ ShowOverlay()

EVROverlayError vr::IVROverlay::ShowOverlay ( VROverlayHandle_t ulOverlayHandle)
inline

Shows the VR overlay. For dashboard overlays, only the Dashboard Manager is allowed to call this.


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