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

GRendaccess/mgendac

intn GRendaccess(int32 ri_id)
ri_id

IN:

General raster image identifier returned by GRcreate or GRselect

Purpose

Terminates access to an general raster image.

Return value

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

Description

There should be one call to GRendaccess for every ri_id returned from GRselect and/or GRcreate. Attempts to access ri_id after the call to GRendaccess will result in an error condition.

Example

This example illustrates the use of GRendaccess:

     #include "hdf.h"

     int32 gr_id, ri_id, file_id, stat;
     char *name = "Image name";
     int32 ncomp = 2;
     int32 interlace_mode = MFGR_INTERLACE_PIXEL;
     int32 data_type = DFNT_UINT16;
     int32 dim_sizes[2];

     file_id = Hopen("myfile", DFACC_WRITE, 0);
     gr_id = GRstart(file_id);
     ri_id = GRcreate(gr_id, name, ncomp, data_type,
         interlace_mode, dim_sizes);

       ...
     stat = GRendaccess(ri_id);
     stat = GRend(gr_id);
     Hclose(file_id);
      
FORTRAN

integer function mgendac(ri_id)

integer ri_id



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

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