Page 1 of 1
String of pixels to image
Posted: 2007-02-01T04:08:34-07:00
by Jasmina
Hi,
I have width, height and string with RGB values for all pixels for one image($width,$height and $pixelString) . How can I create image from these values using ImageMagick?
Posted: 2007-02-01T08:03:21-07:00
by magick
You did not specify which language interface you want to use. With MagickWand, use MagickReadImageBlob() but first call MagickSetFormat() to set the format to "RGB".
Posted: 2007-02-01T11:54:52-07:00
by Jasmina
I use PHP to export information for every pixel from Flash (pixel color = 0xRRGGBB value) to $pixelString. I use ImageMagick with "exec", never used MagickWand before. How I can use this string to generate a picture?
Posted: 2007-02-01T22:28:45-07:00
by anthony
See the imagemagick 'txt:' enumerated pixel format...
http://www.cit.gu.edu.au/~anthony/graph ... files/#txt
this lets you feed a stream of pixels, one line per pixel, to create the image from.
You can also feed the pixels (in sequence) using a netPBM format (text or binary)
http://www.cit.gu.edu.au/~anthony/graph ... ts/#netpbm
Posted: 2007-02-02T09:38:50-07:00
by Jasmina
Thank you.
Jasmina