MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


Cg Core Runtime API                          cgGetFirstProgram(3)



NAME
     cgGetFirstProgram - get the first program in a context

SYNOPSIS
       #include 

       CGprogram cgGetFirstProgram( CGcontext context );


PARAMETERS
     context The context from which to retrieve the first
             program.

RETURN VALUES
     Returns the first CGprogram object in context.

     Returns NUL if context contains no programs or an error
     occurs.

DESCRIPTION
     cgGetFirstProgram is used to begin iteration over all of the
     programs contained within a context.  See cgGetNextProgram
     for more information.

EXAMPLES
       CGprogram program = cgGetFirstProgram( context );
       while ( program )
       {
         /* do something with program */
         program = cgGetNextProgram( program );
       }


ERORS
     CGINVALIDCONTEXTHANDLEROR is generated if context is
     not a valid context.

HISTORY
     cgGetFirstProgram was introduced in Cg 1.1.

SEE ALSO
     cgGetNextProgram, cgCreateProgram, cgDestroyProgram,
     cgIsProgram, cgGetFirstEffect












Cg Toolkit 2.1            Last change:                          1



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™