-
-
Notifications
You must be signed in to change notification settings - Fork 35.5k
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
WebXR: Don't request hand-tracking
feature by default.
#27699
Conversation
Yes, this is fine |
Noted this change in the migration guide for |
But... How do we select/drag anything (create input events) on VisionOS if it's not with If we go into a WebXR session and we can't create any event... The only use case I can think of is watching a immersive video but we wouldn't even have controls for it. |
@@ -85,7 +85,11 @@ | |||
|
|||
container.appendChild( renderer.domElement ); | |||
|
|||
document.body.appendChild( VRButton.createButton( renderer ) ); | |||
const sessionInit = { | |||
optionalFeatures: [ 'hand-tracking' ] |
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.
Hmm, yeah... I guess in the handinput
examples it should be requiredFeatures
?
/ping @m-blix |
That doesn't work on Vision Pro anyway since Safari doesn't create events for hands. I'm unsure why they made that decision but it's unlikely to change. If you turn on WebXR hands on Vision OS 1.1, you may get 3 or 4 controllers (2 hands and 1/2 transient controllers). This is not supported by three at the moment since it only looks at the first 2 input sources. |
Sounds like we're going to have to rework all this 😔 |
I'm trying to clean up the spec so it's not as confusing but am getting pushback: immersive-web/webxr#1358 (comment) |
Just stubbed my toe on Apple's It's fine if they want their special transient pointers which work without hand tracking, but then they should also fire polyfilled events on the hands when they are granted so everybody else's apps aren't broken.
Hah! If you don't want workarounds, don't ship intentionally broken products and leave them that way for four months! I'm going to look into submitting a PR later that explores polyfilling the missing input logic and perhaps adding a framerate up-interpolator for their janky 30hz tracking so hands work better in three.js than their own native apps. I'm also thinking about contributing the PinchMoveControls from LeapShape to three.js as a more general camera/locomotion system (now that the camera parenting bug has been fixed...). |
@zalo amazing stuff! |
Fixed #27698.
Description
This PR ensures
VRButtons.createButton()
gets thesessionInit
parameter likeXRButton
andARButton
.Besides, the optional feature
hand-tracking
is not requested by default anymore to avoid unnecessary permission prompts in visionOS./cc @cabanier