ENVINITF

This is a reference to an ENVINITF object that lets you programmatically interact with complex NITF and MIE4NITF datasets, much like the NITF Dataset Browser.

Example

; Start the application

e = ENVI(/HEADLESS)

 

; Open a NITF file

File = FILEPATH('MultiSegmentExample.ntf', $

  ROOT_DIR=e.ROOT_DIR, SUBDIRECTORY = ['data', 'NITFExamples'])

NITF = ENVINITF(File)

 

; Print the contents, which include the

; security banner and segments

Print, NITF

Result:

ENVINITF <276253>

URI: INSTALL_DIR\ENVIxx\data\NITFExamples\MultiSegmentExample.ntf

Security Banner: //US //UNCLASSIFIED //

  Camera Series: 0

  Image Segments: 4

    0: Image 1: Missing ID [1,024 x 1,024]

    1: Image 2: Missing ID [64 x 64]

    2: Image 3: 0000000003 [64 x 64]

    3: Image 4: 0000000001 [181 x 73]

  Text Segments: 1

  Annotation Segments: 0

  DES Segments: 0

Print the value of the NSEGMENTS property:

Print, NITF.NSEGMENTS

Result:

4     1     0

Syntax

Result = ENVINITF(Filename [, Properties=value] [, ERROR=value])

Return Value

This routine returns a reference to an ENVINITF object.

Methods

Dehydrate

GetAssociatedFiles

GetBandFields

GetBandValue

GetBandValues

GetDESData

GetDESUserDefinedDataFields

GetDESUserDefinedDataValue

GetDESXMLData

GetSecurityFields

GetSecurityValue

GetSegmentFields

GetSegmentValue

GetTextSegments

GetTREFields

GetTRENames

GetTREValue

Hydrate

OpenCameraSeries

OpenCameraSeriesFrames

OpenRaster

OpenVector

WriteMetadata

Arguments

Filename

Specify a fully qualified URI to a NITF or MIE4NITF file.

Properties

METADATA (Get)

An IDL dictionary of all NITF metadata contained in the file. This property only pertains to NITF files.

NASSOCIATED_FILES (Get)

The number of associated NITF files in a MIE4NITF file.

NFRAMES (Get)

A long-integer array of size [Number of Series] that contains the number of frames in each MIE4NITF camera series. The order of elements is the same as that of the SERIES_NAMES array.

NSEGMENTS (Get)

A three-element, long-integer array that contains the number of:

[0]: Image segments

[1]: Text segments

[2]: DES segments

NSERIES (Get)

The number of MIE4NITF camera series.

SECURITY_BANNER (Get)

A string containing the NITF security banner.

SERIES_NAMES (Get)

A string array of size [Number of Series] that contains the name of each MIE4NITF camera series. The order of elements is the same as that of the NFRAMES array.

URI (Get)

The input filename.

Keywords

BROWSER

Opens the NITF Browser, if running ENVI interactively.

ERROR

Set this keyword to a named variable that will contain any error message issued during execution of this routine. If no error occurs, the ERROR variable will be set to a null string (''). If an error occurs and the routine is a function, then the function result will be undefined.

When this keyword is not set and an error occurs, ENVI returns to the caller and execution halts. In this case, the error message is contained within !ERROR_STATE and can be caught using IDL's CATCH routine. See IDL Help for more information on !ERROR_STATE and CATCH.

See Manage Errors for more information on error handling in ENVI programming.

Version History

ENVI 5.6.1

Introduced

ENVI 5.6.2 Added WriteMetadata method function
ENVI 5.6.3

Added: GetBandFields, GetBandValue, GetBandValues, GetDESUserDefinedDataFields, and GetDESUserDefinedDataValue methods.

Deprecated: GetDESUserDefinedSubheaderFields and GetDESUserDefinedSubheaderValue methods, and shapefile DES.

ENVI 6.0 Added the BROWSER keyword. Added GetDESXMLData method

API Version

4.2

See Also

ENVINITFMetadata, ENVINITFCSMRasterSpatialRef, ENVIRasterSeries