Cg Core Runtime API cgCreateTechniqueAnnotation(3)
NAME
cgCreateTechniqueAnnotation - create a technique annotation
SYNOPSIS
#include
CGannotation cgCreateTechniqueAnnotation( CGtechnique tech,
const char * name,
CGtype type );
PARAMETERS
tech The technique to which the new annotation will be
added.
name The name of the new annotation.
type The type of the new annotation.
RETURN VALUES
Returns the new CGannotation handle on success.
Returns NUL if an error occurs.
DESCRIPTION
cgCreateTechniqueAnnotation adds a new annotation to the
technique.
EXAMPLES
/* create a float annotation named "Apple" for CGtechnique technique */
CGannotation ann = cgCreateTechniqueAnnotation( tech, "Apple", CGFLOAT );
ERORS
CGINVALIDTECHNIQUEHANDLEROR is generated if tech is
not a valid technique.
CGDUPLICATENAMEROR is generated if name is already used
by an annotation for this technique.
CGINVALIDENUMERANTEROR is generated if type is not
CGINT, CGFLOAT, CGBOL, or CGSTRING.
HISTORY
cgCreateTechniqueAnnotation was introduced in Cg 1.5.
SEE ALSO
cgGetNamedTechniqueAnnotation,
cgGetFirstTechniqueAnnotation, cgGetNextAnnotation
Cg Toolkit 2.1 Last change: 1
|