4 pieceSlide
=$
[$pieceHeight-130]
7 inputname
=${infile%%.*}
11 function getwidth
() { magick identify
-format '%[height]' "$1"; }
12 height
=$
(getwidth
"${infile}")
18 while [ $top -lt $height ]
21 convert
-crop x
${pieceHeight}+0+${top} +repage "${infile}" "${targetdir}/${inputname}_${fno}.png
"
22 top=$[$top+$pieceSlide]