瀏覽代碼

Don't show video when there's only audio.

tags/blog-initial
Daniel Perelman 1 年之前
父節點
當前提交
eba8813f9f
共有 1 個文件被更改,包括 8 次插入5 次删除
  1. +8
    -5
      camera/templates/index.html

+ 8
- 5
camera/templates/index.html 查看文件

@@ -222,11 +222,14 @@ form label {
remoteView.srcObject = stream;
log("Set srcObject");
remoteView.play();
out.innerText += "Set srcObject\n";
out.style.display = 'none';
form.style.display = 'none';
videos.style.display = '';
body.classList.add('justVideo');

if (stream.getVideoTracks().length > 0) {
remoteView.style.display = '';
out.style.display = 'none';
form.style.display = 'none';
videos.style.display = '';
body.classList.add('justVideo');
}
};

return pc;


Loading…
取消
儲存