READ_ENVI_IMAGE
Name
READ_ENVI_IMAGE
Purpose
This function serves to read an ENVI image/header directly into
an IDL program without the need to first open that image in ENVI
and use the ENVI_* routines to do so.
Category
Image Processing.
Calling Sequence
Result = READ_ENVI_IMAGE( filename, HEADER=header )
Inputs
Filename
The ENVI image filename to be read.
Keyword Parameters
HEADER:
A named variable to receive a structure containing the header
data read in from the accompanying ENVI image header file.
Return Value
An array containing the image data. This array will be of the
correct data type for the provided image and will appear in BIP
interleave order (bands, samples, lines). If any error is
encountered during this process, the scalar -1 will be returned.
Side Effects
NONE
Modification History
Written by: Carl Salvaggio
July, 2009 Original code
December, 2009 OS family dependent swap endian added
Disclaimer
This source code is provided "as is" and without warranties as to performance
or merchantability. The author and/or distributors of this source code may
have made statements about this source code. Any such statements do not
constitute warranties and shall not be relied on by the user in deciding
whether to use this source code.
This source code is provided without any express or implied warranties
whatsoever. Because of the diversity of conditions and hardware under which
this source code may be used, no warranty of fitness for a particular purpose
is offered. The user is advised to test the source code thoroughly before
relying on it. The user must assume the entire risk of using the source code.