http://www.perlmonks.org?node_id=1214407

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Does anyone know how to set the compression level for writing png files in Imager, or if it's even possible? So far Super Search and Google have been no help, so I tried many guesses of possible argument names, but no joy. All I've learned is that Imager doesn't complain about invalid args. I would really prefer not to use a different image module as it would involve a substantial rewrite of the program. Thanks for any help with this.

$img->write( file => $outfile, type => 'png', compression => 0 ); $img->write( file => $outfile, type => 'png', compress => 0 ); $img->write( file => $outfile, type => 'png', level => 0 ); $img->write( file => $outfile, type => 'png', quality => 0 ); ... I've tried these and many more, including every variation or combi +nation I could think of