aframevr / aframe

:a: Web framework for building virtual reality experiences.
https://aframe.io/
MIT License
16.69k stars 3.98k forks source link

A -Frame ARjs doesn't work on Chrome/Firefox mobile #3892

Closed armonnaeini closed 5 years ago

armonnaeini commented 5 years ago

Description:

I first would like to say this problem is not specific to ARjs. I have done some troubleshooting other answers claimed that this issue is not present in only A-Frame. I have tried to use A-Frame without any augmented reality (using the examples from A-Frame's website) and the most basic A-Frame scenes do not work properly.

The program works fine, without any errors, on Safari.

If I use Chrome on my iPhone X, I get a screen that shows only my HTML DOM and the webcam isn't in use.

If I use Firefox, I get an error message saying: WebRTC issue-! navigator.mediaDevices not present in your browser

I really have no idea what to do at this point. I have been troubleshooting for so long now, trying every fix I could find, but nothing has worked. Is there some sort of work around to this?

arpu commented 5 years ago

about the Firefox WebRTC browser you can try include https://github.com/webrtcHacks/adapter

armonnaeini commented 5 years ago

about the Firefox WebRTC browser you can try include https://github.com/webrtcHacks/adapter

Didn't work :/

armonnaeini commented 5 years ago

Please someone help with this issue I still am experiencing this problem.

dmarcos commented 5 years ago

Probably better to reach out ar.js folks or open a question on Stack Overflow. With info provided, This doesn’t seem to be a problem with A-Frame itself but something related to WebRTC camera access in the browsers / devices you use.

What do you mean by I have tried to use A-Frame without any augmented reality (using the examples from A-Frame's website) and the most basic A-Frame scenes do not work properly.? A-Frame examples work fine for me on an iPhoneX (Safari) / Pixel 2 (Chrome)

MartijnEisses commented 5 years ago

I ran into the same problem. But it doesn't look like this is at all possible on iOS. I found this answer on StackOverflow:
https://stackoverflow.com/questions/51501642/chrome-and-firefox-are-not-able-to-access-iphone-camera

Chrome and FireFox on iOS still use the iOS WebKit rendering engine. getUserMedia is only available in Safari, not other browsers on iOS.

This is currently being tracked here: https://bugs.chromium.org/p/chromium/issues/detail?id=752458

dmarcos commented 5 years ago

@MartijnEisses thanks for reporting. That seems indees the issue: Unavailability of getUserMedia API in WebKit apps other than Safari.

arfai1213 commented 5 years ago

same issue, any update on it please?

dmarcos commented 5 years ago

It’s not actionable on the A-Frame / ar.js. side. The necessary Web APIs are just not available in WebViews. It’s up to Apple to expose them.