JeremyHeleine / Photo-Sphere-Viewer

A JavaScript library to display Photo Sphere panoramas.
855 stars 953 forks source link

Gyroscope and VR features don't work on iPhone #12

Open AdamCampbell opened 9 years ago

AdamCampbell commented 9 years ago

When testing this library I have noticed that gyroscope features and VR works well on Android but doesn't work on iPhone. Would it take much to add support?

AdamCampbell commented 9 years ago

Just did some digging and saw the issue on your screen sphere orientation library. It's a shame that mobile safari doesn't support these features.

AdamCampbell commented 9 years ago

Seems this is close to a polyfill for the API.. https://gist.github.com/JamesEggers1/1904283 I don't particularly like that you have to add jQuery to use it. However if it works it works. I'm not a web developer so, to you does this seem usable?

AdamCampbell commented 9 years ago

Also this: https://github.com/Financial-Times/polyfill-service/blob/master/polyfills/screen/orientation/polyfill.js But I feel you need the event stuff..

JeremyHeleine commented 9 years ago

Hi,

Yeah, the limitations of using a feature that is currently just a draft… I'll look at these solutions if they're good, but I don't want to add any external library (Three.js is here temporarily, my own 3D renderer is in works).

mchampa commented 8 years ago

Hi Jeremy, Wondering if you were able to fix gyroscope access for IPhone. It works here: http://viewer.spherecast.org/upload http://sphcst.com/h01nc

JeremyHeleine commented 8 years ago

Hi,

I guess the right APIs are finally available in iOS. I'll see if I can fix the bug affecting Photo Sphere Viewer (it's difficult without using a real iOS device but it's not impossible :) ). Thanks for noticing me that the issue can be fixed.

mchampa commented 8 years ago

Thanks Jeremy! I can help test if you want. Just shoot over any URLs to test. Thanks.

JeremyHeleine commented 8 years ago

Hi, The library used to play with the gyroscope has been updated. If it's possible for you, you can test it here.

mchampa commented 8 years ago

Thanks Jeremy. I did a quick test on an Ipad 3rd gen. The sample image test shows some response to the gyroscope, but only shows the dirt portion of the image rotating when moving the ipad. I'll do an iphone test shortly. Let me know how else I can help.

mchampa commented 8 years ago

Hey Jeremy, I tested the test page on an iphone 6 and it worked really well. Gyroscope worked after clicking the gyro icon on the viewer. split screen worked as well. Great job!

JeremyHeleine commented 8 years ago

Thanks for your tests! Actually, it's Thomas Gustavo who deserves the congratulations, as he found how to fix the bug. :)

About the issue you encountered on the iPad, is the panorama correctly displayed without the gyroscope?

mchampa commented 8 years ago

Thanks Thomas too! Clicking the gyro icon in the viewer menu to toggle off the gyro control provides identical interaction compared to the gyro enabled interaction...looking at dirt.

mchampa commented 8 years ago

Hi Jeremy, wondering if any more progress has been made on the IOS updates? I can help test. Thank you.

JeremyHeleine commented 8 years ago

Hi, not for the moment, sadly, but I don't give up. :)