herr_t H5Zget_filter_info( H5Z_filter_t filter, unsigned int *filter_config )
SUBROUTINE h5zget_filter_info_f(filter, config_flags, hdferr)
INTEGER, INTENT(IN) :: filter ! Filter, may be one of the
INTEGER, INTENT(OUT) :: config_flags ! Bit field indicating whether
! a filter's encoder and/or
! decoder are available
INTEGER, INTENT(OUT) :: hdferr ! Error code
END SUBROUTINE h5zfilter_avail_f
IN: Identifier of the filter to query. See the introduction to this section of the reference manual for a list of valid filter identifiers.
unsigned int *filter_config
OUT: A bit field encoding the returned filter information
H5Zget_filter_inforetrieves information about a filter. At present, this means that the function retrieves a filter's configuration flags, indicating whether the filter is configured to decode data, to encode data, neither, or both.
Iffilter_configis not set toNULLprior to the function call, the returned parameter contains a bit field specifying the available filter configuration. The configuration flag values can then be determined through a series of bitwiseANDoperations, as described below.
Valid filter configuration flags include the following:
Encoding is enabled for this filter. In Fortran,H5Z_FILTER_ENCODE_ENABLED_F.
Decoding is enabled for this filter. In Fortran,H5Z_FILTER_DECODE_ENABLED_F.
(These flags are defined for C in the HDF5 Library source code fileH5Zpublic.h.)
A bitwiseANDof the returnedfilter_configand a valid filter configuration flag will reveal whether the related configuration option is available. For example, if the value of H5Z_FILTER_CONFIG_ENCODE_ENABLED & filter_config is true, i.e., greater than0(zero), the queried filter is configured to encode data; if the value isFALSE, i.e., equal to0(zero), the filter is not so configured.
If a filter is not encode-enabled, the correspondingH5Pset_*function will return an error if the filter is added to a dataset creation property list (which is required if the filter is to be used to encode that dataset). For example, if theH5Z_FILTER_CONFIG_ENCODE_ENABLEDflag is not returned for the SZIP filter,H5Z_FILTER_SZIP, a call toH5Pset_szipwill fail.
If a filter is not decode-enabled, the application will not be able to read an existing file encoded with that filter.
This function should be called, and the returnedfilter_configanalyzed, before calling any other function, such asH5Pset_szip, that might require a particular filter configuration.
Returns a non-negative value on success, a negative value on failure.
Function introduced in this release. Fortran subroutine introduced in this release.