NAME

cgGetNamedPass - get a technique pass by name

SYNOPSIS

  #include <Cg/cg.h>

  CGpass cgGetNamedPass( CGtechnique tech,
                         const char * name );

PARAMETERS

tech

The technique from which to retrieve the pass.

name

The name of the pass to retrieve.

RETURN VALUES

Returns the named pass from the technique. If the technique has no pass corresponding to name, NULL is returned.

DESCRIPTION

The passes of a technique can be retrieved directly by name using the cgGetNamedPass function. The names of the passes in a technique can be discovered by iterating through the technique's passes (see cgGetFirstPass and cgGetNextPass), calling cgGetPassName for each one in turn.

EXAMPLES

to-be-written

ERRORS

CG_INVALID_TECHNIQUE_HANDLE_ERROR is generated if tech does not refer to a valid technique.

HISTORY

cgGetNamedPass was introduced in Cg 1.4.

SEE ALSO

cgIsPass, cgGetFirstPass, cgGetNextPass, cgGetPassName