HDF Interfaces

There are two basic interfaces to HDF files, the single-file application interface and the multiple-file application interface. These interfaces support eight different types (or "models") of data access. Data Access Models and Routine Prefixes. lists the different models and the names of the IDL routines that access those models. Each model is described in more detail after the table.

  • Data Access Models and Routine Prefixes.

Model

IDL Routine Name Prefix

24-bit raster

HDF_DF24_

annotation data

HDF_DFAN_

palette data

HDF_DFP_

8-bit raster

HDF_DFR8_

scientific data

HDF_DFSD_

multi-file scientific data

HDF_SD_

VData

HDF_VD_

VGroup

HDF_VG_

Single File Application Interfaces

In this mode, access is limited to one file at a time. This interface supports the 8-bit raster, 24-bit raster, palette, scientific data, and annotation models. The interfaces are described in more detail after the table.

8-bit Raster Model: The HDF_DFR8_ routines access 8-bit images.

Palette Model: The HDF_DFP_ routines are used to work with the HDF_DFR8_ routines to manipulate palettes associated with 8-bit HDF images.

24-bit Raster Model: The HDF_DFR24_ routines access 24-bit images.

Scientific Data Models (SDs): Used to manipulate arrays of arbitrary dimension and type. Under this model, an array accompanied by a record of its data type, dimensions and descriptors is called a Scientific Dataset (SD). HDF supports two kinds of SDs--the older single-file DFSD, and the new, NetCDF based, MFSD.

To show preference to the new format, HDF and IDL refer to "MFSD" as simply "SD". IDL calls to the SD model are distinguished by the prefix HDF_SD, while calls to the DFSD are distinguished by the HDF_DFSD prefix. Unfortunately, HDF4.0 uses the same tags for the two different scientific data models. Therefore, caution should be used when accessing the SDs through tags. IDL routines may seem to work, but may actually read incorrect information when tags, and not the standard HDF_SD_ routines, are used.

Annotation Model: The annotation model is used to describe the contents of the file through such items as labels, data descriptors, and dimension scales.

Vdata Model: This interface allows for the creation of customized tables. Each table consists of a series of Vdata records whose values are stored in fixed length fields. As described in more detail in the Vdata example below, a Vdata can contain three kinds of identifying information: a Vdata name, Vdata Class, and multiple Vdata field names. The Vdata model is accessed through the routines that begin with the HDF_VD_ prefix.

Vgroup Model: A collection of one or more data objects, Vdata sets, or Vgroups is known as a Vgroup. Each Vgroup can be given a Vgroup name and Vgroup class. The Vgroup model is accessed through the routines that begin with the HDF_VG_ prefix.

Multi-File Application Interface

The HDF_SD_ routines allow operations on more than one file at a time. This multi-file interoperability is achieved through HDF's use of a modified version of the NetCDF library. IDL's interface to HDF's multi-file capability is the HDF_SD_SETEXTFILE routine.