Remove whitespace created by -append

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Locked
denton
Posts: 4
Joined: 2020-03-02T06:51:00-07:00
Authentication code: 1152

Remove whitespace created by -append

Post by denton »

I've just installed IM on my macbook pro (Version: ImageMagick 7.0.9-26 Q16 x86_64 2020-02-27)

I'm using it to append images vertically on top of each other but there's spacing between the images. How do I reduce the whitespace or get rid of it altogether? https://imgur.com/3xAwH3I

Thank you.

I'm not much of a programming person so I don't know much.

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Remove whitespace created by -append

Post by snibgo »

I can't see any white space in your example.

If your input images have the same width, "-append" does not add any space. If they have different widths, there will be space at least one side of the narrower images. This space is the "-background" colour.

If that doesn't help, please show your command, and input images.
snibgo's IM pages: im.snibgo.com

denton
Posts: 4
Joined: 2020-03-02T06:51:00-07:00
Authentication code: 1152

Re: Remove whitespace created by -append

Post by denton »

snibgo wrote:
2020-03-02T07:03:46-07:00
I can't see any white space in your example.

If your input images have the same width, "-append" does not add any space. If they have different widths, there will be space at least one side of the narrower images. This space is the "-background" colour.

If that doesn't help, please show your command, and input images.
Sorry I meant the black gap between the 3 pictures.

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Remove whitespace created by -append

Post by snibgo »

Please show your command, and input images.
snibgo's IM pages: im.snibgo.com

denton
Posts: 4
Joined: 2020-03-02T06:51:00-07:00
Authentication code: 1152

Re: Remove whitespace created by -append

Post by denton »

snibgo wrote:
2020-03-02T07:11:04-07:00
Please show your command, and input images.


magick Desktop/NT11un Desktop/NT11me Desktop/NT11act -append Desktop/NT11full

https://imgur.com/a/JK4HIGk

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Remove whitespace created by -append

Post by snibgo »

Your three inputs are 2922x424 pixels. Your output is 2922x1272 pixels, exactly three times the size of each input. No pixels has been added.

I suggest you use extensions to your filenames, eg ".png" for PNG format.
snibgo's IM pages: im.snibgo.com

denton
Posts: 4
Joined: 2020-03-02T06:51:00-07:00
Authentication code: 1152

Re: Remove whitespace created by -append

Post by denton »

snibgo wrote:
2020-03-02T07:31:04-07:00
Your three inputs are 2922x424 pixels. Your output is 2922x1272 pixels, exactly three times the size of each input. No pixels has been added.

I suggest you use extensions to your filenames, eg ".png" for PNG format.
So why are there the black gaps in between each picture?

snibgo
Posts: 13034
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Remove whitespace created by -append

Post by snibgo »

Every input has a border with semi-transparent black pixels. When you append the images, those pixels are in the output image.

I suggest you open an input and the output in a program such as Gimp that shows the semi-transparent pixels.
snibgo's IM pages: im.snibgo.com

Locked