blob: 3fac163042a7baaad9c3f65e1175de2e6e1191b6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#! /bin/bash
# This script tests: pamtotga tgatoppm
# Also requires: ppmtopgm pgmtopbm
#Test 1: Should print 2425386270 41, cksum of testgrid.pbm
${PBM_TESTPREFIX}pamtotga -mono testgrid.pbm | \
${PBM_TESTPREFIX}tgatoppm | ${PBM_BINPREFIX}ppmtopgm | \
${PBM_BINPREFIX}pgmtopbm -threshold -val 0.5 | cksum
#Test 2: Should print 2871603838 33838, cksum of testimg.pgm
${PBM_BINPREFIX}ppmtopgm testimg.ppm > ${tmpdir}/testimg.pgm
${PBM_TESTPREFIX}pamtotga -cmap ${tmpdir}/testimg.pgm | \
${PBM_TESTPREFIX}tgatoppm | ${PBM_BINPREFIX}ppmtopgm | cksum
rm ${tmpdir}/testimg.pgm
#Test 3: Should print 1926073387 101484, cksum of testimg.ppm
${PBM_TESTPREFIX}pamtotga -rgb testimg.ppm | ${PBM_TESTPREFIX}tgatoppm | cksum
|