blob: 97cf9b2cdbdb0b611f82b4e5e8fe1bbe18dc134c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
#! /bin/sh
# This script tests: pngtopam pnmtopng
# Also requires:
# Failure message
## If this test fails and pnm-roundtrip2.test succeeds, it indicates
## some problem with pnmtopng.
# Test 1. Should print 1926073387 101484 18 times
for flags in "" -interlace \
-gamma=.45 \
-hist \
-nofilter \
-sub \
-up \
-avg \
-paeth \
-compression=9 \
"-compression=0 -comp_mem=1 -comp_window=8 -comp_buffer=512" \
"-compression=9 -comp_mem=1 -comp_window=15 -comp_buffer=512" \
"-compression=9 -comp_mem=1 -comp_window=8 -comp_buffer=512" \
"-compression=0 -comp_mem=9 -comp_window=8 -comp_buffer=512" \
"-compression=9 -comp_mem=9 -comp_window=15 -comp_buffer=8096" \
-comp_strategy=huffman_only \
-comp_strategy=filtered \
-force
do
pnmtopng testimg.ppm $flags | pngtopam | cksum
done
# Test 2. Should print 281226646 481 18 times
for flags in "" -interlace \
-gamma=.45 \
-hist \
-nofilter \
-sub \
-up \
-avg \
-paeth \
-compression=9 \
"-compression=0 -comp_mem=1 -comp_window=8 -comp_buffer=512" \
"-compression=9 -comp_mem=1 -comp_window=15 -comp_buffer=512" \
"-compression=9 -comp_mem=1 -comp_window=8 -comp_buffer=512" \
"-compression=0 -comp_mem=9 -comp_window=8 -comp_buffer=512" \
"-compression=9 -comp_mem=9 -comp_window=15 -comp_buffer=8096" \
-comp_strategy=huffman_only \
-comp_strategy=filtered \
-force
do
pnmtopng maze.pbm $flags | pngtopam | cksum
done
|