Reputation: 1053
I'm trying to get an image capture from the front or back camera of my smartphone using the WebRTC. I used one of WebRTC samples for that. This code works perfectly in browsers on the computer, but on the smartphone with different operating systems (iOS, Android) I get a black screen in the tag <video autoplay></video>
. I tried various browsers, in none of them the image capture function worked properly, everywhere a black screen was displayed. What should I do to capture the picture?
I have a http connection, all my smartphones and cameras work fine, so the problem is definitely in WebRTC (or in its use).
Upvotes: 0
Views: 332
Reputation: 17295
For Safari, try adding playsinline to the video element. See this thread for background information.
If that doesn't help you might want to check the mediastream as well as the video elements readyState property.
Upvotes: 1