(defer)
| 14 | .add(`Resize of ${sample.width}x${sample.height}`, { |
| 15 | defer: true, |
| 16 | fn (defer) { |
| 17 | p.resizeBuffer({ |
| 18 | src: sample.buffer, |
| 19 | width: sample.width, |
| 20 | height: sample.height, |
| 21 | toWidth: (sample.width * 0.15)|0, |
| 22 | toHeight: (sample.height * 0.15)|0, |
| 23 | filter: 'lanczos3' |
| 24 | }) |
| 25 | .then(() => defer.resolve()) |
| 26 | } |
| 27 | }) |
| 28 | |
| 29 | .add(`Unsharp of ${sample.width}x${sample.height}`, { |