diff options
| author | Feuerfuchs <git@feuerfuchs.dev> | 2019-09-28 18:08:18 +0200 |
|---|---|---|
| committer | Feuerfuchs <git@feuerfuchs.dev> | 2019-09-28 18:08:18 +0200 |
| commit | f4754c009d97b963b0c9dfcb55811af795bc0035 (patch) | |
| tree | 1c1ed9ce197fd692118f5d19ee0cfa111fe47216 /hyperize.sh | |
| parent | new: hyperowo, moved animation offsets into function for reusability (diff) | |
| download | blobfox-emojis-f4754c009d97b963b0c9dfcb55811af795bc0035.tar.gz blobfox-emojis-f4754c009d97b963b0c9dfcb55811af795bc0035.tar.bz2 blobfox-emojis-f4754c009d97b963b0c9dfcb55811af795bc0035.zip | |
new: hypercofe, generalized hyper script
Diffstat (limited to 'hyperize.sh')
| -rwxr-xr-x | hyperize.sh | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/hyperize.sh b/hyperize.sh new file mode 100755 index 0000000..6f6ad0a --- /dev/null +++ b/hyperize.sh | |||
| @@ -0,0 +1,38 @@ | |||
| 1 | #!/bin/sh | ||
| 2 | |||
| 3 | source ./shakeoffsets.sh | ||
| 4 | |||
| 5 | declare -a shakeOffsets | ||
| 6 | getShakeOffsets shakeOffsets | ||
| 7 | |||
| 8 | SOURCEBASE=$1 | ||
| 9 | SOURCESVG=`printf "%s.svg" $SOURCEBASE` | ||
| 10 | TARGETSVG=`printf "export/a%s.png" $SOURCEBASE` | ||
| 11 | |||
| 12 | |||
| 13 | mkdir -p export_tmp | ||
| 14 | rm -f export_tmp/* | ||
| 15 | |||
| 16 | |||
| 17 | counter=1 | ||
| 18 | while [ $counter -le 75 ] | ||
| 19 | do | ||
| 20 | offset=${shakeOffsets[counter-1]} | ||
| 21 | file=`printf "export_tmp/%s.png" $counter` | ||
| 22 | inkscape -z -e $file -a $offset $SOURCESVG | ||
| 23 | ((counter++)) | ||
| 24 | done | ||
| 25 | |||
| 26 | |||
| 27 | declare -a args | ||
| 28 | |||
| 29 | counter=1 | ||
| 30 | while [ $counter -le 75 ] | ||
| 31 | do | ||
| 32 | file=`printf "export_tmp/%s.png" $counter` | ||
| 33 | args+=($file 1:50) | ||
| 34 | ((counter++)) | ||
| 35 | done | ||
| 36 | |||
| 37 | apngasm -o $TARGETSVG ${args[@]} | ||
| 38 | rm -f export_tmp/* | ||
