Hello,
When using montage geometry '+4+4' means that two images will have 8 pixels between and that images will be 4 pixels from the edge of the final image. How can I make the image so that the distance between two images is 4 pixels and not 8 pixels while the distance to the edge remains 4 pixels?
Thank you
montage tile spacing
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: montage tile spacing
If you are only using 2 images, you can post process using -slice to remove rows or columns in the middle. See http://www.imagemagick.org/Usage/crop/#chop
However, the better and more general solution is to use -geometry +2+2 and post process with -bordercolor ... -border 2 to add a 2 pixel border all around the outside. See http://www.imagemagick.org/Usage/crop/#border. This will make the space between images 4 and the outside space 4 all around.
montage image1 image2 -geometry +2+2 <otheroptions> miff:- | convert - -bordercolor ... -border 2 resultimage
However, the better and more general solution is to use -geometry +2+2 and post process with -bordercolor ... -border 2 to add a 2 pixel border all around the outside. See http://www.imagemagick.org/Usage/crop/#border. This will make the space between images 4 and the outside space 4 all around.
montage image1 image2 -geometry +2+2 <otheroptions> miff:- | convert - -bordercolor ... -border 2 resultimage