Apple released a statement that getUserMedia will be fully functional on iOS 11. After installing iOS 11 Beta version 7, I do not get any stream message using below code write on ionic2:
var constraints = {
audio: false,
video: { facingMode: 'user' }
};
navigator.mediaDevices.getUserMedia(constraints).then(
function success(stream) {
console.log('====mid=====');
console.log(stream);
//video.srcObject = stream;
}
).catch(function(e) { console.error(e); });
Unfortunately,
getUserMedia
is only supported in Safari and not WKWebView or UIWebView in iOS 11.http://www.openradar.me/33571214