584 out.m[0][1] = tm.M[1][0];
585 out.m[1][1] = tm.M[1][1];
586 out.m[2][1] = tm.M[1][2];
588 out.m[0][2] = tm.M[2][0];
589 out.m[1][2] = tm.M[2][1];
590 out.m[2][2] = tm.M[2][2];
592 out.m[0][3] = tm.M[3][0];
593 out.m[1][3] = tm.M[3][1];
594 out.m[2][3] = tm.M[3][2];
602 UFUNCTION(BlueprintPure, Category =
"VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf =
"true",
DisplayName =
"GetOpenVRHMDType"))
606 UFUNCTION(BlueprintPure, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetOpenVRControllerType"))
610 UFUNCTION(BlueprintPure, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true"))
611 static
bool IsOpenVRDeviceConnected(int32 DeviceIndex);
614 UFUNCTION(BlueprintPure, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true"))
618 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true"))
622 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true"))
627 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true", WorldContext = "WorldContextObject",
DisplayName = "GetVRDeviceModelAndTexture", ExpandEnumAsExecs = "Result", AdvancedDisplay = "OverrideDeviceID"))
628 static UTexture2D * GetVRDeviceModelAndTexture(
UObject* WorldContextObject, FString RenderModelNameOverride, FString & RenderModelNameOut,
EBPOpenVRTrackedDeviceClass DeviceType, TArray<UProceduralMeshComponent *> ProceduralMeshComponentsToFill,
bool bCreateCollision,
EAsyncBlueprintResultSwitch &Result, int32 OverrideDeviceID = -1);
631 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyString", ExpandEnumAsExecs = "Result"))
635 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyBool", ExpandEnumAsExecs = "Result"))
639 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyFloat", ExpandEnumAsExecs = "Result"))
643 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyInt32", ExpandEnumAsExecs = "Result"))
647 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyUInt64", ExpandEnumAsExecs = "Result"))
651 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRDevicePropertyMatrix34AsTransform", ExpandEnumAsExecs = "Result"))
657 UFUNCTION(BlueprintPure, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "HasVRCamera"))
661 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "GetVRCameraFrame", ExpandEnumAsExecs = "Result"))
665 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "CreateCameraTexture2D", ExpandEnumAsExecs = "Result"))
669 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "AcquireVRCamera", ExpandEnumAsExecs = "Result"))
673 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "ReleaseVRCamera", ExpandEnumAsExecs = "Result"))
677 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|VRCamera", meta = (bIgnoreSelf = "true",
DisplayName = "IsValid"))
683 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
684 static
bool SetSkyboxOverride_LatLong(UTexture2D * LatLongSkybox);
687 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
688 static
bool SetSkyboxOverride_LatLongStereoPair(UTexture2D * LatLongSkyboxL, UTexture2D * LatLongSkyboxR);
691 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
692 static
bool SetSkyboxOverride(UTexture * tFront, UTexture2D * tBack, UTexture * tLeft, UTexture * tRight, UTexture * tTop, UTexture * tBottom);
695 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
696 static
bool ClearSkyboxOverride();
701 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
702 static
bool FadeHMDToColor(
float fSeconds, FColor Color,
bool bBackground = false);
706 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
707 static
bool GetCurrentHMDFadeColor(FColor & ColorOut,
bool bBackground = false);
710 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
711 static
bool FadeVRGrid(
float fSeconds,
bool bFadeIn);
714 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
715 static
bool GetCurrentVRGridAlpha(
float & VRGridAlpha);
719 UFUNCTION(BlueprintCallable, Category = "VRExpansionFunctions|SteamVR|Compositor", meta = (bIgnoreSelf = "true"))
720 static
bool SetSuspendRendering(
bool bSuspendRendering);
722#if STEAMVR_SUPPORTED_PLATFORM
723 static vr::Texture_t CreateOpenVRTexture_t(UTexture * Texture)
725 vr::Texture_t VRTexture;
728 VRTexture.handle = Texture->Resource->TextureRHI->GetNativeResource();
730 VRTexture.handle = NULL;
732 VRTexture.eColorSpace = vr::EColorSpace::ColorSpace_Auto;
734 VRTexture.eType = vr::ETextureType::TextureType_OpenGL;
736 VRTexture.eType = vr::ETextureType::TextureType_IOSurface;
738 if (IsPCPlatform(GMaxRHIShaderPlatform))
740 if (IsVulkanPlatform(GMaxRHIShaderPlatform))
742 VRTexture.eType = vr::ETextureType::TextureType_Vulkan;
744 else if (IsOpenGLPlatform(GMaxRHIShaderPlatform))
746 VRTexture.eType = vr::ETextureType::TextureType_OpenGL;
751 VRTexture.eType = vr::ETextureType::TextureType_DirectX;