The screen shows blank in ios devices when the stream displayed on the html5 video tag, it shows black screen. but work fines everywhere on other devices. Here is the js code
it works in single screen but when peer to peer js called for twillio it shows a black screen while video session starts between two devices and user
navigator.mediaDevices.getUserMedia({video:true}).then(function(stream) {
document.getElementById("myVideo").setAttribute('autoplay', '');
document.getElementById("myVideo").setAttribute('muted', '');
document.getElementById("myVideo").setAttribute('playsinline', '');
document.getElementById("myVideo").srcObject = stream;
document.getElementById("myVideo").play();
}).catch(function(error) {
console.log(error.name + ": " + error.message);
alert(error.name + ": " + error.message);
});
Here Is the HTML code
<video id="myVideo" allow="camera;microphone" class="silhouetteVideo" style="" autoplay playsinline controls="false"></video>