16 lines
432 B
Bash
16 lines
432 B
Bash
|
#!/bin/sh
|
||
|
|
||
|
ORIGSIZE=1041
|
||
|
ORIGLX=115
|
||
|
ORIGLY=200
|
||
|
ORIGRX=1445
|
||
|
ORIGRY=360
|
||
|
NEWSIZE=500
|
||
|
|
||
|
for f in $*; do
|
||
|
echo "Converting $f"
|
||
|
i=`basename $f .jpg`
|
||
|
convert $f -crop "$ORIGSIZE"x"$ORIGSIZE"+"$ORIGLX"+"$ORIGLY" +repage -resize "$NEWSIZE"x"$NEWSIZE" -bordercolor white -border 1 "$i"-l.png
|
||
|
convert $f -crop "$ORIGSIZE"x"$ORIGSIZE"+"$ORIGRX"+"$ORIGRY" +repage -resize "$NEWSIZE"x"$NEWSIZE" -bordercolor white -border 1 "$i"-r.png
|
||
|
done
|