image crop

Image crop code examples.

There is 1 snippet with the image crop tag

  • Crop an Image using ImageMagick and node.js

    Crop an image using node.js and the imagemagick node module. The module's convert method is used, where native ImageMagick arguments are passed in as an array. Size, offset and an input image path are supplied to produce a cropped output PNG, which is written to file.

    var http = require("http");
    var im = require("imagemagick"); 
    var args = [
    var server = http.createServer(function(req, res) {
      im.convert(args, function(err) {
        if(err) { throw err; }
        res.end("Image crop complete");
    26 Aug 2013