imageimagemagicktilemontage

Using ImageMagick to repeat or "tile" an image


How do I tile an image using ImageMagick? I don't think I can use montage because I want the columns displaced by 50% of the original image height.

It's probably easier to show an example of what I'm trying to do:

Start with:

enter image description here

End with:

enter image description here

Thanks!


Solution

  • Thanks to Fred at Fred's ImageMagick Scripts, here's the solution:

    infile="tile.png"
    
    h2=`convert $infile -format "%[fx:round(h/2)]" info:`
    
    convert $infile \( -clone 0 -roll +0+$h2 \) +append -write mpr:sometile +delete -size 1000x500 tile:mpr:sometile output.png
    

    This is exactly what I was looking for.