tweak graphicsmagick parameters
This commit is contained in:
parent
875a1b6eeb
commit
2210914740
@ -31,28 +31,28 @@ module.exports = (robot) ->
|
||||
compress = (image, callback) ->
|
||||
gm(image)
|
||||
.noProfile()
|
||||
.quality(rand(25,40))
|
||||
.colorize(rand(0,5),rand(0,5),rand(0,5))
|
||||
.noise('uniform')
|
||||
.quality(rand(30,80))
|
||||
.noise('uniform')
|
||||
.toBuffer callback
|
||||
|
||||
resize = (image, callback) ->
|
||||
gm(image)
|
||||
.resize(260000, '@>')
|
||||
.resize('40%')
|
||||
.resize('500%')
|
||||
.scale('95%')
|
||||
.scale('105%')
|
||||
.toBuffer callback
|
||||
|
||||
colorize = (image, callback) ->
|
||||
gm(image)
|
||||
.modulate(rand(110,200), rand(100,110))
|
||||
.modulate(rand(100,110), rand(100,150))
|
||||
.toBuffer callback
|
||||
|
||||
deepFry = (res, image) ->
|
||||
script = concat [
|
||||
init(image),
|
||||
resize,
|
||||
times(40, compress),
|
||||
colorize
|
||||
times(50, compress),
|
||||
]
|
||||
|
||||
async.waterfall script, (err, image) ->
|
||||
|
Loading…
Reference in New Issue
Block a user