mirror of
https://github.com/serratus/quaggaJS.git
synced 2026-08-13 05:31:37 +08:00
Merge branch 'tricki-patch-1'
This commit is contained in:
+6
-3
@@ -57,10 +57,13 @@ function(Code128Reader, EANReader, InputStream, ImageWrapper, BarcodeLocator, Ba
|
||||
} else if (_config.inputStream.type == "ImageStream") {
|
||||
_inputStream = InputStream.createImageStream();
|
||||
} else if (_config.inputStream.type == "LiveStream") {
|
||||
video = document.createElement("video");
|
||||
var $viewport = document.querySelector("#interactive.viewport");
|
||||
if($viewport) {
|
||||
$viewport.appendChild(video);
|
||||
if ($viewport) {
|
||||
video = $viewport.querySelector("video");
|
||||
if (!video) {
|
||||
video = document.createElement("video");
|
||||
$viewport.appendChild(video);
|
||||
}
|
||||
}
|
||||
_inputStream = InputStream.createLiveStream(video);
|
||||
CameraAccess.request(video, _config.inputStream.constraints, function(err) {
|
||||
|
||||
Reference in New Issue
Block a user