Questions tagged [imagemagick]

ImageMagick is an open source software suite for displaying, converting and editing raster image files.

ImageMagick is a set of command line utilities to modify, transform, and convert images. The utilities are available for all major OSs.

The software mainly consists of libraries and a number of utilities for manipulating images.

File format conversion

One of the basic and thoroughly-implemented features of is its ability to efficiently and accurately convert images between different file formats. Over 100 different formats are supported.

Language Bindings

There are ImageMagick bindings for most popular programming languages including , , , , , , , , , and .

Distribution

is cross-platform, and runs on all recent versions of Microsoft Windows (except Windows 95), and Unix-like systems including Mac OS X, Linux, Solaris, and FreeBSD. The project's source code can be compiled for other systems, including AmigaOS 4.0 and MorphOS.

480 questions
89
votes
3 answers

Invert colors with ImageMagick

How do I invert the colors of an image using the ImageMagick convert tool, so that black becomes white and white becomes black? In other words, I want to turn this: into this:
Jo Liss
  • 4,279
75
votes
3 answers

Appending images vertically in ImageMagick

convert -append 1.jpg 2.jpg out.jpg This command appends 1.jpg and 2.jpg horizontally. What is the command to do this vertically?
29
votes
1 answer

Stack images vertically and center

I have several images of different widths and heights that I would like to stack vertically about their respective centers. I've tried convert 1.jpg 2.jpg 3.jpg -append out.jpg But this aligns them to the left, I'd like it to be center-aligned.
bmikolaj
  • 393
27
votes
1 answer

Convert PDF to JPG images with ImageMagick - how to 0-pad file names?

I convert a pdf file to jpg images by using ImageMagick like this: convert -density 600 foo.pdf foo.jpg The created jpg images are named foo-1.jpg, foo-10.jpg and so on. Is there way to 0-pad the output file names to foo-01.jpg etc.?
ironsand
  • 2,299
23
votes
4 answers

How to insert white space with imagemagick?

What parameters does "convert" (?) need to get this OUTPUT from this INPUT? INPUT: OUTPUT:
17
votes
1 answer

Use imagemagic to put several JPG on one page

I have a folder full of jpg files. When I use the following command, convert *.jpg assembly.pdf I get a pdf file with one image per page of the pdf. I would like to put 9 images on each page. Is there a way to do this with convert or…
Ziggy
  • 906
8
votes
1 answer

Can ImageMagick number output files with two digits?

I use the following command to extract pages from PDF files into independent JPG files before inserting them into videos: convert.exe -density 96 -resize 640x480 input.pdf +adjoin -alpha remove -alpha off output.jpg As a result, files are numbered…
7
votes
1 answer

Converting images of different dimensions into a gif with maximum dimensions

I have a set of images for an animation, but not all of the dimensions are the same. Some may be 100x100, others might be 99x105, a few with 110x100, and so on. If I did a simple convert *.png myAni.gif And the first image happened to be a bit…
MxLDevs
  • 1,189
7
votes
3 answers

How to average multiple images into one with ImageMagick?

convert -average darky1.jpg darky2.jpg lighty1.jpg lighty2.jpg l.ppm convert -average lighty1.jpg lighty2.jpg lighty1.jpg lighty2.jpg d.ppm l.ppm is much lighter than d.ppm. The order of images matters (but should not). The same for using…
Vi.
  • 17,175
6
votes
2 answers

How to pass a list of files to ImageMagick's montage?

I have a large number of tiles, with the following naming convention: A-x-y.jpg where 0<=x<=16 & 0<=y<=14 Now I know that we can use the Montage tool in ImageMagick, to merge them into one whole image. Ideally I could have used the following…
6
votes
1 answer

How to overlay two images with position and scale in imagemagick?

Given these two images of size 512x512 with transparent background: circle.png inner.png I'd like to overlay these two images, so that they appear centered and shrink the image size down to say 64x64. My initial attempt looks like: convert…
bluenote10
  • 225
  • 1
  • 2
  • 10
4
votes
2 answers

Combine multiple JPEGs into one

I have folder of JPEG files named 0_0, 0_1, 1_0, 1_1, etc. First number is column and second one is row. I want to combine them into one JPEG file. How would I go about doing this? I have looked into ImageMagick but I don't know what parameters to…
4
votes
1 answer

make directory if it doesn't exist with `mogrify -path` command

I convert images in a directory named foo to bar by like this. $ mkdir bar $ mogrify -path bar -negate foo/*.png Is there option in Imagemagick that create a folder with -path option, if it not exist.
ironsand
  • 2,299
4
votes
1 answer

What does the output of Imagemagicks identify mean?

Can someone please explain me the following output of imagemagicks identify? image.gif GIF 345x49 345x49+0+0 8-bit PseudoClass 256c 1.79KB 0.000u 0:00.000 I know the follwing: I know that GIF is the file extension, 345 is the width, 49 is height,…
Martin Thoma
  • 3,434
2
votes
1 answer

Convert file to 24bit bitmap

I'm using imagemagick convert to convert this image https://i.stack.imgur.com/u4z85.jpg to a bmp. However for some reason the tool I am using doesn't like the bitmap. If I save the image as a png and convert it to a 24bit bmp its fine. I tried using…
user3109
1
2 3 4