For Programmers: Free Programming Magazines  


Home > Archive > PERL Miscellaneous > January 2008 > best way to store binary image data in a variable using image magick









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author best way to store binary image data in a variable using image magick
Jack

2008-01-25, 4:28 am

Hi all,

Just wanted to know the code for doin this, such that I can use the
variable for doing other kinds of methods against it..

I tried this, and I can printout the binary data, but I am finding you
can assign the image data to a variable for further processing.. any
ideas ? I noticed that this line: $img->Write('jpg:-'); actually
displayed the image data, but how do I assign that binary data to a
variable ??

use Image::Magick;
my $img = new Image::Magick;
$x= $img->Read("c:\\tmp\\ean81.bmp");

## doesnt work: $img->Write('$temp');
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com