ViaCognita
(ViaCognita)
December 28, 2024, 10:39am
1
Hey there!
I’m using Unreal Engine 5.4.4.
I’m learning how to develop a VR game with C++. To do it, I’m checking the Blueprint’s VR Template project. My first thing I’m doing is replicate the blueprint VR Pawn in C++. This is what I’ve done in my project:
I have added the OpenXR and OpenXRHandTracking:
These plugins are enabled in the .uproject:
"Plugins": [
{
"Name": "ModelingToolsEditorMode",
"Enabled": true
},
{
"Name": "OpenXR",
"Enabled": true,
"SupportedTargetPlatforms": [
"Win64",
"Linux",
"Android",
"VisionOS"
]
},
{
"Name": "OpenXRHandTracking",
"Enabled": true,
"SupportedTargetPlatforms": [
"Win64",
"Linux",
"Android",
"VisionOS"
]
}
]
But in MyGame.Build.cs I have added this:
PublicDependencyModuleNames.AddRange(new string[]
{
"Core",
"CoreUObject",
"Engine",
"InputCore",
"EnhancedInput",
"XRBase",
"HeadMountedDisplay",
"UMG"
});
Do I have to add XRBase
module here or OpenXR
?
How can I fix this warning?
Thanks!
Rectus_SA
(Rectus)
December 28, 2024, 2:34pm
2
Enabling the XRBase plugin from the plugins menu should fix the warning.
To access the XR system from C++ code, it is probably enough with those dependencies. You only need the OpenXR module there if you need any of the few features that aren’t abstracted by the HeadMountedDisplay module.
2 Likes
ViaCognita
(ViaCognita)
December 28, 2024, 2:35pm
3
Thanks for your answer.
Is there any documentation, video or tutorial about how to start developing VR with OpenXR and C++?
Thanks again.
ViaCognita
(ViaCognita)
December 28, 2024, 2:38pm
4
By the way, the XRBase plugin is already enabled:
But it isn’t in the .uproject
file:
"Plugins": [
{
"Name": "ModelingToolsEditorMode",
"Enabled": true
},
{
"Name": "OpenXR",
"Enabled": true,
"SupportedTargetPlatforms": [
"Win64",
"Linux",
"Android",
"VisionOS"
]
},
{
"Name": "OpenXRHandTracking",
"Enabled": true,
"SupportedTargetPlatforms": [
"Win64",
"Linux",
"Android",
"VisionOS"
]
}
]
Rectus_SA
(Rectus)
December 28, 2024, 2:44pm
5
I haven’t seen any documentation anywhere at least.
Try unchecking and checking the plugin. It’s probably been implicitly enabled by the OpenXR plugin.
system
(system)
Closed
January 27, 2025, 2:44pm
6
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.