1#!/usr/bin/perl 2# 3# Test writing PNG images when 16bit support is enabled 4# 5# Contributed by Bob Friesenhahn <bfriesen@simple.dallas.tx.us> 6# 7BEGIN { $| = 1; $test=1; print "1..5\n"; } 8END {print "not ok $test\n" unless $loaded;} 9 10use Image::Magick; 11$loaded=1; 12 13require 't/subroutines.pl'; 14 15chdir 't/png' || die 'Cd failed'; 16 17# 18# 1) Test pseudocolor image 19# 20testReadWrite( 'input_256.png', 21 'output_256.png', 22 q/quality=>54/, 23 '26687d6be46b4e1ca5201a47caa7dad660245c5f4517835ab6e19f2f84fc4a03' ); 24 25# 26# 2) Test truecolor image 27# 28++$test; 29testReadWrite( 'input_truecolor.png', 30 'output_truecolor.png', 31 q/quality=>55/, 32 '76f43f03e51c8608bfca7ff96d3936148ad855782968a017ea03cccbeebff64d' ); 33 34# 35# 3) Test monochrome image 36# 37++$test; 38testReadWrite( 'input_mono.png', 39 'output_mono.png', '', 40 'a8d79029f6ced36f904659dda5ea67a6bab5e602b1033aa29c7f1b45b35c1178' ); 41 42# 43# 4) Test Multiple-image Network Graphics 44# 45++$test; 46testReadWrite( 'input.mng', 47 'output.mng', 48 q/quality=>55/, 49 '5a883e67c29d7bb27897ec7a3f3cb3fb0330fb43aef4360e8314503cb37fae09' ); 50 51# 52# 5) Test 16-bit Portable Network Graphics 53# 54++$test; 55testReadWrite( 'input_16.png', 56 'output_16.png', 57 q/quality=>55/, 58 'd4bed86abb1849f69f1a5afb7c5cf8798e8192ba228357f189c277198c14f5a0', 59 '4036b56c00d731a2865470815eabc177dc158af2abacb34ef95c7e716ec2da60'); 60 61 62