Welcome to the Harris Geospatial product documentation center. Here you will find reference guides, help documents, and product libraries.


ENVI_ENTER_DATA

ENVI_ENTER_DATA

This routine is obsolete and has been replaced with ENVIRaster.

Use this routine to enter image data from an array into ENVI Classic memory. ENVI_ENTER_DATA internally calls ENVI_SETUP_HEAD and registers the bands in the Available Bands List. This routine automatically creates an ENVI header file for the image (which is also stored in memory), and it returns the FID for the in-memory image. Once the image appears in the Available Bands List, you can use it like any other ENVI-format image and even save it to disk by selecting File > Save File As > ENVI Standard from the ENVI Classic main menu bar.

Syntax


ENVI_ENTER_DATA, Data [, BBL=array] [, BNAMES=string array] [, CLASS_NAMES=string array] [, DATA_GAINS=array] [, DATA_IGNORE_VALUE=variable] [, DATA_OFFSET=array] [, DEF_STRETCH=value] [, DESCRIP=string] [, FILE_TYPE=integer] [, FUNC_COMPLEX={0 | 1 | 2 | 3 | 4}] [, FWHM=array] [, GEO_POINTS=array] [, INFO=value] [, INHERIT=value] [, /INVISIBLE] [, LOOKUP=array] [, MAP_INFO=value] [, NUM_CLASSES=integer] [, PIXEL_SIZE=array] [, R_FID=variable] [, REFLECTANCE_SCALE_FACTOR=variable] [, SENSOR_TYPE=integer] [, SPEC_NAMES=string array] [, UNITS=integer] [, WAVELENGTH_UNIT={0 | 1 | 2 | 3 | 4 | 5 | 6}] [, WL=array] [, XSTART=integer] [, YSTART=integer] [, ZPLOT_AVERAGE=array] [, ZPLOT_TITLES=string array] [, ZRANGE=array]

Arguments


Data

This is a 2D or 3D data array of type byte, integer, unsigned integer, long integer, unsigned long integer, long 64-bit integer, unsigned long 64-bit integer, floating point, double precision, complex, or double complex. The data must be in BSQ format and have the dimensions [samples, lines] or [samples, lines, bands].

Note: The array is incorporated into the ENVI Classic session directly, rendering the variable undefined after the call to ENVI_ENTER_DATA. If you wish to use the array after the call to ENVI_ENTER_DATA, first copy the array and set the Data argument equal to the copy.

Keywords


BBL (optional)

Use this keyword to specify an array of ones and zeros representing the good and bad bands, respectively. The number of elements in BBL must be equal to the number of bands in the image.

BNAMES (optional)

Use this keyword to specify the band names assigned to the data. BNAMES is a string array (with num_bands elements) of band names. The default band names are [band 1, band 2], etc.

CLASS_NAMES (optional)

Use this keyword to specify a string array of class names for classification images. The first element (Class 0) is “Unclassified.” Only use CLASS_NAMES if the result is a classification image, in which case this keyword is required. If the result is not a classification image, this keyword is optional.

DATA_GAINS

Use this keyword to specify a named variable that contains an array of gain values for each band in the dataset. DATA_GAINS can be used in conjunction with DATA_OFFSETS in ENVI Classic's general purpose utility, Apply Gain and Offset.

DATA_IGNORE_VALUE (optional)

Use this keyword to specify a named variable that contains a scalar number representing the data value to ignore in the dataset. If you set DATA_IGNORE_VALUE, it is the same type as the input dataset, and an undefined ignore value is represented by the double-precision number 1e-34. Currently, this value is used only in user-written ENVI Classic code.

DATA_OFFSET (optional)

Use this keyword to specify a named variable that contains an array of offsets for each band in the dataset. DATA_OFFSETS can be used in conjunction with DATA_GAINS in ENVI Classic's general purpose utility, Apply Gain and Offset.

DEF_STRETCH (optional)

Use this keyword to specify the default stretch information. Set DEF_STRETCH equal to the value returned from ENVI_DEFAULT_STRETCH_CREATE.

DESCRIP (optional)

Use this keyword to specify a text description of the data, or of the type of processing performed.

FILE_TYPE (optional)

Use this keyword to specify an integer value indicating the file type. See ENVI_FILE_TYPE for details on how to determine the integer value of a file type.

FUNC_COMPLEX (optional)

Set this keyword to one of the following values to specify the complex lookup function that determines how to display complex data.

  • 0: Power (default): The natural log of the magnitude
  • 1: Magnitude:
  • 2: Real: The real portion of the complex number
  • 3: Imaginary: The imaginary part of the complex number
  • 4: Phase:

Note: Only set this keyword if the IDL data type of the image is complex or double-precision complex.

FWHM (optional)

Use this keyword to specify an array of floating-point values representing FWHM responses for each band. The number of elements in this array is equal to the number of bands in the image.

GEO_POINTS

