c_gofwr - Writes a record to a graphics overlay file

SYNTAX

#include "worgen.h"
#include "gof.h"
FUNCTION c_gofwr (fd, nbytes, type, gofptr, addrec)

     int                *fd;
     int		*nbytes;
     int		*type;
     union GOF		*gofptr;
     int 		*addrec;

PARAMETERS

fd (input, integer)

File descriptor of the GOF.

nbytes (output, integer)

The number of bytes to the next record. (i.e. the number of bytes to skip to set the file pointer to the beginning of the next record.)

type (input, integer)

The type of GOF record being written. Valid values are:

     = HDR:	for the GOF header record
     = HPOLIN:	for a line or polygon header record
		(i.e. the line or polygon record without X/Y pairs)
     = FPOLIN:	for a full line or polygon record
     = PNT:	for a point record
     = ANNOT:	for a full annotation record
     = XYPAIRS:	for X/Y point pairs of a line or polygon

gofptr (input, union)

A record that contains the GOF information. This union consists of four structures (HEADER, POINT, POLIN, and ANNOT). This union, as well as the structures, are defined in the gof.h include file.

addrec (input, integer)

Flag specifying whether to add records to the GOF or update existing records.

     = TRUE:	add the record
     = FALSE:	update existing record

DESCRIPTION

c_gofwr() is used to write a record to a graphics overlay file. If addrec is TRUE, then a new record will be added to the GOF. If addrec is FALSE, then an existing GOF record will be updated.

RETURN VALUE

c_gofwr() returns

     E_SUCC (0)  --> successful completion
     E_FAIL (-1) --> operation failed

SPECIAL CONSIDERATIONS

c_gofwr() is C callable only.