-
-
Notifications
You must be signed in to change notification settings - Fork 100
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] Add basic support for WebXR AR module #1507
Conversation
Note that this is increasing the version of the protocol used to talk to the Web Engine during WebXR sessions. This means that this change breaks WebXR support. We need to land the chromium backend change and also upload a new patch for Gecko to adapt it to work with this new protocol version. |
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.
This change looks good now.
This change requires Igalia/wolvic-gecko-patches#5, otherwise WebXR will break in the Gecko backend |
The Assertions.h file was using a Throw() inline method defined in OpenXRHelpers.h in several macros. There were several problems with that: 1. The macros would only work if the file including Assertions.h was also including OpenXRHelpers.h. That's wrong, Assertions.h should not depend on that 2. Assertions.h should not have any dependency with OpenXR headers This was unnoticed because files using those macros were already including OpenXRHelpers.h. As soon as I tried to use it in non OpenXR files it started to generate compiler errors.
Wolvic can now start and render WebXR's immersive-ar sessions for those devices supporting passthrough, either via non-opaque blend modes or passthrough compositor layers. This requires a few changes in the communication protocol with the web engine: 1. pass the available blend modes to the web engine so it can select the desired one depending on the requested WebXR session. 2. use the selected blend mode from the web engine to render the immersive scene 3. notify Wolvic about the type of WebXR session (AR/VR) Change #3 is required for those devices that do support passthrough but not via AR blend modes. Examples of those are the Meta devices that implement passthrough via a passthrough compositor layer. Note that WebXR's session type will prevail over the current passthrough status in standalone mode. There are 4 different scenarios (PT stands for passthrough): 1. PT ON, VR session: PT will be disabled on entering and reenabled on exiting 2. PT ON, AR session: PT will be activated all the time 3. PT OFF, VR session: PT will be off all the time 4. PT OFF, AR session: PT will be activated on entering and reenabled on exiting This change requires Igalia/wolvic-chromium#114 which implements the required bits on the Chromium backend.
Wolvic can now start and render WebXR's immersive-ar sessions for those devices supporting passthrough, either via non-opaque blend modes or passthrough compositor layers.
This requires a few changes in the communication protocol with the web engine:
Change #3 is required for those devices that do support passthrough but not via AR blend modes. Examples of those are the Meta devices that implement passthrough via a passthrough compositor layer.
Note that WebXR's session type will prevail over the current passthrough status in standalone mode. There are 4 different scenarios (PT stands for passthrough):
This change requires
Igalia/wolvic-chromium#114 which implements the required bits on the Chromium backend.
Fixes #242