Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OpenXR: Allow moving vendor passthrough extensions to GDExtension #87630
OpenXR: Allow moving vendor passthrough extensions to GDExtension #87630
Changes from all commits
e74a0f4
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can do this automatically on our end instead of letting the gdextension dictates whether this should be set or not, by going through the list of gdextensions and checking their return values to
is_environment_blend_mode_alpha_blend_supported()
.This would mitigate the issue where multiple gdextensions can be loaded each with different level of support. For example, one gdextension may have full support while the other may only be able to emulate support. The latter would set this flag which would cause the logic to assume that emulation is required when it's not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't entirely understand this suggestion.
Are you saying that we should add some method on
OpenXRExtensionWrapperExtension
which allows the extension to tell Godot that it's going to emulateALPHA_BLEND
and we'll loop over all the extensions and call it? At first glance, that doesn't seem any simpler. But I'm probably misunderstanding?I don't think we'll encounter situations with multiple extensions that have "full" vs "emulated" support. The only way "full" support happens is if the runtime reports that it supports
ALPHA_BLEND
, in which case no extension is needed.The situation with multiple extensions that I forsee is where the runtime supports multiple passthrough extensions for compatibility, for example, maybe HTC devices would support their passthrough extension but then also the Meta one to make it easy for developers to port their apps. So, we just need to make sure that both extensions don't try to do emulation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it, thanks for the clarification!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it safe to always add
OpenXRCompositionLayerProvider
here? Most extensions won't be a composition layer provider.I think we need a
OpenXRCompositionLayerProviderWrapperExtension
(damn thats a mouth full) wrapper that inherits fromOpenXRExtensionWrapperExtension
andOpenXRCompositionLayerProvider
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could make a new extension class, however, nothing special is done with an
OpenXRCompositionLayerProvider
until you callopenxr_api->register_composition_layer_provider()
, so I think it's safe for them to always beOpenXRCompositionLayerProvider
, since only the extensions that really need to do anything for that will register themselves.