From 13e892e1c27a3a929e683c626fbf0af03d2959e7 Mon Sep 17 00:00:00 2001 From: John Guan Date: Sat, 1 Aug 2020 22:03:05 +0800 Subject: [PATCH] Update gesture.js fix URL.createObjectURL error. --- js/gesture.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/gesture.js b/js/gesture.js index 43a9f3c..a6686aa 100644 --- a/js/gesture.js +++ b/js/gesture.js @@ -5,7 +5,7 @@ ccanvas=document.getElementById('comp') c_=ccanvas.getContext('2d') navigator.webkitGetUserMedia({audio:true,video:true},function(stream){ s=stream - video.src=window.webkitURL.createObjectURL(stream) + video.srcObject=stream video.addEventListener('play', function(){setInterval(dump,1000/25)} )