mirror of https://gitgud.io/fatchan/gm
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
483 B
23 lines
483 B
|
|
var assert =require('assert')
|
|
|
|
module.exports = function (gm, dir, finish, GM) {
|
|
var m = gm
|
|
.crop(200, 155, 300, 0)
|
|
.resize(58, 50, '%');
|
|
|
|
var args = m.args();
|
|
assert.equal('convert', args[0]);
|
|
assert.equal('-crop', args[2]);
|
|
assert.equal('200x155+300+0', args[3]);
|
|
assert.equal('-resize', args[4]);
|
|
assert.equal('58x50%', args[5]);
|
|
|
|
if (!GM.integration)
|
|
return finish();
|
|
|
|
m
|
|
.write(dir + '/cropresize.png', function crop (err) {
|
|
finish(err);
|
|
});
|
|
}
|
|
|