NCL Home > Documentation > HLUs > API

NhlAddPrimitive

The Fortran name of this function is NhlFAddPrimitive.

This function adds a Primitive object to the tfPolyDrawList of a Transform object.


C Synopsis

#include <ncarg/hlu/hlu.h>
#include <hfile for Transform class object>
#include <ncarg/hlu/Primitive.h>

NhlErrorTypes NhlAddPrimitive(
        	int transform_id,
        	int primitive_id,
        	int before_id
		)

Fortran Synopsis

      subroutine NhlFAddPrimitive(transform_id, primitive_id, before_id, err_id)
      integer transform_id, primitive_id, before_id, err_id

Arguments

transform_id (input)
Identifier of a Transform object to whose tfPolyDrawList the Primitive object is to be added.
primitive_id (input)
Identifier of the Primitive object to add to the tfPolyDrawList of the Transform object.
before_id
Identifier of a Primitive object already in the tfPolyDrawList or NullObjId. The Primitive object specified by primitive_id will be placed ahead of the Primitive object specified by before_id in the list. If set to NullObjId, the Primitive object specified by primitive_id will be placed at the end of the list.
err_id (output, Fortran only)
Error code.

Types

Type name:		NhlTErrorTypes
Definition:
typedef enum _NhlErrType{
	NhlFATAL	= -4,	/* "FATAL"	*/
	NhlWARNING	= -3,	/* "WARNING"	*/
	NhlINFO		= -2,	/* "INFO"	*/
	NhlNOERROR	= -1	/* "NOERROR"	*/
} NhlErrorTypes;