using the api, can't create image from array
Posted: 2011-10-26T12:09:20-07:00
using the magic namespace I tied to create an image from my bitarray.
Image image(1280,720,"RGB",CharPixell,rgbImage);
but the app freezes and crashes . rgbImages is a char pointer used like so:
char * rgbImage = NULL;
rgbImage = (char *)malloc( size);
size is my step btypes * y. Did I do something wrong?
Do I need to use InitializeMagick ?
Image image(1280,720,"RGB",CharPixell,rgbImage);
but the app freezes and crashes . rgbImages is a char pointer used like so:
char * rgbImage = NULL;
rgbImage = (char *)malloc( size);
size is my step btypes * y. Did I do something wrong?
Do I need to use InitializeMagick ?