cgGetFirstPassAnnotation
Keywords: cgGetFirstPassAnnotation, NVIDIA, NVIDIA Cg Toolkit, Cg Toolkit, Shader, Shader Programming, GPU Shader Programming, GPU Program

> ## Name

> cgGetFirstPassAnnotation - get the first annotation of a pass

> ## Synopsis

>     #include <Cg/cg.h>

>     CGannotation cgGetFirstPassAnnotation( CGpass pass );

> ## Parameters

> pass
>   The pass from which to retrieve the annotation.

> ## Return Values

> Returns the first annotation from the given pass.

> Returns NULL if the pass has no annotations or an error occurs.

> ## Description

> The annotations associated with a pass can be retrieved using cgGetFirstPassAnnotation. The remainder of the pass's annotations can be discovered by iterating through the parameters, calling cgGetNextAnnotation to get to the next one.

> ## Examples

>     CGannotation ann = cgGetFirstPassAnnotation( pass );
>     while( ann )
>     {
>        /* do something with ann */
>        ann = cgGetNextAnnotation( ann );
>     }

> ## Errors

> CG_INVALID_PASS_HANDLE_ERROR is generated if pass is not a valid pass.

> ## History

> cgGetFirstPassAnnotation was introduced in Cg 1.4.

> ## See Also

> cgGetNamedPassAnnotation, cgGetNextAnnotation