Comparing version 0.1.0 to 0.1.1
@@ -697,3 +697,3 @@ /* -*- Mode: Java; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- / | ||
v: v, | ||
quantizationTable: quantizationTables[qId] | ||
quantizationIdx: qId | ||
}; | ||
@@ -765,2 +765,11 @@ offset += 3; | ||
// set each frame's components quantization table | ||
for (var i = 0; i < frames.length; i++) { | ||
var cp = frames[i].components; | ||
for (var j in cp) { | ||
cp[j].quantizationTable = quantizationTables[cp[j].quantizationIdx]; | ||
delete cp[j].quantizationIdx; | ||
} | ||
} | ||
this.width = frame.samplesPerLine; | ||
@@ -767,0 +776,0 @@ this.height = frame.scanLines; |
{ | ||
"name": "jpeg-js", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "A pure javascript JPEG encoder and decoder", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -51,2 +51,9 @@ var redtape = require('redtape'), | ||
it('should be able to decode a unconventional table JPEG', function (t) { | ||
var jpegData = fixture('unconventional-table.jpg'); | ||
var rawImageData = jpeg.decode(jpegData); | ||
t.equal(rawImageData.width, 1920); | ||
t.equal(rawImageData.height, 1200); | ||
t.end(); | ||
}); | ||
@@ -90,1 +97,2 @@ it('should be able to encode a JPEG', function (t) { | ||
}); | ||
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2134778
17
1685