Name: H5Pset_shuffle
Signature:
  herr_t `H5Pset_shuffle`(hid_t `plist_id`)
Purpose:
  Sets up use of the shuffle filter.
Description:
  `H5Pset_shuffle` sets the shuffle filter, `H5Z_FILTER_SHUFFLE`, in the dataset creation property list `plist_id`.

  The shuffle filter de-interlaces a block of data by reordering the bytes. All the bytes from one consistent byte position of each data element are placed together in one block; all bytes from a second consistent byte position of each data element are placed together a second block; etc. For example, given three data elements of a 4-byte datatype stored as `012301230123`, shuffling will re-order data as `000111222333`. This can be a valuable step in an effective compression algorithm because the bytes in each byte position are often closely related to each other and putting them together can increase the compression ratio.

  As implied above, the primary value of the shuffle filter lies in its coordinated use with a compression filter; it does not provide data compression when used alone. When the shuffle filter is applied to a dataset immediately prior to the use of a compression filter, the compression ratio achieved is often superior to that achieved by the use of a compression filter without the shuffle filter.

Parameters:

hid_t `plist_id` | IN: Dataset creation property list identifier.

Returns:
  Returns a non-negative value if successful; otherwise returns a negative value.
Fortran90 Interface: h5pset_shuffle_f

      SUBROUTINE h5pset_shuffle_f(prp_id, hdferr)
        IMPLICIT NONE
        INTEGER(HID_T), INTENT(IN) :: prp_id      ! Property list identifier
        INTEGER, INTENT(OUT)       :: hdferr      ! Error code
                                                  ! 0 on success and -1 on failure
      END SUBROUTINE h5pset_shuffle_f

History:

Release | C
1.6.0 | Function introduced in this release.