0

I'm trying to comment on an image using the gm module, but it only creates the same image I used without the comment.

Code in Context

var gm = require('gm');

gm('api/routes/image1.jpg')
    .comment(['Text Example'])
    .write('api/routes/image2.png', 
     function(e) {
         console.log(e||'done');
     });
Nayantara Jeyaraj
  • 2,624
  • 7
  • 34
  • 63
Jonathan
  • 127
  • 1
  • 8
  • 1
    Are you expecting the text to be on the image itself? Because that's not what [comment](http://www.graphicsmagick.org/GraphicsMagick.html#details-comment) is for. If so, you need to use `drawText`. – Ben Fortune Oct 12 '16 at 11:22
  • You alrigth. Thanks @BenFortune. Taking the gm documentation, you know some other stuff I can study this module? – Jonathan Oct 12 '16 at 11:34
  • The GraphicsMagick documentation is really good, `gm` is just a wrapper around it. – Ben Fortune Oct 12 '16 at 11:45
  • Thanks @BenFortune. More a question. I want create a white bar in bottom the image. I thought I'd do a append a white image, but the image can has very with and heigth different, so that is not work. Do you know how I could create a bar in bottom the image with any size ? – Jonathan Oct 12 '16 at 12:30

0 Answers0