5 # tests/pngstest gamma alpha
7 # Run ./pngstest on the PNG files in $srcdir/contrib/testpngs which have the
8 # given gamma and opacity:
10 # gamma: one of; linear, 1.8, sRGB, none.
11 # alpha: one of; opaque, tRNS, alpha, none. 'none' is equivalent to !alpha
13 # NOTE: the temporary files pngstest generates have the base name gamma-alpha to
14 # avoid issues with make -j
20 exec ./pngstest --tmpfile "${gamma}-${alpha}-" --log ${1+"$@"} `
21 for f in "${srcdir}/contrib/testpngs/"*.png
26 test "$gamma" = "linear" && g="$f";;
29 test "$gamma" = "sRGB" && g="$f";;
32 test "$gamma" = "1.8" && g="$f";;
35 test "$gamma" = "none" && g="$f";;
43 test "$alpha" = "alpha" && echo "$g";;
46 test "$alpha" = "tRNS" -o "$alpha" = "none" && echo "$g";;
49 test "$alpha" = "opaque" -o "$alpha" = "none" && echo "$g";;