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

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

When feeding RGB (or, more accurately, BGR) data from a video source to Imager, a wise perlmonk once suggested to use this trick:
use Imager; my $i = Imager->new(); $nfr = reverse $nfr; $i->read( type => "pnm", data => "P6\n$width $height\n255\n" . $nfr ); $i->flip(dir => "hv");
Is this still the best way to do it? It seems awkward that the mighty Imager wouldn't allow feeding it RGB data directly.