ngrandjean
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
5 additions and
1 deletions
-
web_widget_image_webcam/static/src/js/webcam.js
|
|
@ -139,7 +139,11 @@ var Webcam = { |
|
|
|
}) |
|
|
|
.then( function(stream) { |
|
|
|
// got access, attach stream to video
|
|
|
|
video.src = window.URL.createObjectURL( stream ) || stream; |
|
|
|
try { |
|
|
|
video.srcObject = stream; |
|
|
|
} catch (error) { |
|
|
|
video.src = window.URL.createObjectURL(stream) || stream; |
|
|
|
} |
|
|
|
self.stream = stream; |
|
|
|
self.loaded = true; |
|
|
|
self.live = true; |
|
|
|