Updated to 0.6.8

This commit is contained in:
Christoph Oberhofer
2015-06-13 01:08:22 +02:00
parent 556df4567b
commit 6e4f93fb26
3 changed files with 27 additions and 5 deletions
+19 -2
View File
@@ -6890,7 +6890,13 @@ define(
} while(decodedChar !== '*');
result.pop();
if (!result.length) {
return null;
}
if(!self._verifyTrailingWhitespace(lastStart, nextStart, counters)) {
return null;
}
return {
code : result.join(""),
@@ -6901,6 +6907,17 @@ define(
};
};
Code39Reader.prototype._verifyTrailingWhitespace = function(lastStart, nextStart, counters) {
var trailingWhitespaceEnd,
patternSize = ArrayHelper.sum(counters);
trailingWhitespaceEnd = nextStart - lastStart - patternSize;
if ((trailingWhitespaceEnd * 3) >= patternSize) {
return true;
}
return false;
};
Code39Reader.prototype._patternToChar = function(pattern) {
var i,
self = this;
@@ -7902,12 +7919,12 @@ define('frame_grabber',["cv_utils"], function(CVUtils) {
_canvas.height = _canvasSize.y;
_ctx = _canvas.getContext("2d");
_data = new Uint8Array(_size.x * _size.y);
console.log("FrameGrabber", {
console.log("FrameGrabber", JSON.stringify({
size: _size,
topRight: topRight,
videoSize: _video_size,
canvasSize: _canvasSize
});
}));
/**
* Uses the given array as frame-buffer
+2 -2
View File
File diff suppressed because one or more lines are too long