making a fluffy testbed

This commit is contained in:
tTh 2022-08-23 12:24:22 +02:00
parent 75584b8ada
commit 162e04e6fc
6 changed files with 76 additions and 2 deletions

1
.gitignore vendored
View File

@ -11,6 +11,7 @@ Lib/t_t16x24
Lib/testbmp
Tests/*.tga
Tests/*.gif
Tests/t_t16x24
Tools/genplot2

View File

@ -2,6 +2,12 @@
Tester, c'est douter.
## État des lieux
Pas grand chose.
Allez quand même voir `config.sh` et `functions.sh` pour avoir une idée
du désastre actuel
## Mais encore ?

View File

@ -1,7 +1,6 @@
#!/bin/bash
SRC="/tmp/src.tga"
BW="/tmp/bw.tga"
source ./config.sh
DST="foo.tga"

8
Tests/config.sh Normal file
View File

@ -0,0 +1,8 @@
SRC="/tmp/src.tga"
BW="/tmp/bw.tga"
GIF89A="flashy.gif"
# find the last version of tga_*
COMDIR="../Tools"

43
Tests/functions.sh Normal file
View File

@ -0,0 +1,43 @@
# ---------------------------------------------------------------
test_des_xpers ()
{
command=$1
echo ; echo " Test du xper $command"
# generation d'une image sur laquelle travailler
$COMDIR/tga_mires mircol0 $SRC "hard xper '$command'"
case $command in
zero)
$COMDIR/tga_effects $SRC x0 $DST 64 128 192
;;
un)
$COMDIR/tga_effects $SRC x1 $DST 64 128 192
;;
deux)
$COMDIR/tga_effects $SRC x2 $DST 64 128 192
;;
trois)
$COMDIR/tga_effects $SRC x3 $DST 42 R1 "rg"
;;
quatre)
$COMDIR/tga_effects $SRC x4 $DST 27
;;
cinq)
$COMDIR/tga_effects $SRC x5 $DST 64 128 192
;;
*)
echo "==== ERROR ON $command ===="
exit 1 ;;
esac
gif89a=$(printf "flashy_%s.gif" $command)
convert -delay 80 $SRC $DST $gif89a
}
# ---------------------------------------------------------------
# ---------------------------------------------------------------

17
Tests/xper.sh Executable file
View File

@ -0,0 +1,17 @@
#!/bin/bash
source ./config.sh
source ./functions.sh
DST="foo.tga"
$COMDIR/tga_tools version
test_des_xpers "zero"
test_des_xpers "un"
test_des_xpers "deux"
test_des_xpers "trois"
test_des_xpers "quatre"
test_des_xpers "cinq"