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

[OpenXR] Fix a regression when emulating a controller in WebXR #1512

Merged
merged 1 commit into from
Aug 13, 2024

Conversation

svillar
Copy link
Member

@svillar svillar commented Aug 12, 2024

When eye tracking navigation was introduced in c94ab62 it required some changes in the code that emulates a controller from a hand. It was basically just making that code aware of eye tracking in order not to use the hand aim but the eye gaze.

That required some code refactorings. In one of them the grip space flag was removed from the initialization of flags and set later inside an if block. The problem was that we were setting that flag but at the same time removing the previous ones as we used a " = " instead of a " |= ".

When eye tracking navigation was introduced in c94ab62 it required
some changes in the code that emulates a controller from a hand. It
was basically just making that code aware of eye tracking in order
not to use the hand aim but the eye gaze.

That required some code refactorings. In one of them the grip space
flag was removed from the initialization of flags and set later
inside an if block. The problem was that we were setting that flag
but at the same time removing the previous ones as we used a " = "
instead of a " |= ".
@svillar
Copy link
Member Author

svillar commented Aug 12, 2024

It's easy to test

  1. Open Moonrider
  2. Controllers do not move

Works as expected with the patch

Copy link
Contributor

@felipeerias felipeerias left a comment

Choose a reason for hiding this comment

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

LGTM

Straightforward fix, the test works as expected in Moon Rider.

@svillar svillar merged commit 0af8d2b into main Aug 13, 2024
22 checks passed
@svillar svillar deleted the webxr_emulate_controller_regression branch August 13, 2024 07:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants