Imagemagick: Difference between revisions

From Helpful
Jump to navigation Jump to search
 
 
Line 29: Line 29:
* http://www.imagemagick.org/Magick++/Geometry.html
* http://www.imagemagick.org/Magick++/Geometry.html


Note you can in some cases not specify the size at all.


You can sometimes avoid having to know the image size.
For example, to take 5 pixels off the top and left, 15 off the right, and 10 off the bottom edge, without specifying an image size:
For example, to take 5 pixels off the top and left, 15 off the right, and 10 off the bottom edge, without specifying an image size:
  convert -crop +5+5 -crop -15-10 bordered.png borderless.png
  convert -crop +5+5 -crop -15-10 bordered.png borderless.png

Latest revision as of 14:06, 12 October 2012

These are primarily notes
It won't be complete in any sense.
It exists to contain fragments of useful information.
This article/section is a stub — probably a pile of half-sorted notes and is probably a first version, is not well-checked, so may have incorrect bits. (Feel free to ignore, or tell me)

convert/mogrify notes

The command line swiss army knife for image conversions

http://www.imagemagick.org/script/command-line-processing.php



On geometry specifications

See e.g.


You can sometimes avoid having to know the image size. For example, to take 5 pixels off the top and left, 15 off the right, and 10 off the bottom edge, without specifying an image size:

convert -crop +5+5 -crop -15-10 bordered.png borderless.png

Errors

This article/section is a stub — probably a pile of half-sorted notes and is probably a first version, is not well-checked, so may have incorrect bits. (Feel free to ignore, or tell me)


Convert: geometry does not contain image

Can be triggered by using -trim while the entire image is just one color.


Editing Unknown field with tag 40961 (0xa001) encountered. `TIFFReadCustomDirectory'.

This is a warning, telling you that this field has been ignored. This particular tag refers to the color space, meaning that the colors may not be interpreted as specified - which can have an effect anywhere between none at all and 'uuuuugly'.