Edit: Duplicate of How to access camera on iOS11 home screen web app?
I\'m running into a problem with using a apple web-app together with camera ac
The navigator.mediaDevices.getUserMedia
function is back in iOS 14.3 which got out yesterday. (Make sure you are not using the navigator.getUserMedia
which is deprecated).
We'll be using it in Cordova, I'll update this post if we find some instabilities.
Don't forget to use the playinline
attribute in your <video>
element if you don't want the video to start in fullscreen.
Apple has removed the ability to use getUserMedia
inside a UIWebView, WKWebView, SFSafariViewController, or a webpage that has been "added to the home screen".
The reasoning is not clear, however I do not believe this to be a bug.
An Apple staff member wrote this about WebRTC in iOS 11:
...right now, WebRTC is only supported in Safari. No WKWebView, not even SFSafariViewController.
And I can confirm that this includes the UIWebView as well (through personal tesing).