Navigation
API > API/Plugins > API/Plugins/XRBase
| Name | UHeadMountedDisplayFunctionLibrary |
| Type | class |
| Header File | /Engine/Plugins/Runtime/XRBase/Source/XRBase/Public/HeadMountedDisplayFunctionLibrary.h |
| Include Path | #include "HeadMountedDisplayFunctionLibrary.h" |
Syntax
UCLASS (MinimalAPI)
class UHeadMountedDisplayFunctionLibrary : public UBlueprintFunctionLibrary
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UBlueprintFunctionLibrary → UHeadMountedDisplayFunctionLibrary
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UHeadMountedDisplayFunctionLibrary
(
const FObjectInitializer& ObjectInitializer |
HeadMountedDisplayFunctionLibrary.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| OnXRDeviceOnDisconnectDelegate | FXRDeviceOnDisconnectDelegate | HeadMountedDisplayFunctionLibrary.h | |
| OnXRTimedInputActionDelegateMap | TMap< FName, FXRTimedInputActionDelegate > | HeadMountedDisplayFunctionLibrary.h |
Functions
Public
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void BreakKey
(
FKey InKey, |
Breaks an XR key apart into the interaction profile, handedness, motion source, indentifier and component. | HeadMountedDisplayFunctionLibrary.h |
|
static void CalibrateExternalTrackingToHMD
(
const FTransform& ExternalTrackingTransform |
Called to calibrate the offset transform between an external tracking source and the internal tracking source (e.g. mocap tracker to and HMD tracker). | HeadMountedDisplayFunctionLibrary.h |
|
static void ClearXRTimedInputActionDelegate
(
const FName& ActionPath |
HeadMountedDisplayFunctionLibrary.h |
|
|
static EXRDeviceConnectionResult::Type ConnectRemoteXRDevice
(
const FString& IpAddress, |
Connect to a remote deviceConnect to a remote device for Remote Debugging | HeadMountedDisplayFunctionLibrary.h |
|
static void DisconnectRemoteXRDevice() |
Disconnect remote AR Device | HeadMountedDisplayFunctionLibrary.h |
|
static bool EnableHMD
(
bool bEnable |
Switches to/from using HMD and stereo rendering. | HeadMountedDisplayFunctionLibrary.h |
|
static TArray< FXRDeviceId > EnumerateTrackedDevices
(
const FName SystemId, |
Cross XR-System query that will list all XR devices currently being tracked. | HeadMountedDisplayFunctionLibrary.h |
|
static bool GetControllerTransformForTime2
(
UObject* WorldContext, |
Get the transform and potentially velocity data at a specified time near the current frame in unreal world space. | HeadMountedDisplayFunctionLibrary.h |
|
static bool GetCurrentInteractionProfile
(
const EControllerHand Hand, |
Get the openXR interaction profile name for the given controller. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetDevicePose
(
const FXRDeviceId& XRDeviceId, |
Cross XR-System query that returns a specific device's tracked position and orientation (in tracking space). | HeadMountedDisplayFunctionLibrary.h |
|
static void GetDeviceWorldPose
(
UObject* WorldContext, |
Cross XR-System query that returns a specific device's position and orientation in world space. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetHandTrackingState
(
UObject* WorldContext, |
Cross XR-System query that returns critical information about the motion controller (position, orientation, hand/finger position) | HeadMountedDisplayFunctionLibrary.h |
|
static void GetHMDData
(
UObject* WorldContext, |
Cross XR-System query that returns critical information about the HMD display (position, orientation, device name) | HeadMountedDisplayFunctionLibrary.h |
|
static FName GetHMDDeviceName() |
Returns the name of the device, so scripts can modify their behaviour appropriately | HeadMountedDisplayFunctionLibrary.h |
|
static EHMDWornState::Type GetHMDWornState() |
Returns the worn state of the device. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetMotionControllerState
(
UObject* WorldContext, |
Cross XR-System query that returns critical information about the motion controller (position, orientation) | HeadMountedDisplayFunctionLibrary.h |
|
static int32 GetNumOfTrackingSensors() |
If the HMD has multiple positional tracking sensors, return a total number of them currently connected. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetOrientationAndPosition
(
FRotator& DeviceRotation, |
Grabs the current orientation and position for the HMD. | HeadMountedDisplayFunctionLibrary.h |
|
static float GetPixelDensity () |
Returns the current XR pixel density. | HeadMountedDisplayFunctionLibrary.h |
|
static FVector2D GetPlayAreaBounds
(
TEnumAsByte< EHMDTrackingOrigin::Type > Origin |
Get the bounds of the area where the user can freely move while remaining tracked centered around the specified origin | HeadMountedDisplayFunctionLibrary.h |
|
static bool GetPlayAreaRect
(
FTransform& OutTransform, |
Get the transform and dimensions of the playable area rectangle. | HeadMountedDisplayFunctionLibrary.h |
|
static TEnumAsByte< EHMDTrackingOrigin::Type > GetTrackingOrigin() |
Returns current tracking origin type (eye level or floor level). | HeadMountedDisplayFunctionLibrary.h |
|
static bool GetTrackingOriginTransform
(
TEnumAsByte< EHMDTrackingOrigin::Type > Origin, |
Get the transform of the specified tracking origin, if available. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetTrackingSensorParameters
(
FVector& Origin, |
If the HMD has a positional sensor, this will return the game-world location of it, as well as the parameters for the bounding region of tracking. | HeadMountedDisplayFunctionLibrary.h |
|
static FTransform GetTrackingToWorldTransform
(
UObject* WorldContext |
Returns a transform that can be used to convert points from tracking space to world space. | HeadMountedDisplayFunctionLibrary.h |
|
static FString GetVersionString() |
Returns name of tracking system specific version string. | HeadMountedDisplayFunctionLibrary.h |
|
static void GetVRFocusState
(
bool& bUseFocus, |
Returns current state of VR focus. | HeadMountedDisplayFunctionLibrary.h |
|
static float GetWorldToMetersScale
(
UObject* WorldContext |
Returns the World to Meters scale, which corresponds to the scale of the world as perceived by the player | HeadMountedDisplayFunctionLibrary.h |
|
static float GetXRSecondaryScreenPercentage () |
Returns the current XR secondary screen precentage. | HeadMountedDisplayFunctionLibrary.h |
|
static int32 GetXRSystemFlags() |
Returns the flags for the device, so scripts can modify their behaviour appropriately | HeadMountedDisplayFunctionLibrary.h |
|
static bool HasValidTrackingPosition() |
If the HMD supports positional tracking, whether or not we are currently being tracked | HeadMountedDisplayFunctionLibrary.h |
|
static bool IsDeviceTracking
(
const FXRDeviceId& XRDeviceId |
Cross XR-System query that returns whether the specified device is tracked or not. | HeadMountedDisplayFunctionLibrary.h |
|
static bool IsHeadMountedDisplayConnected () |
Returns whether or not the HMD hardware is connected and ready to use. | HeadMountedDisplayFunctionLibrary.h |
|
static bool IsHeadMountedDisplayEnabled() |
Returns whether or not we are currently using the head mounted display. | HeadMountedDisplayFunctionLibrary.h |
|
static bool IsSpectatorScreenModeControllable() |
Return true if spectator screen mode control is available. | HeadMountedDisplayFunctionLibrary.h |
|
static void ResetOrientationAndPosition
(
float Yaw, |
Resets orientation by setting roll and pitch to 0, assuming that current yaw is forward direction and assuming current position as a 'zero-point' (for positional tracking). | HeadMountedDisplayFunctionLibrary.h |
|
static void SetClippingPlanes
(
float Near, |
Sets near and far clipping planes (NCP and FCP) for stereo rendering. | HeadMountedDisplayFunctionLibrary.h |
|
static bool SetHMDColorScaleAndBias
(
FLinearColor ColorScale, |
Multiply the post-compositor frame by a color and add a bias. | HeadMountedDisplayFunctionLibrary.h |
|
static void SetSpectatorScreenMode
(
ESpectatorScreenMode Mode |
Sets the social screen mode. | HeadMountedDisplayFunctionLibrary.h |
|
static void SetSpectatorScreenModeTexturePlusEyeLayout
(
FVector2D EyeRectMin, |
Setup the layout for ESpectatorScreenMode::TexturePlusEye. | HeadMountedDisplayFunctionLibrary.h |
|
static void SetSpectatorScreenTexture
(
UTexture* InTexture |
Change the texture displayed on the social screen | HeadMountedDisplayFunctionLibrary.h |
|
static void SetTrackingOrigin
(
TEnumAsByte< EHMDTrackingOrigin::Type > Origin |
Sets current tracking origin type (eye level or floor level). | HeadMountedDisplayFunctionLibrary.h |
|
static void SetWorldToMetersScale
(
UObject* WorldContext, |
Sets the World to Meters scale, which changes the scale of the world as perceived by the player | HeadMountedDisplayFunctionLibrary.h |
|
static void SetXRDisconnectDelegate
(
const FXRDeviceOnDisconnectDelegate& InDisconnectedDelegate |
HeadMountedDisplayFunctionLibrary.h |
|
|
static void SetXRTimedInputActionDelegate
(
const FName& ActionName, |
Hook up a delegate to get an OpenXR action event with action time. | HeadMountedDisplayFunctionLibrary.h |
|
static void UpdateExternalTrackingHMDPosition
(
const FTransform& ExternalTrackingTransform |
Called after calibration to attempt to pull the internal tracker (e.g. HMD tracking) in line with the external tracker (e.g. mocap tracker). | HeadMountedDisplayFunctionLibrary.h |
|