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

GRreftoindex/mgr2idx

int32 GRreftoindex(int32 gr_id, uint16 ref)
gr_id

IN:

General raster interface identifier returned by GRstart

ref

IN:

Reference number to be mapped

Purpose

Maps the reference number of an image to an index.

Return value

Returns the index of the image if successful and FAIL (or -1) otherwise.

Description

In the same manner as GRnametoindex, this routine is commonly used for the purpose of accessing an image in conjunction with a call to GRselect.

Example

This example illustrates the use of GRreftoindex:

     #include "hdf.h"

     int32 gr_id, ri_id, index;
      uint16 ref;
        ...
      index = GRreftoindex(gr_id, ref);
     ri_id = GRselect(gr_id, index);
       ...
 
FORTRAN

integer function mgr2idx(gr_id, ref)

integer gr_id, ref



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

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