[Top] [Prev] [Next] [Bottom]

DFSDsetdimscale/dssdisc

intn DFSDsetdimscale (intn dim, int32 dimsize, VOIDP scale)
dim

IN:

Dimension this scale corresponds to

dimsize

IN:

Size of the scale buffer

scale

IN:

Buffer for the scale values

Purpose

Defines the scale for a dimension.

Return value

Returns SUCCEED (or 0) if successful and FAIL (or -1) otherwise.

Description

A scale is a one-dimensional array whose values describe reference points along one dimension of the dataset. For example, a two-dimensional dataset representing points on a map could have two scales, one representing points of latitude, and the other points of longitude.

Example

In this example a 200 x 300 data array is written to a file called "myfile.hdf", together with scales for each dimension. It is assumed that the arrays latscale and longscale have been assigned values that define the corresponding scales.

     float32 press1[200][300];
     float32 latscale[200], longscale[300];
     int dims[2];
     ...
     dims[0] = 200;
     dims[1] = 300;

     DFSDsetdims(2, dims);
     DFSDsetdimscale(1, dims[0], latscale);
     DFSDsetdimscale(2, dims[1], longscale);
     DFSDadddata("myfile.hdf", 2, dims, press1);
 
FORTRAN

integer function dssdisc (dim, dimsize, scale)

integer dim

integer dimsize(*), scale(*)



[Top] [Prev] [Next] [Bottom]

hdfhelp@ncsa.uiuc.edu
HDF User's Reference Manual, Draft 06/09/97, NCSA HDF Development Group.