Reputation: 126
I want to be able to tile together images of different aspect ratios in a way that looks good and avoids as much whitespace between the images as possible.
What I've done so far is rename all the images using a script that changes the image name to the aspect ratio, which makes ImageMagick tile the narrowest images first:
for i in *.jpg;
do mv "$i" $(printf '%.4f' $(echo "scale=4;" $(identify -format "%w" "$i") "/" $(identify -format "%h" "$i") | bc))"$i";
done
Then I run ImageMagick:
montage -mode concatenate -tile 6x -geometry 250x+10+20 -background black *.jpg out.jpg
Which gives me something like this:
Unfortunately, I want something like this, where there isn't as much vertical space between the images with the smaller aspect ratios and bigger ones:
Anyone have any ideas?
Upvotes: 1
Views: 322