The HDF_READ function allows extraction of Hierarchical Data Format (HDF) data and metadata into an output structure based upon information provided through a graphical user interface or through a file template generated by HDF_BROWSER. The output structure is a single level structure corresponding to the data elements and names specified by HDF_BROWSER or it's output template. Templates generated by HDF_BROWSER may be re-used for HDF files of identical format.
This routine is written in the IDL language. Its source code can be found in the file
subdirectory of the IDL distribution.
Set this keyword to a named variable that will contain a 2 x n string array of extracted DFR8 images and their palettes. The first column will contain the extracted DFR8 image names, while the second column will contain the extracted name of the associated palette. If no palette is associated with a DFR8 image the palette name will be set to the null string. If no DFR8 images were extracted from the HDF file, this returned string will be the null string ('').
Set this keyword to a named variable that will contain a string array of the names of all the extracted DF24 24-bit images. This is useful in determining whether a (3, n , m ) extracted data element is a 24-bit image or another type of data. If no DF24 24-bit images were extracted from the HDF file, the returned string will be the null string ('').
Set this keyword to specify the HDF file template (generated by the function HDF_BROWSER), that defines which data elements to extract from the selected HDF file. Templates may be used on any files that have a format identical to the file the template was created from.
When HDF_READ is called without a template, it calls HDF_BROWSER to review the contents of an HDF file and create the default output names for the various data elements. By default, these names begin with a prefix derived from the filename. Set this keyword to a string value to be used in place of the default prefix.
NOTE: Vgroups and Vdata's are not currently supported. HDF files written with HDF4.1 or greater may not be readable. Because of a bug in HDF4.0r2, multiple use of HDF_READ or HDF_BROWSER on files containing both DFR8 and DF24 images may cause the DFR8 and DF24 interfaces to become unusable. In these cases, HDF_READ will not be able to extract DFR8 or DF24 images, and access to these interfaces will fail for the duration of the IDL session. Restarting IDL will allow you to again use HDF_READ to extract the contents of the HDF file.