Skip to content

Conversation

BastiaanOlij
Copy link
Contributor

@BastiaanOlij BastiaanOlij commented May 28, 2025

This PR adds support for the Khronos OpenXR loader to the core of Godot.

This means that as long as the headset supports it, and you don't use any vendor features or have features locked behind vendor specific manifest entries, Godot can export to a headset without needing the vendor plugin.

This is the first step in turning the vendor plugin purely into a plugin that exposes vendor features.

Note: there is a problem with the loader for OpenXR 1.x.41, which is the version we're currently on. You can override the default behaviour by specifying the loader version to use in the export settings. 1.1.47 (currently the latest version) works fine:
image

I'm planning to update the third-party folder to 1.1.48 as soon as its released and waiting on that before this PR should be merged.

If a custom loader is added through a plugin, this property can be set to disabled:
image
Bit of a hidden feature but this really is designed to be set using option_override (which will also hide the field).

This will only disable adding the dependency, it will not remove the manifest additions Khronos requires. Those will now always be added if OpenXR is selected as the XR Mode.

Due to this, changes to the vendors plugin are required as well as it now doubles up setting manifest entries and the loader dependency.

Finally I'll likely add some improvements to the way we obtain function pointers as we're doubling up loader logic but that may become a separate PR.

Tested on:

  • Quest 3
  • Pico 4 Ultra

Contributed by Khronos Group through the Godot Integration Project

@BastiaanOlij
Copy link
Contributor Author

cc @dsnopek @m4gr3d

@BastiaanOlij BastiaanOlij force-pushed the openxr_core_android_loader branch 4 times, most recently from e16eb1d to 15ecdbd Compare May 28, 2025 06:04
@BastiaanOlij BastiaanOlij modified the milestones: 4.5, 4.6 May 30, 2025
@BastiaanOlij BastiaanOlij force-pushed the openxr_core_android_loader branch from 15ecdbd to 918d224 Compare June 2, 2025 06:14
@BastiaanOlij BastiaanOlij marked this pull request as ready for review June 2, 2025 06:14
@BastiaanOlij BastiaanOlij requested review from a team as code owners June 2, 2025 06:14
@BastiaanOlij
Copy link
Contributor Author

I'm taking this out of draft as it is working. This should not be merged until after we've updated the OpenXR version in the thirdparty folder to atleast 1.1.46

Opinion among the XR team is to also hold off merging until Godot 4.5 has been released as accompanying changes on the vendor plugin side will require some guidance.

@BastiaanOlij BastiaanOlij force-pushed the openxr_core_android_loader branch from 918d224 to f1de29a Compare June 4, 2025 05:47
@BastiaanOlij
Copy link
Contributor Author

Rebased so it should now automatically pick up the OpenXR loader for 1.1.47 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant