Skip to content

OpenXR: Use GLTFDocument function to get supported extension names - #109630

Merged
Repiteo merged 1 commit into
godotengine:masterfrom
aaronfranke:openxr-gltf-doc-ext
Aug 21, 2025
Merged

Repiteo merged 1 commit into
godotengine:masterfrom
aaronfranke:openxr-gltf-doc-ext

Conversation

@aaronfranke

Copy link
Copy Markdown
Member

I came across this code added in PR #107388 with a redundant list of extensions, and this comment:

// Now find anything we support through plugins, which is a bit of a pain as they are converted to Strings
// and we need to convert them back.

It's actually not a pain, GLTFDocument has function exactly for this purpose. In fact, this function was actually requested for this purpose but forgotten about. So, this PR uses it. The only complexity still in the OpenXR code is to convert Godot's HashSet<String> to a Vector<const char *> to pass to OpenXR, and the logic has been updated to only resize the arrays once, avoiding dynamic memory allocation.

@aaronfranke aaronfranke added this to the 4.6 milestone Aug 15, 2025
@aaronfranke
aaronfranke requested a review from a team as a code owner August 15, 2025 06:55
Comment thread modules/openxr/extensions/openxr_render_model_extension.cpp Outdated
@fire
fire requested a review from a team August 15, 2025 14:17

@dsnopek dsnopek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

I just tested this with SteamVR (which supports this OpenXR render models extension) with the openxr_render_models demo and it worked fine!

Since this feature was added for Godot 4.5, I feel like fixing this issue for release with 4.5 could make sense, so I'm going to change the milestone. But if other folks disagree, we can switch it back to 4.6

@dsnopek dsnopek added bug and removed enhancement labels Aug 20, 2025
@dsnopek dsnopek modified the milestones: 4.6, 4.5 Aug 20, 2025
@Repiteo
Repiteo merged commit d5ad055 into godotengine:master Aug 21, 2025
39 of 40 checks passed
@Repiteo

Repiteo commented Aug 21, 2025

Copy link
Copy Markdown
Contributor

Thanks!

@aaronfranke
aaronfranke deleted the openxr-gltf-doc-ext branch August 21, 2025 14:25
BendyLand pushed a commit to BendyLand/voltaire that referenced this pull request Aug 2, 2026
…c-ext

OpenXR: Use GLTFDocument function to get supported extension names
wangshucheng pushed a commit to wangshucheng/godot that referenced this pull request Aug 27, 2026
…c-ext

OpenXR: Use GLTFDocument function to get supported extension names
Shane-Gadsby pushed a commit to Shane-Gadsby/godotwebgpu that referenced this pull request Sep 21, 2026
…c-ext

OpenXR: Use GLTFDocument function to get supported extension names
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.

4 participants