You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 27, 2021. It is now read-only.
On iOS Safari, you open the example, it prompts for webcam use, you allow, then it takes a single frame and stays that way, doesn't open a video stream
Do you have more information on this and whether there's potential for this same webpage to work on iOS somehow?
Thank you! :)
The text was updated successfully, but these errors were encountered:
I had the same problem and stumpled upon this.
A solution that worked for me was:
Make sure your website is called via HTTPS. (else you need to activate the options in the safari developer tools that WebRTC is allowed on 'unsafe' websites)
Set the "playsinline"-attribute of the video object to true:
navigator.mediaDevices.getUserMedia({video: true,audio: false}).then(function(stream){video.srcObject=stream;video.setAttribute("playsinline",true);// <-- this is the important linevideo.play();})
Should you make a Pull Request for this to be added to the example in this repo? Unsure what the etiquette is to close this Issue or leave it open so others can find it easily.
This example -
https://developer.mozilla.org/en-US/docs/Web/API/WebRTC_API/Taking_still_photos
https://mdn-samples.mozilla.org/s/webrtc-capturestill/
On iOS Safari, you open the example, it prompts for webcam use, you allow, then it takes a single frame and stays that way, doesn't open a video stream
Do you have more information on this and whether there's potential for this same webpage to work on iOS somehow?
Thank you! :)
The text was updated successfully, but these errors were encountered: