montage concatenate with null:

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
sebunger
Posts: 2
Joined: 2015-08-29T19:36:10-07:00
Authentication code: 1151

montage concatenate with null:

Post by sebunger »

Hi,

I'm trying to combine a number of images with equal dimensions into a single image by concatenating them without border or any decorations. However, sometimes I need to leave some of the tiles blank. I've tried this command line, but it seems to behave oddly (and contrary to documentation):

Code: Select all

montage -mode concatenate -tile 2x2 rose: rose: null: rose: im_example.png
I expected an image with 3 roses and a white field in the bottom left. however, I get this:

Image

Am I doing something wrong or is this a bug?

Thanks for your help,
Seb
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: montage concatenate with null:

Post by fmw42 »

It seems to work this way:

Code: Select all

montage -tile 2x2 -geometry 70x46+0+0 rose: rose: null: rose: result.png
but oddly, if you leave off the WxH, I get your same result

Code: Select all

montage -tile 2x2 -geometry +0+0 rose: rose: null: rose: result.png
I suspect that without the WxH, montage does not know what size to make null: and so skips it.


Also if you leave off the geometry, it works fine, but you get lots of white space

Code: Select all

montage -tile 2x2 rose: rose: null: rose: result.png
sebunger
Posts: 2
Joined: 2015-08-29T19:36:10-07:00
Authentication code: 1151

Re: montage concatenate with null:

Post by sebunger »

Yes, those are my exact results. The problem is that I don't necessarily know the geometry of the individual images, only that they are the same. I guess I could query that information and then use it in my script, but according to my understanding of the docs I thought it should work. Hence my post here.
Post Reply