Struct ovr_overlay_sys::IVROverlay
source · [−]#[repr(C)]pub struct IVROverlay { /* private fields */ }
Implementations
sourceimpl IVROverlay
impl IVROverlay
sourcepub unsafe fn FindOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pOverlayHandle: *mut u64
) -> EVROverlayError
pub unsafe fn FindOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pOverlayHandle: *mut u64
) -> EVROverlayError
Finds an existing overlay with the specified key.
sourcepub unsafe fn CreateOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pchOverlayName: *const c_char,
pOverlayHandle: *mut u64
) -> EVROverlayError
pub unsafe fn CreateOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pchOverlayName: *const c_char,
pOverlayHandle: *mut u64
) -> EVROverlayError
Creates a new named overlay. All overlays start hidden and with default settings.
sourcepub unsafe fn DestroyOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
pub unsafe fn DestroyOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
Destroys the specified overlay. When an application calls VR_Shutdown all overlays created by that app are automatically destroyed.
sourcepub unsafe fn GetOverlayKey(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchValue: *mut c_char,
unBufferSize: u32,
pError: *mut EVROverlayError
) -> u32
pub unsafe fn GetOverlayKey(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchValue: *mut c_char,
unBufferSize: u32,
pError: *mut EVROverlayError
) -> u32
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.
sourcepub unsafe fn GetOverlayName(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchValue: *mut c_char,
unBufferSize: u32,
pError: *mut EVROverlayError
) -> u32
pub unsafe fn GetOverlayName(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchValue: *mut c_char,
unBufferSize: u32,
pError: *mut EVROverlayError
) -> u32
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.
sourcepub unsafe fn SetOverlayName(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchName: *const c_char
) -> EVROverlayError
pub unsafe fn SetOverlayName(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchName: *const c_char
) -> EVROverlayError
set the name to use for this overlay
sourcepub unsafe fn GetOverlayImageData(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvBuffer: *mut c_void,
unBufferSize: u32,
punWidth: *mut u32,
punHeight: *mut u32
) -> EVROverlayError
pub unsafe fn GetOverlayImageData(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvBuffer: *mut c_void,
unBufferSize: u32,
punWidth: *mut u32,
punHeight: *mut u32
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayErrorNameFromEnum(
self: Pin<&mut IVROverlay>,
error: EVROverlayError
) -> *const c_char
pub unsafe fn GetOverlayErrorNameFromEnum(
self: Pin<&mut IVROverlay>,
error: EVROverlayError
) -> *const c_char
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
sourcepub unsafe fn SetOverlayRenderingPid(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unPID: u32
) -> EVROverlayError
pub unsafe fn SetOverlayRenderingPid(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unPID: u32
) -> EVROverlayError
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
sourcepub unsafe fn GetOverlayRenderingPid(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> u32
pub unsafe fn GetOverlayRenderingPid(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> u32
Gets the pid that is allowed to render to this overlay
sourcepub unsafe fn SetOverlayFlag(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eOverlayFlag: VROverlayFlags,
bEnabled: bool
) -> EVROverlayError
pub unsafe fn SetOverlayFlag(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eOverlayFlag: VROverlayFlags,
bEnabled: bool
) -> EVROverlayError
Specify flag setting for a given overlay
sourcepub unsafe fn GetOverlayFlag(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eOverlayFlag: VROverlayFlags,
pbEnabled: *mut bool
) -> EVROverlayError
pub unsafe fn GetOverlayFlag(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eOverlayFlag: VROverlayFlags,
pbEnabled: *mut bool
) -> EVROverlayError
Sets flag setting for a given overlay
sourcepub unsafe fn GetOverlayFlags(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pFlags: *mut u32
) -> EVROverlayError
pub unsafe fn GetOverlayFlags(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pFlags: *mut u32
) -> EVROverlayError
Gets all the flags for a given overlay
sourcepub unsafe fn SetOverlayColor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fRed: f32,
fGreen: f32,
fBlue: f32
) -> EVROverlayError
pub unsafe fn SetOverlayColor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fRed: f32,
fGreen: f32,
fBlue: f32
) -> EVROverlayError
Sets the color tint of the overlay quad. Use 0.0 to 1.0 per channel.
sourcepub unsafe fn GetOverlayColor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfRed: *mut f32,
pfGreen: *mut f32,
pfBlue: *mut f32
) -> EVROverlayError
pub unsafe fn GetOverlayColor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfRed: *mut f32,
pfGreen: *mut f32,
pfBlue: *mut f32
) -> EVROverlayError
Gets the color tint of the overlay quad.
sourcepub unsafe fn SetOverlayAlpha(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fAlpha: f32
) -> EVROverlayError
pub unsafe fn SetOverlayAlpha(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fAlpha: f32
) -> EVROverlayError
Sets the alpha of the overlay quad. Use 1.0 for 100 percent opacity to 0.0 for 0 percent opacity.
sourcepub unsafe fn GetOverlayAlpha(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfAlpha: *mut f32
) -> EVROverlayError
pub unsafe fn GetOverlayAlpha(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfAlpha: *mut f32
) -> EVROverlayError
Gets the alpha of the overlay quad. By default overlays are rendering at 100 percent alpha (1.0).
sourcepub unsafe fn SetOverlayTexelAspect(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fTexelAspect: f32
) -> EVROverlayError
pub unsafe fn SetOverlayTexelAspect(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fTexelAspect: f32
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTexelAspect(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfTexelAspect: *mut f32
) -> EVROverlayError
pub unsafe fn GetOverlayTexelAspect(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfTexelAspect: *mut f32
) -> EVROverlayError
Gets the aspect ratio of the texels in the overlay. Defaults to 1.0
sourcepub unsafe fn SetOverlaySortOrder(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unSortOrder: u32
) -> EVROverlayError
pub unsafe fn SetOverlaySortOrder(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unSortOrder: u32
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlaySortOrder(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punSortOrder: *mut u32
) -> EVROverlayError
pub unsafe fn GetOverlaySortOrder(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punSortOrder: *mut u32
) -> EVROverlayError
Gets the sort order of the overlay. See SetOverlaySortOrder for how this works.
sourcepub unsafe fn SetOverlayWidthInMeters(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fWidthInMeters: f32
) -> EVROverlayError
pub unsafe fn SetOverlayWidthInMeters(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fWidthInMeters: f32
) -> EVROverlayError
Sets the width of the overlay quad in meters. By default overlays are rendered on a quad that is 1 meter across
sourcepub unsafe fn GetOverlayWidthInMeters(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfWidthInMeters: *mut f32
) -> EVROverlayError
pub unsafe fn GetOverlayWidthInMeters(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfWidthInMeters: *mut f32
) -> EVROverlayError
Returns the width of the overlay quad in meters. By default overlays are rendered on a quad that is 1 meter across
sourcepub unsafe fn SetOverlayCurvature(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fCurvature: f32
) -> EVROverlayError
pub unsafe fn SetOverlayCurvature(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fCurvature: f32
) -> EVROverlayError
Use to draw overlay as a curved surface. Curvature is a percentage from (0..1] where 1 is a fully closed cylinder. For a specific radius, curvature can be computed as: overlay.width / (2 PI r).
sourcepub unsafe fn GetOverlayCurvature(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfCurvature: *mut f32
) -> EVROverlayError
pub unsafe fn GetOverlayCurvature(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pfCurvature: *mut f32
) -> EVROverlayError
Returns the curvature of the overlay as a percentage from (0..1] where 1 is a fully closed cylinder.
sourcepub unsafe fn SetOverlayTextureColorSpace(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTextureColorSpace: EColorSpace
) -> EVROverlayError
pub unsafe fn SetOverlayTextureColorSpace(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTextureColorSpace: EColorSpace
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTextureColorSpace(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTextureColorSpace: *mut EColorSpace
) -> EVROverlayError
pub unsafe fn GetOverlayTextureColorSpace(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTextureColorSpace: *mut EColorSpace
) -> EVROverlayError
Gets the overlay’s current colorspace setting.
sourcepub unsafe fn SetOverlayTextureBounds(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pOverlayTextureBounds: *const VRTextureBounds_t
) -> EVROverlayError
pub unsafe fn SetOverlayTextureBounds(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pOverlayTextureBounds: *const VRTextureBounds_t
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTextureBounds(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pOverlayTextureBounds: *mut VRTextureBounds_t
) -> EVROverlayError
pub unsafe fn GetOverlayTextureBounds(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pOverlayTextureBounds: *mut VRTextureBounds_t
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTransformType(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTransformType: *mut VROverlayTransformType
) -> EVROverlayError
pub unsafe fn GetOverlayTransformType(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTransformType: *mut VROverlayTransformType
) -> EVROverlayError
Returns the transform type of this overlay.
sourcepub unsafe fn SetOverlayTransformAbsolute(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn SetOverlayTransformAbsolute(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
Sets the transform to absolute tracking origin.
sourcepub unsafe fn GetOverlayTransformAbsolute(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTrackingOrigin: *mut ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn GetOverlayTransformAbsolute(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peTrackingOrigin: *mut ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
Gets the transform if it is absolute. Returns an error if the transform is some other type.
sourcepub unsafe fn SetOverlayTransformTrackedDeviceRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unTrackedDevice: u32,
pmatTrackedDeviceToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn SetOverlayTransformTrackedDeviceRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unTrackedDevice: u32,
pmatTrackedDeviceToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
Sets the transform to relative to the transform of the specified tracked device.
sourcepub unsafe fn GetOverlayTransformTrackedDeviceRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punTrackedDevice: *mut u32,
pmatTrackedDeviceToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn GetOverlayTransformTrackedDeviceRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punTrackedDevice: *mut u32,
pmatTrackedDeviceToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
Gets the transform if it is relative to a tracked device. Returns an error if the transform is some other type.
sourcepub unsafe fn SetOverlayTransformTrackedDeviceComponent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unDeviceIndex: u32,
pchComponentName: *const c_char
) -> EVROverlayError
pub unsafe fn SetOverlayTransformTrackedDeviceComponent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unDeviceIndex: u32,
pchComponentName: *const c_char
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTransformTrackedDeviceComponent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punDeviceIndex: *mut u32,
pchComponentName: *mut c_char,
unComponentNameSize: u32
) -> EVROverlayError
pub unsafe fn GetOverlayTransformTrackedDeviceComponent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punDeviceIndex: *mut u32,
pchComponentName: *mut c_char,
unComponentNameSize: u32
) -> EVROverlayError
Gets the transform information when the overlay is rendering on a component.
sourcepub unsafe fn GetOverlayTransformOverlayRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulOverlayHandleParent: *mut u64,
pmatParentOverlayToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn GetOverlayTransformOverlayRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulOverlayHandleParent: *mut u64,
pmatParentOverlayToOverlayTransform: *mut HmdMatrix34_t
) -> EVROverlayError
Gets the transform if it is relative to another overlay. Returns an error if the transform is some other type.
sourcepub unsafe fn SetOverlayTransformOverlayRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulOverlayHandleParent: u64,
pmatParentOverlayToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn SetOverlayTransformOverlayRelative(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulOverlayHandleParent: u64,
pmatParentOverlayToOverlayTransform: *const HmdMatrix34_t
) -> EVROverlayError
Sets the transform to relative to the transform of the specified overlay. This overlays visibility will also track the parents visibility
sourcepub unsafe fn SetOverlayTransformCursor(
self: Pin<&mut IVROverlay>,
ulCursorOverlayHandle: u64,
pvHotspot: *const HmdVector2_t
) -> EVROverlayError
pub unsafe fn SetOverlayTransformCursor(
self: Pin<&mut IVROverlay>,
ulCursorOverlayHandle: u64,
pvHotspot: *const HmdVector2_t
) -> EVROverlayError
Sets the hotspot for the specified overlay when that overlay is used as a cursor. These are in texture space with 0,0 in the upper left corner of the texture and 1,1 in the lower right corner of the texture.
sourcepub unsafe fn GetOverlayTransformCursor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvHotspot: *mut HmdVector2_t
) -> EVROverlayError
pub unsafe fn GetOverlayTransformCursor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvHotspot: *mut HmdVector2_t
) -> EVROverlayError
Gets cursor hotspot/transform for the specified overlay
sourcepub unsafe fn SetOverlayTransformProjection(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *const HmdMatrix34_t,
pProjection: *const VROverlayProjection_t,
eEye: EVREye
) -> EVROverlayError
pub unsafe fn SetOverlayTransformProjection(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToOverlayTransform: *const HmdMatrix34_t,
pProjection: *const VROverlayProjection_t,
eEye: EVREye
) -> EVROverlayError
Sets the overlay as a projection overlay
sourcepub unsafe fn ShowOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
pub unsafe fn ShowOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
Shows the VR overlay. For dashboard overlays, only the Dashboard Manager is allowed to call this.
sourcepub unsafe fn HideOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
pub unsafe fn HideOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
Hides the VR overlay. For dashboard overlays, only the Dashboard Manager is allowed to call this.
sourcepub unsafe fn IsOverlayVisible(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
pub unsafe fn IsOverlayVisible(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
Returns true if the overlay is visible.
sourcepub unsafe fn GetTransformForOverlayCoordinates(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
coordinatesInOverlay: impl ValueParam<HmdVector2_t>,
pmatTransform: *mut HmdMatrix34_t
) -> EVROverlayError
pub unsafe fn GetTransformForOverlayCoordinates(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eTrackingOrigin: ETrackingUniverseOrigin,
coordinatesInOverlay: impl ValueParam<HmdVector2_t>,
pmatTransform: *mut HmdMatrix34_t
) -> EVROverlayError
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
sourcepub unsafe fn PollNextOverlayEvent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pEvent: *mut VREvent_t,
uncbVREvent: u32
) -> bool
pub unsafe fn PollNextOverlayEvent(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pEvent: *mut VREvent_t,
uncbVREvent: u32
) -> bool
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
sourcepub unsafe fn GetOverlayInputMethod(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peInputMethod: *mut VROverlayInputMethod
) -> EVROverlayError
pub unsafe fn GetOverlayInputMethod(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
peInputMethod: *mut VROverlayInputMethod
) -> EVROverlayError
Returns the current input settings for the specified overlay.
sourcepub unsafe fn SetOverlayInputMethod(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eInputMethod: VROverlayInputMethod
) -> EVROverlayError
pub unsafe fn SetOverlayInputMethod(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eInputMethod: VROverlayInputMethod
) -> EVROverlayError
Sets the input settings for the specified overlay.
sourcepub unsafe fn GetOverlayMouseScale(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvecMouseScale: *mut HmdVector2_t
) -> EVROverlayError
pub unsafe fn GetOverlayMouseScale(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvecMouseScale: *mut HmdVector2_t
) -> EVROverlayError
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.
sourcepub unsafe fn SetOverlayMouseScale(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvecMouseScale: *const HmdVector2_t
) -> EVROverlayError
pub unsafe fn SetOverlayMouseScale(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvecMouseScale: *const HmdVector2_t
) -> EVROverlayError
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).
sourcepub unsafe fn ComputeOverlayIntersection(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pParams: *const VROverlayIntersectionParams_t,
pResults: *mut VROverlayIntersectionResults_t
) -> bool
pub unsafe fn ComputeOverlayIntersection(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pParams: *const VROverlayIntersectionParams_t,
pResults: *mut VROverlayIntersectionResults_t
) -> bool
Computes the overlay-space pixel coordinates of where the ray intersects the overlay with the specified settings. Returns false if there is no intersection.
sourcepub unsafe fn IsHoverTargetOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
pub unsafe fn IsHoverTargetOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
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
sourcepub unsafe fn SetOverlayIntersectionMask(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pMaskPrimitives: *mut VROverlayIntersectionMaskPrimitive_t,
unNumMaskPrimitives: u32,
unPrimitiveSize: u32
) -> EVROverlayError
pub unsafe fn SetOverlayIntersectionMask(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pMaskPrimitives: *mut VROverlayIntersectionMaskPrimitive_t,
unNumMaskPrimitives: u32,
unPrimitiveSize: u32
) -> EVROverlayError
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).
sourcepub unsafe fn TriggerLaserMouseHapticVibration(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fDurationSeconds: f32,
fFrequency: f32,
fAmplitude: f32
) -> EVROverlayError
pub unsafe fn TriggerLaserMouseHapticVibration(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
fDurationSeconds: f32,
fFrequency: f32,
fAmplitude: f32
) -> EVROverlayError
Triggers a haptic event on the laser mouse controller for the specified overlay
sourcepub unsafe fn SetOverlayCursor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulCursorHandle: u64
) -> EVROverlayError
pub unsafe fn SetOverlayCursor(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
ulCursorHandle: u64
) -> EVROverlayError
Sets the cursor to use for the specified overlay. This will be drawn instead of the generic blob when the laser mouse is pointed at the specified overlay
sourcepub unsafe fn SetOverlayCursorPositionOverride(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvCursor: *const HmdVector2_t
) -> EVROverlayError
pub unsafe fn SetOverlayCursorPositionOverride(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvCursor: *const HmdVector2_t
) -> EVROverlayError
Sets the override cursor position to use for this overlay in overlay mouse coordinates. This position will be used to draw the cursor instead of whatever the laser mouse cursor position is.
sourcepub unsafe fn ClearOverlayCursorPositionOverride(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
pub unsafe fn ClearOverlayCursorPositionOverride(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
Clears the override cursor position for this overlay
sourcepub unsafe fn SetOverlayTexture(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pTexture: *const Texture_t
) -> EVROverlayError
pub unsafe fn SetOverlayTexture(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pTexture: *const Texture_t
) -> EVROverlayError
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
sourcepub unsafe fn ClearOverlayTexture(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
pub unsafe fn ClearOverlayTexture(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> EVROverlayError
Use this to tell the overlay system to release the texture set for this overlay.
sourcepub unsafe fn SetOverlayRaw(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvBuffer: *mut c_void,
unWidth: u32,
unHeight: u32,
unBytesPerPixel: u32
) -> EVROverlayError
pub unsafe fn SetOverlayRaw(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pvBuffer: *mut c_void,
unWidth: u32,
unHeight: u32,
unBytesPerPixel: u32
) -> EVROverlayError
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.
sourcepub unsafe fn SetOverlayFromFile(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchFilePath: *const c_char
) -> EVROverlayError
pub unsafe fn SetOverlayFromFile(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pchFilePath: *const c_char
) -> EVROverlayError
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
sourcepub unsafe fn ReleaseNativeOverlayHandle(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pNativeTextureHandle: *mut c_void
) -> EVROverlayError
pub unsafe fn ReleaseNativeOverlayHandle(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pNativeTextureHandle: *mut c_void
) -> EVROverlayError
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.
sourcepub unsafe fn GetOverlayTextureSize(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pWidth: *mut u32,
pHeight: *mut u32
) -> EVROverlayError
pub unsafe fn GetOverlayTextureSize(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
pWidth: *mut u32,
pHeight: *mut u32
) -> EVROverlayError
Get the size of the overlay texture
sourcepub unsafe fn CreateDashboardOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pchOverlayFriendlyName: *const c_char,
pMainHandle: *mut u64,
pThumbnailHandle: *mut u64
) -> EVROverlayError
pub unsafe fn CreateDashboardOverlay(
self: Pin<&mut IVROverlay>,
pchOverlayKey: *const c_char,
pchOverlayFriendlyName: *const c_char,
pMainHandle: *mut u64,
pThumbnailHandle: *mut u64
) -> EVROverlayError
Creates a dashboard overlay and returns its handle
sourcepub unsafe fn IsDashboardVisible(self: Pin<&mut IVROverlay>) -> bool
pub unsafe fn IsDashboardVisible(self: Pin<&mut IVROverlay>) -> bool
Returns true if the dashboard is visible
sourcepub unsafe fn IsActiveDashboardOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
pub unsafe fn IsActiveDashboardOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64
) -> bool
returns true if the dashboard is visible and the specified overlay is the active system Overlay
sourcepub unsafe fn SetDashboardOverlaySceneProcess(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unProcessId: u32
) -> EVROverlayError
pub unsafe fn SetDashboardOverlaySceneProcess(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
unProcessId: u32
) -> EVROverlayError
Sets the dashboard overlay to only appear when the specified process ID has scene focus
sourcepub unsafe fn GetDashboardOverlaySceneProcess(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punProcessId: *mut u32
) -> EVROverlayError
pub unsafe fn GetDashboardOverlaySceneProcess(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
punProcessId: *mut u32
) -> EVROverlayError
Gets the process ID that this dashboard overlay requires to have scene focus
sourcepub unsafe fn ShowDashboard(
self: Pin<&mut IVROverlay>,
pchOverlayToShow: *const c_char
)
pub unsafe fn ShowDashboard(
self: Pin<&mut IVROverlay>,
pchOverlayToShow: *const c_char
)
Shows the dashboard.
sourcepub unsafe fn GetPrimaryDashboardDevice(self: Pin<&mut IVROverlay>) -> u32
pub unsafe fn GetPrimaryDashboardDevice(self: Pin<&mut IVROverlay>) -> u32
Returns the tracked device that has the laser pointer in the dashboard
sourcepub unsafe fn ShowKeyboard(
self: Pin<&mut IVROverlay>,
eInputMode: EGamepadTextInputMode,
eLineInputMode: EGamepadTextInputLineMode,
unFlags: u32,
pchDescription: *const c_char,
unCharMax: u32,
pchExistingText: *const c_char,
uUserValue: u64
) -> EVROverlayError
pub unsafe fn ShowKeyboard(
self: Pin<&mut IVROverlay>,
eInputMode: EGamepadTextInputMode,
eLineInputMode: EGamepadTextInputLineMode,
unFlags: u32,
pchDescription: *const c_char,
unCharMax: u32,
pchExistingText: *const c_char,
uUserValue: u64
) -> EVROverlayError
Show the virtual keyboard to accept input. In most cases, you should pass KeyboardFlag_Modal to enable modal overlay behavior on the keyboard itself. See EKeyboardFlags for more.
sourcepub unsafe fn ShowKeyboardForOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eInputMode: EGamepadTextInputMode,
eLineInputMode: EGamepadTextInputLineMode,
unFlags: u32,
pchDescription: *const c_char,
unCharMax: u32,
pchExistingText: *const c_char,
uUserValue: u64
) -> EVROverlayError
pub unsafe fn ShowKeyboardForOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
eInputMode: EGamepadTextInputMode,
eLineInputMode: EGamepadTextInputLineMode,
unFlags: u32,
pchDescription: *const c_char,
unCharMax: u32,
pchExistingText: *const c_char,
uUserValue: u64
) -> EVROverlayError
Show the virtual keyboard to accept input for an overlay. In most cases, you should pass KeyboardFlag_Modal to enable modal overlay behavior on the keyboard itself. See EKeyboardFlags for more.
sourcepub unsafe fn GetKeyboardText(
self: Pin<&mut IVROverlay>,
pchText: *mut c_char,
cchText: u32
) -> u32
pub unsafe fn GetKeyboardText(
self: Pin<&mut IVROverlay>,
pchText: *mut c_char,
cchText: u32
) -> u32
Get the text that was entered into the text input
sourcepub unsafe fn HideKeyboard(self: Pin<&mut IVROverlay>)
pub unsafe fn HideKeyboard(self: Pin<&mut IVROverlay>)
Hide the virtual keyboard
sourcepub unsafe fn SetKeyboardTransformAbsolute(
self: Pin<&mut IVROverlay>,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToKeyboardTransform: *const HmdMatrix34_t
)
pub unsafe fn SetKeyboardTransformAbsolute(
self: Pin<&mut IVROverlay>,
eTrackingOrigin: ETrackingUniverseOrigin,
pmatTrackingOriginToKeyboardTransform: *const HmdMatrix34_t
)
Set the position of the keyboard in world space
sourcepub unsafe fn SetKeyboardPositionForOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
avoidRect: impl ValueParam<HmdRect2_t>
)
pub unsafe fn SetKeyboardPositionForOverlay(
self: Pin<&mut IVROverlay>,
ulOverlayHandle: u64,
avoidRect: impl ValueParam<HmdRect2_t>
)
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
sourcepub unsafe fn ShowMessageOverlay(
self: Pin<&mut IVROverlay>,
pchText: *const c_char,
pchCaption: *const c_char,
pchButton0Text: *const c_char,
pchButton1Text: *const c_char,
pchButton2Text: *const c_char,
pchButton3Text: *const c_char
) -> VRMessageOverlayResponse
pub unsafe fn ShowMessageOverlay(
self: Pin<&mut IVROverlay>,
pchText: *const c_char,
pchCaption: *const c_char,
pchButton0Text: *const c_char,
pchButton1Text: *const c_char,
pchButton2Text: *const c_char,
pchButton3Text: *const c_char
) -> VRMessageOverlayResponse
Show the message overlay. This will block and return you a result.
sourcepub unsafe fn CloseMessageOverlay(self: Pin<&mut IVROverlay>)
pub unsafe fn CloseMessageOverlay(self: Pin<&mut IVROverlay>)
If the calling process owns the overlay and it’s open, this will close it.
Trait Implementations
sourceimpl Drop for IVROverlay
impl Drop for IVROverlay
sourcefn drop(self: &mut IVROverlay)
fn drop(self: &mut IVROverlay)
Synthesized destructor.
sourceimpl ExternType for IVROverlay
impl ExternType for IVROverlay
type Kind = Opaque
type Kind = Opaque
Either cxx::kind::Opaque
or cxx::kind::Trivial
. Read more
sourceimpl MakeCppStorage for IVROverlay
impl MakeCppStorage for IVROverlay
sourceunsafe fn allocate_uninitialized_cpp_storage() -> *mut IVROverlay
unsafe fn allocate_uninitialized_cpp_storage() -> *mut IVROverlay
Allocates heap space for this type in C++ and return a pointer to that space, but do not initialize that space (i.e. do not yet call a constructor). Read more
sourceunsafe fn free_uninitialized_cpp_storage(arg0: *mut IVROverlay)
unsafe fn free_uninitialized_cpp_storage(arg0: *mut IVROverlay)
Frees a C++ allocation which has not yet had a constructor called. Read more
Auto Trait Implementations
impl RefUnwindSafe for IVROverlay
impl !Send for IVROverlay
impl !Sync for IVROverlay
impl !Unpin for IVROverlay
impl UnwindSafe for IVROverlay
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more