Reputation: 11
someone can help me with this line of code?
recorder = new MediaRecorder(stream, {mimeType: 'video/webm'});
when i use this variable in iOS, cath(err) answer me "RefenceError, cant find variable: mediaRecorder"
pleases can you helpe? if you need it this is the complete function
startBtn.addEventListener('click',function() {
navigator.mediaDevices.getUserMedia(constraint).then(function(stream) {
recorder = new MediaRecorder(stream, {
mimeType: 'video/webm'
});
recorder.start();
}).catch(function(err) {
alert('impossible '+err);
});
})
Upvotes: 1
Views: 242
Reputation: 322
Unfortunately the getUserMedia is only supported in safari browser
Any other browsers the getUserMedia is not supported in iOS devices
First check the availability of getUserMedia before you assign it to recorder
Good Luck
Upvotes: 0