Use this keyword to specify a 16-element array of double-precision, floating-point values representing geographic coordinates for the upper-left, upper-right, lower-left, and lower-right corners of the image. The array consists of four groups of x and y pixel locations and their corresponding latitude and longitude values with the form [x, y, lat, lon]. South latitudes and west longitudes have negative values. The array is defined as follows:

  • GEO_POINTS[0:3]: Upper left
  • GEO_POINTS[4:7]: Upper right
  • GEO_POINTS[8:11]: Lower left
  • GEO_POINTS[12:15]: Lower right

INFO (optional)

Use this keyword to store information that you can pass to your spatial and spectral readers. INFO is retrieved from ENVI_FILE_QUERY using the keyword H_INFO, which is a handle to the data. Use HANDLE_VALUE and the handle H_INFO to retrieve the data for INFO.

INHERIT (optional)

Use this keyword to specify the file inheritance. Set INHERIT equal to the value returned from ENVI_SET_INHERITANCE.

INVISIBLE (optional)

Set this keyword to prevent the file from automatically displaying in the ENVI Classic interface. This keyword only applies when using ENVI_OPEN_FILE in ENVI Classic programming. A file opened with the INVISIBLE keyword set will not appear in the Available Bands List and will not automatically display. Refer to "Programming in ENVI Classic" in ENVI Classic Help for more information.

LOOKUP (optional)

Use this keyword to specify an array of long integers representing class RGB values for classification images. The LOOKUP array contains an RGB triplet for each class specified by the keyword NUM_CLASSES. The dimensions of the array are [3, num_classes], and the RGB triplet is ordered [r, g , b]. You must set LOOKUP when entering a classification image.

MAP_INFO (optional)

Use this keyword to specify map information. Set MAP_INFO equal to the value returned from ENVI_MAP_INFO_CREATE.

NUM_CLASSES (optional)

Use this keyword to specify the number of classes for classification images. Remember to include Class 0 (“Unclassified”) in the number of classes. You only need to set NUM_CLASSES when entering a classification image.

PIXEL_SIZE (optional)

Use this keyword to specify the pixel size of images that are not georeferenced. PIXEL_SIZE is a two-element array of floating-point values representing the x and y pixel sizes, respectively.

R_FID (optional)

ENVI Classic library routines that result in new images also have an R_FID, or “returned FID.” This is simply a named variable containing the file ID to access the processed data. Specifying this keyword saves you the step of opening the new file from disk.

REFLECTANCE_SCALE_FACTOR (optional)

Use this keyword to specify a named variable that contains a single scalar number used to convert the input data into reflectance. For example, REFLECTANCE_SCALE_FACTOR would be used to convert integer scaled reflectance data into floating point [0, 1] reflectance values.

SENSOR_TYPE (optional)

Use this keyword to specify an integer value indicating the sensor type. See ENVI_SENSOR_TYPE for details on how to determine the integer value of a sensor type.

SPEC_NAMES (optional)

Use this keyword to specify a string array of spectral library names. You only need to set SPEC_NAMES when entering spectral library files.

UNITS (optional)

Use this keyword to specify the PIXEL_SIZE units for images that are not georeferenced. UNITS is an integer value returned from ENVI_TRANSLATE_PROJECTION_UNITS. Georeferenced images do not use this value. Instead, they use the pixel size and units contained in the map information structure.

WAVELENGTH_UNIT (optional)

Use this keyword to specify a named variable that contains one of the following values, indicating the wavelength units.

  • 0: Micrometers
  • 1: Nanometers
  • 2: Wavenumber
  • 3: GHz
  • 4: MHz
  • 5: Index
  • 6: Unknown

WL (optional)

Use this keyword to specify an array of wavelength values. The number of elements is equal to the number of bands.

XSTART (optional)

Use this keyword to specify the x starting sample for the first pixel in the file. The default value is 0. Use XSTART in conjunction with YSTART to preserve the spatial reference for subsetted files. When processing a file, you typically set the XSTART of the output file to the XSTART of the input file plus the value of DIMS[1] (the starting sample).

YSTART (optional)

Use this keyword to specify the y starting sample for the first pixel in the file. The default value is 0. Use YSTART in conjunction with XSTART to preserve the spatial reference for subsetted files. When processing a file, you typically set the YSTART of the output file to the YSTART of the input file plus the value of DIMS[3] (the starting line).

ZPLOT_AVERAGE (optional)

Use this keyword to specify a two-element array of long integers representing the x and y window size (in pixels) for the Z Profile. The window size must be a value of 1 or greater. The Z Profile is formed from the average of the profiles within the specified window. The default window size is [1, 1].

ZRANGE (optional)

Use this keyword to specify a 2D array for the lower and upper range used by default in spectral plots.

ZPLOT_TITLES (optional)

Use this keyword to specify a two-element string array for the x and y plot titles. The default x title is “Band Number” for images with no wavelength information and “Wavelength” for images with wavelength information. The default y axis title is “Value.”



© 2017 Exelis Visual Information Solutions, Inc. |  Legal
My Account    |    Buy    |    Contact Us