Use libvips built-in ICC profiles when required #1619

This commit is contained in:
Lovell Fuller
2019-07-29 14:16:21 +01:00
parent 2ed4b5ae83
commit 417cca6e0d
7 changed files with 17 additions and 24 deletions

View File

@@ -394,6 +394,15 @@ describe('Image Stats', function () {
});
});
it('CMYK input without profile', () =>
sharp(fixtures.inputJpgWithCmykNoProfile)
.stats()
.then(stats => {
assert.strictEqual(4, stats.channels.length);
assert.strictEqual(true, stats.isOpaque);
})
);
it('Stream in, Callback out', function (done) {
const readable = fs.createReadStream(fixtures.inputJpg);
const pipeline = sharp().stats(function (err, stats) {