I have 1D array of pixel values and i can get red, green and blue this way.
int rgb[] = new int[]
{
(argb >> 16) & 0xff, //red
(argb >> 8) & 0xff, //green
(argb ) & 0xff //blue
};
I know width height of image as well which I want to create. So, in total I have following data. 1) width of new image 2) height of new image 3) one dimension array of pixel value.
My supervisor has advised me to use createRaster method but function arguments are hard to understand for me. Can you suggest me some simple code? Thanks.