@@ -3,25 +3,70 @@ CTLRENDER=$1
33
44mkdir output
55
6+ printf ' printing environment variables...\n'
7+ printenv
8+
9+ printf ' printing current path...\n'
10+ pwd
11+
12+ printf ' printing directory contents...\n'
13+ dir
14+
15+ set -e
16+
617for J in tiff8 tiff16 tiff32 dpx8 dpx10 dpx12 dpx16; do
18+
19+ echo ${J} unity test
20+
721 for I in bars_cinepaint_10.dpx bars_nuke_10_be.dpx bars_nuke_10_le.dpx bars_nuke_12_be.dpx bars_nuke_12_le.dpx bars_nuke_16_be.dpx bars_nuke_16_le.dpx bars_nuke_8_be.dpx bars_nuke_8_le.dpx bars_photoshop_16_be_interleaved.tif bars_photoshop_16_be_planar.tif bars_photoshop_16_le_interleaved.tif bars_photoshop_16_le_planar.tif bars_photoshop_32_be_interleaved.tif bars_photoshop_32_be_planar.tif bars_photoshop_32_le_interleaved.tif bars_photoshop_32_le_planar.tif bars_photoshop_8_be_interleaved.tif bars_photoshop_8_be_planar.tif bars_photoshop_8_le_interleaved.tif bars_photoshop_8_le_planar.tif ; do
822 name=` echo $I | sed -e ' s/\..*//' `
923 ext=` echo $J | sed -e ' s/[0-9]//g' `
1024 echo ${I} ' ->' ${J}
1125 if [[ $IS_TIFF_FOUND == 0 ]] && [[ $J == * " tif" * ]] ; then
12- printf ' skipping %s because no tiff\n' $J
26+ printf ' skipping %s because tiff support was not detected \n' $J
1327 elif [[ $IS_TIFF_FOUND == 0 ]] && [[ $I == * " tif" * ]] ; then
14- printf ' skipping %s because no tiff\n' $I
28+ printf ' skipping %s because tiff support was not detected \n' $I
1529 else
1630 $CTLRENDER -ctl unity.ctl -format ${J} -force ${I} output/${name} _${J} .${ext}
1731 fi
1832 done
1933
20- echo ${J} unity test
21-
34+ # test TIFF32 conversions
2235 if [[ $IS_TIFF_FOUND == 1 ]] ; then
36+ printf ' bars_photoshop_32_be_planar.tif -> output/bars_tiff32_%s.%s \n' ${J} ${ext}
2337 $CTLRENDER -ctl unity.ctl -format ${J} -force bars_photoshop_32_be_planar.tif output/bars_tiff32_${J} .${ext}
38+ printf ' output/bars_tiff32_%s.%s -> output/bars_tiff32_%s_tiff32.tiff \n' ${J} ${ext} ${J}
2439 $CTLRENDER -ctl unity.ctl -format tiff32 -force output/bars_tiff32_${J} .${ext} output/bars_tiff32_${J} _tiff32.tiff
2540 fi
2641done
2742
43+ # test EXR to EXR support
44+ if [[ $IS_OPENEXR_FOUND == 1 ]] ; then
45+ printf ' bars_photoshop.exr -> output/bars_exr_exr.exr \n'
46+ $CTLRENDER -ctl unity.ctl -format exr -force bars_photoshop.exr output/bars_exr_exr.exr
47+ printf ' bars_photoshop.exr -> output/bars_exr_exr16.exr \n'
48+ $CTLRENDER -ctl unity.ctl -format exr16 -force bars_photoshop.exr output/bars_exr_exr16.exr
49+ printf ' bars_photoshop.exr -> output/bars_exr_exr32.exr \n'
50+ $CTLRENDER -ctl unity.ctl -format exr32 -force bars_photoshop.exr output/bars_exr_exr32.exr
51+ fi
52+
53+ # test TIFF32 to EXR and EXR to TIFF32 support
54+ if [[ $IS_OPENEXR_FOUND == 1 ]] && [[ $IS_TIFF_FOUND == 1 ]] ; then
55+
56+ for J in exr exr16 exr32 tiff32; do
57+
58+ for I in bars_photoshop_32_be_interleaved.tif bars_photoshop_32_be_planar.tif bars_photoshop_32_le_interleaved.tif bars_photoshop_32_le_planar.tif bars_photoshop.exr; do
59+ name=` echo $I | sed -e ' s/\..*//' `
60+ ext=` echo $J | sed -e ' s/[0-9]//g' `
61+ echo ${I} ' ->' ${J}
62+ if [[ $IS_TIFF_FOUND == 0 ]] && [[ $J == * " tif" * ]] ; then
63+ printf ' skipping %s because tiff support was not detected\n' $J
64+ elif [[ $IS_TIFF_FOUND == 0 ]] && [[ $I == * " tif" * ]] ; then
65+ printf ' skipping %s because tiff support was not detected\n' $I
66+ else
67+ $CTLRENDER -ctl unity.ctl -format ${J} -force ${I} output/${name} _${J} .${ext}
68+ fi
69+
70+ done
71+ done
72+ fi
0 commit comments