#!/Perl/bin/perl use strict; use warnings; use FindBin qw/$Bin/; use Benchmark (qw/timediff timestr/); use Image::BMP; my $t0 = Benchmark->new(); my $img = Image::BMP->new(); $img->debug( 1 ); $img->open_file($Bin . '/cool_pig.bmp'); my ($r,$g,$b) = $img->xy_rgb(10,10); my $t1 = Benchmark->new(); my $td = timediff($t1, $t0); print "the code took:", timestr($td),"\n";