Creates an associative array in image format.
The input array must be in one of the following forms, where w is the image width, h is the height, and img_count, an optional parameter, is the number of images in the array:
NOTE: If the input pixel_array is 2D and the Colormap keyword is not specified, the returned image is assumed to be grayscale.
Depth
File_Name
File_Type
'sun'
denotes a Sun Rasterfile. (Default: TIFF)
NOTE: See the Discussion section of the IMAGE_READ function for a list of valid file types.
Intleave
image
) Valid strings and the corresponding interleaving methods are:
'image'
'row'
'pixel'
Units
X_resolution
Y_resolution
NOTE: When creating an image that contains 3D pixel data, you must specify the interleaving method if either the width or height has a value of 3. For example, if the dimensions of your data are 100 x 3 x 3 and the data is plane interleaved, it will be interpreted as line interleaved unless you explicitly set the Interleave keyword to the correct value.
pixels = BYTARR(100, 200)
cmap = BYTARR(3, 50)
image = IMAGE_CREATE(pixels, File_name='test.tif', $ Colormap = cmap, File_type = 'tif'); Create the image -- an associative array of image-related ; data. Next, use INFO to display the contents of the array.
INFO, image, /Full