1 #!/usr/bin/perl 2 # 3 # Test read image method on non-interlaced JPEG. 4 # 5 # Contributed by Bob Friesenhahn <bfriesen (at] simple.dallas.tx.us> 6 # 7 BEGIN { $| = 1; $test=1; print "1..11\n"; } 8 END {print "not ok $test\n" unless $loaded;} 9 use Image::Magick; 10 $loaded=1; 11 12 require 't/subroutines.pl'; 13 14 chdir 't/jng' || die 'Cd failed'; 15 16 # 17 # 1) Gray 18 # 19 testReadCompare('input_gray.jng', '../reference/jng/read_gray.miff', q//, 0.003, 0.22); 20 # 21 # 2) Gray with IDAT encoding 22 # 23 ++$test; 24 testReadCompare('input_gray_idat.jng', '../reference/jng/read_gray_idat.miff', q//, 0.003, 0.22); 25 # 26 # 3) Gray with JDAA encoding 27 # 28 ++$test; 29 testReadCompare('input_gray_jdaa.jng', '../reference/jng/read_gray_jdaa.miff', q//, 0.003, 0.22); 30 # 31 # 4) Gray Progressive 32 # 33 ++$test; 34 testReadCompare('input_gray_prog.jng', '../reference/jng/read_gray_prog.miff', q//, 0.003, 0.22); 35 # 36 # 5) Gray progressive with IDAT encoding 37 # 38 ++$test; 39 testReadCompare('input_gray_prog_idat.jng', '../reference/jng/read_gray_prog_idat.miff', q//, 0.003, 0.22); 40 # 41 # 6) Gray progressive with JDAA encoding 42 # 43 ++$test; 44 testReadCompare('input_gray_prog_jdaa.jng', '../reference/jng/read_gray_prog_jdaa.miff', q//, 0.003, 0.22); 45 # 46 # 7) Color with JDAA encoding 47 # 48 ++$test; 49 testReadCompare('input_idat.jng', '../reference/jng/read_idat.miff', q//, 0.003, 0.22); 50 # 51 # 8) Color with JDAA encoding 52 # 53 ++$test; 54 testReadCompare('input_jdaa.jng', '../reference/jng/read_jdaa.miff', q//, 0.003, 0.22); 55 # 56 # 9) Color progressive 57 # 58 ++$test; 59 testReadCompare('input_prog.jng', '../reference/jng/read_prog.miff', q//, 0.003, 0.22);# 60 # 61 # 10) Color progressive with IDAT encoding 62 # 63 ++$test; 64 testReadCompare('input_prog_idat.jng', '../reference/jng/read_prog_idat.miff', q//, 0.003, 0.22); 65 # 66 # 11) Color progressive with JDAA encoding 67 # 68 ++$test; 69 testReadCompare('input_prog_jdaa.jng', '../reference/jng/read_prog_jdaa.miff', q//, 0.003, 0.22); 70