MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


Cg Direct3D9 Runtime API        cgD3D9EnableParameterShadowing(3)



NAME
     cgD3D9EnableParameterShadowing - enable or disable parameter
     shadowing for a program

SYNOPSIS
       #include 

       HRESULT cgD3D9EnableParameterShadowing( CGprogram program,
                                               CGbool enable );


PARAMETERS
     program The program in which to set the parameter shadowing
             state.

     enable  A boolean switch which controls parameter shadowing
             for program.

RETURN VALUES
     Returns D3DOK if the function succeeds.

     Returns the D3D failure code if the function fails due to a
     D3D call.

DESCRIPTION
     cgD3D9EnableParameterShadowing enables or disables parameter
     shadowing for a program.

     If parameter shadowing is enabled for a program, any call to
     set the value of a parameter for that program does not set
     any D3D state. Instead it merely shadows the value so it can
     be set during a subsequent call to cgD3D9BindProgram.

     If parameter shadowing is disabled, these calls immediately
     sets the D3D state and do not shadow the value.

     When using this call to disable parameter shadowing, all
     shadowed parameters for that program are immediately
     invalidated.  No D3D calls are made, so any active program
     retains its current D3D state.  However, subsequent calls to
     cgD3D9BindProgram for that program will not apply any
     shadowed state.  Parameter shadowing for the program will
     continue to be disabled until explicitly enabled with
     another call to cgD3D9EnableParameterShadowing.

     Parameter shadowing can also be specified during a call to
     cgD3D9LoadProgram.

EXAMPLES
       / prog is a CGprogram initialized elsewhere
       ...
       HRESULT hres = cgD3D9EnableParameterShadowing(prog, CGFALSE);



Cg Toolkit 2.1            Last change:                          1






Cg Direct3D9 Runtime API        cgD3D9EnableParameterShadowing(3)



ERORS
     cgD3D9Failed is generated if a D3D function returns an
     error.

     CGD3D9ERNOTLOADED is returned if program was not loaded
     with the cgD3D9LoadProgram.

HISTORY
     cgD3D9EnableParameterShadowing was introduced in Cg 1.1.

SEE ALSO
     cgD3D9IsParameterShadowingEnabled, cgD3D9LoadProgram











































Cg Toolkit 2.1            Last change:                          2



OpenSolaris man pages main menu

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