Skip to content
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

[DRAFT] Add support for the Android XR OpenXR vendor #238

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

m4gr3d
Copy link
Collaborator

@m4gr3d m4gr3d commented Dec 23, 2024

This PR adds support for the Android XR OpenXR vendor, which will provide the ability to run Godot XR apps on Android XR devices via the vendor plugin.

  • This is a draft PR as the Android XR emulator doesn't support OpenXR apps, and no Android XR devices is yet available for testing, so no testing / validation is feasible at the moment. The PR will remain in this state until we're able to test and validate the functionality.
  • While Android XR uses the Khronos loader, the platform introduces its own set of permissions and manifest entries which prevents us from using the Khronos vendor logic, and requires us to create and use a separate Android vendor.
  • This PR limits itself to the OpenXR extensions already supported in Godot core and the vendors plugin. Android XR introduces a new set of OpenXR extensions which we may add support for in future PRs.

@m4gr3d m4gr3d added the enhancement New feature or request label Dec 23, 2024
@m4gr3d m4gr3d added this to the 4.x milestone Dec 23, 2024
Comment on lines 39 to 84
android {
dimension "vendor"
ndk {
//noinspection ChromeOsAbiSupport
abiFilters 'arm64-v8a', 'x86_64'
}
externalNativeBuild {
cmake {
arguments "-DFLAVOR=android"
}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do we really need another AAR built? We've never used the FLAVOR define in the C++ anywhere - could we just use the Khronos AAR for Android too?

(The same goes for MagicLeap - I think we could reuse the Khronos AAR for that as well)

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ah, I guess it's because the Java code is different.

Well, after PR #227 is merged, this won't be as big of a deal because with that one we do only one C++ build, and then each of the Java builds just reuses the artifacts of that :-)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes the new flavor is primarily for the difference in the java code and the manifest. The C++ code and configuration is the same as the others.

@dsnopek
Copy link
Collaborator

dsnopek commented Jan 7, 2025

Ah, I guess you noted it above (I didn't read the description too carefully :-)) but this is the most disappointing thing:

Selection_256

I can't wait until we can test Android XR, even in an emulator!

@m4gr3d m4gr3d force-pushed the add_android_vendors branch from 189e37d to 0607bdd Compare January 11, 2025 00:13
@m4gr3d m4gr3d force-pushed the add_android_vendors branch from 0607bdd to 982fc9d Compare January 28, 2025 02:27
m4gr3d added a commit to m4gr3d/godot_openxr_vendors that referenced this pull request Jan 28, 2025
@m4gr3d m4gr3d mentioned this pull request Jan 28, 2025
@m4gr3d m4gr3d force-pushed the add_android_vendors branch from 982fc9d to aeeb41b Compare January 28, 2025 02:37
@m4gr3d m4gr3d force-pushed the add_android_vendors branch from aeeb41b to 0226ae9 Compare January 28, 2025 02:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants