【发布时间】:2017-03-13 19:58:58
【问题描述】:
我正在使用 webcam.js 获取客户点击的照片,以便在我的基于云的零售店软件上创建个人资料。
它曾经在早期版本的 chrome 中运行良好,在 firefox 上仍然运行良好。但现在最新版本的 chrome 甚至 Opera 等其他浏览器都开始在调用网络摄像头时抛出错误 - 只允许 https 版本使用网络摄像头。
它是个人使用的软件,我不想在 SSL 证书上花费额外。是否有一些选项可以让我们为 http 站点添加例外以使用网络摄像头
当前代码:
function loadCamera(){
Webcam.attach( '#my_camera' );
Webcam.set({
width: 200,
height: 200,
dest_width: 200,
dest_height: 200,
force_flash : true
});
}
【问题讨论】: