Created
May 30, 2016 19:21
-
-
Save elxris/3257901c8f91434c20e5278fd332b5ec to your computer and use it in GitHub Desktop.
lwip - Image Resize
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var lwip = require('lwip'); | |
lwip.open('image.jpg', function(err, image) { | |
if (err) {throw err;} | |
image.batch() | |
.cover(200, 200) | |
.writeFile('output.jpg', function(err) { | |
if (err) {throw err;} | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment