【问题标题】:GetUserMedia access denied on Cordova Android app, WebRTC and Kurento integrationCordova Android 应用程序、WebRTC 和 Kurento 集成上的 GetUserMedia 访问被拒绝
【发布时间】:2015-09-23 01:52:02
【问题描述】:

我正在尝试使用 Cordova、WebRTC 和 Kurento 制作 Android 应用程序。当我尝试使用该应用程序进行视频通话时,我可以接收来自远程对等方的视频和音频,但我无法将我的本地视频和音频发送到我的远程对等方。当通话开始时,我在应用程序上收到了 Permission Denied。

遵循调用 getUserMedia 的函数的代码。

getUserMedia = function(constraints, onSuccess, onError) {
alert('getusermedia.adapter');
if (constraints.audio) {
  constraints.audio = constraintsToChrome(constraints.audio);
}
if (constraints.video) {
  constraints.video = constraintsToChrome(constraints.video);
}
webrtcUtils.log('chrome: ' + JSON.stringify(constraints));
return navigator.webkitGetUserMedia(constraints, onSuccess, onError);
};
navigator.getUserMedia = getUserMedia; 

【问题讨论】:

    标签: android cordova getusermedia


    【解决方案1】:

    您可以使用来自cordova-plugin-cameracamera.getPicture 或来自cordova-plugin-media-capturenavigator.device.capture.captureVideo

    取自answer to "Showing camera view inside html in android and then snap a picture"

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2016-02-09
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2016-06-04
      • 1970-01-01
      • 2015-09-20
      • 2013-05-09
      相关资源
      最近更新 更多