Closed dax72 closed 4 years ago
Hi, can you try the branch in PR #4548 and see if that fixes it?
is there a dist ready to download?
I couldn't find any relevant changes on the Safari release notes:
https://developer.apple.com/documentation/safari_release_notes
I just tried on another iPad (iPad Pro 12,9""), v13.4.1...same problem! Motion sensor does not work when you click VR button.
We should probably disable cardboard / stereo mode on iPads
and on iPhone? currently I can confirm that it does not work on iPhone and iPad with iOS13.4.1. VR mode on iPad has no sense..but on iPhone it's necessary
Got same issue, with my older iphone for tests with iOS 13.3 it does work properly, but newest 13.4.X it doesn't... as far as i checked DeviceMotionEvent.requestPermission()
doesn't seem to work right, it asks about permission, right after with my app it reloads page and and my typical promise that checks if it's gyroscope or if the device support gyroscope it saying "false" for iPhone with newest iOS :/ previous version was ok.
Also checked with DeviceOrientationEvent, doesn't help :(
On iPad we can disable. On iPhone we can keep for now. What’s your audience? Can you share details on your application? We see Cardboard usage decline and harder and harder to come by. Polyfilled VR comes with a lot of issues like this one where things break when browser APIs and policies change.
We create VR games/apps for clients and they require iPhone compatibility
Is iPhone compatibility via Magic Window mode enough? Do you have any metrics of cardboard usage you can share?
Magic Window mode it's not enough, they need stereo mode. I think the percentage of iPhone/cardboard is not relevant but clients require the compatibility iPhone/android and without it they do not market products.
Safari iOS from a development point of view is a nightmare because there is no webVR/webXR support but for big companies it is not their problem, they want it to work on iOS too :(
@dax72 Thanks for the info. Is your client decision based on any audience metrics?
@dmarcos Unfortunately I don't have access to their audience metrics, but I have more clients that are asking to me to fix this iOS bug
@dax72 Are they willing to pay to fix the issue?
For what it's worth, this also affects magic window tracking, not just VR mode.
Ok, did some investigating. 🕵🏻♂️
This was a regression in Webkit, reported on 2020-03-31: https://bugs.webkit.org/show_bug.cgi?id=209831 And patched same day by the reporter: https://github.com/WebKit/webkit/commit/13e78b2bad4fb6f8c8a152e9a3cfc07c910dc858
Unfortunately, considering that the changeset which introduced the bug was in December 2019: https://trac.webkit.org/changeset/253357/webkit And the bug only showed up just now in 13.4.1, it seems it's gonna take a really long time to see the patch fixing it make it's way into iOS.
Thanks for investigating. Super appreciated. Magic window still works for me on examples:
https://aframe.io/aframe/examples/
it’s a different code path
Oh, interesting! That's probably because our team is currently stuck on 0.9.2 for other reasons, which is using the webvr-polyfill / device motion api for magic window?
So scratch that. Can confirm that on latest aframe, magic window is fine.
Since iOS 13, Safari requires permission to access DeviceMotion. 0.9.2 doesn’t have the request logic. It predates iOS 13
Yeah, we manually call DeviceMotionEvent.requestPermission()
. Worked up until this bug. Same issue as VR mode in latest versions, lots of log spam TypeError: null is not an object (evaluating 'i.alpha')
from webvr-polyfill.
Does this pull request fix what is needed for aframe to work properly with iOS 13.4 in cardboard mode? https://github.com/immersive-web/cardboard-vr-display/pull/42 If so, what's the process for getting that incorporated? Does that PR have to get merged into immersive-web, and then immersive-web gets merged into a new point release for aframe?
@jwjordan Yes, best would be for that PR to merge and then for the webvr-polyfill to incorporate. A-Frame would pick a new version of the polyfill Alternative would be to maintain a fork of both repos that it's preferable to avoid.
webvr-polyfill 0.10.12 now has the changes from upstream cardboard-vr-display
@jsantell Yeah! Thank you very much. Super appreciated. I bumped the polyfill on master.
shout out to @jwjordan @ivnnv @machenmusik for the research & patches :tada:
Yeah. Thanks everybody 👏
Checked out master and tested in a VR model inside Ideaspace, and I can confirm this fixed the cardboard mode on the latest version of iOS (13.4.1) in my specific instance. Thanks a ton everyone!
Awesome! When does 1.0.5 release? :)
It’ll be 1.1.0 in a few days depending on how QA goes. In the meantime you can use master builds
Nice even better! I hope it goes well. Thank you @dmarcos and thankyou to everyone who worked on this
And of course...everything works just like normal again in iOS 13.5 beta 5 using 1.0.4...
Thanks for reporting
I can confirm commit cd01cec works.
I assume commit a326ceb will continue to have this update.
Hello @dmarcos I'm getting an error with the cd01cec35a01e03eb2d6a9272500a53de31d3828 version. On this [url]() you can see the error when you focus the pointer on the green marks
index.js:96 Uncaught TypeError: Cannot read property 'array' of undefined at TextGeometry.computeBoundingSphere (index.js:96) at H.raycast (three.js:11367) at Fa (three.js:46525) at Ba.intersectObjects (three.js:46600) at i.checkIntersections (raycaster.js:226) at i.tick (raycaster.js:198) at HTMLElement.tick (a-scene.js:719) at HTMLElement.render (a-scene.js:769) at bind.js:12 at m (three.js:25084)
With version 1.0.4 this doesn't happen, but VR is not working on iOS 13...
@jgutierro that commit looks like it was moved to master. I get that same issue on master branch as well. You might want submit a new ticket or even take a look / revive https://github.com/aframevr/aframe/issues/3318
Your issue seems unrelated to VR mode not working on iOS
. Best to open a separate issue as @NomisGnos mentioned
Hello @NomisGnos and @dmarcos thank you for your answer. I know that commit is moved to master. But I replied here because I guess this TextGeometry error it's caused by this new fixed version for safari, because with the 1.0.4 version it's working fine.
@jgutierro I recommend opening a new issue or information will get lost. Make sure you provide a link to reproduce. Thanks!
Hello @dmarcos, if I try to insert on a iOS WebKit this url https://app.estudiocactus.com/clickandrender/ (it's the master commit aframe version cd01cec35a01e03eb2d6a9272500a53de31d3828) is not working. Do you have any idea why? Because it's working fine if I open directly on safari
Hello @dmarcos and @NomisGnos I opened a new issue and finally was solved! https://github.com/aframevr/aframe/issues/4618#issuecomment-642433783
Thank you so much!
Gyroscope movement does not work, it works fine before ios13.4.1 update or without turning on vr mode.