Release v0.16.1

This commit is contained in:
Lovell Fuller
2016-10-13 10:53:38 +01:00
parent d4a1722863
commit 207dcbeaa4
4 changed files with 40 additions and 10 deletions

View File

@@ -519,6 +519,36 @@ async.series({
}
});
}
}).add('sharp-crop-entropy', {
defer: true,
fn: function(deferred) {
sharp(inputJpgBuffer)
.resize(width, height)
.crop(sharp.strategy.entropy)
.toBuffer(function(err, buffer) {
if (err) {
throw err;
} else {
assert.notStrictEqual(null, buffer);
deferred.resolve();
}
});
}
}).add('sharp-crop-attention', {
defer: true,
fn: function(deferred) {
sharp(inputJpgBuffer)
.resize(width, height)
.crop(sharp.strategy.attention)
.toBuffer(function(err, buffer) {
if (err) {
throw err;
} else {
assert.notStrictEqual(null, buffer);
deferred.resolve();
}
});
}
}).on('cycle', function(event) {
console.log('operations ' + String(event.target));
}).on('complete', function() {