cgD3D11GetCompiledProgram(3)

NAME
cgD3D11GetCompiledProgram - Gets the compiled shader as a ID3DBlob returned from Direct3D after cgD3D11LoadProgram is called.

SYNOPSIS
  #include <Cg/cgD3D11.h>

  ID3DBlob * cgD3D11GetCompiledProgram( CGprogram program );

PARAMETERS

program
    The program handle after a call to cgD3D11LoadProgram has been made.

RETURN VALUES
Returns a pointer to a ID3DBlob object containing the compiled shader code.

Returns NULL if the program was not loaded.

DESCRIPTION
cgD3D11GetCompiledProgram allows the user to get back the compiled shader from Direct3D once cgD3D11LoadProgram has been called.

EXAMPLES
CGprogram myCgProgram = cgCreateProgram( ... ); cgD3D11LoadProgram( myCgProgram, 0 );

ID3DBlob * obj = cgD3D11GetCompiledProgram( myCgProgram );

ERRORS
CG_INVALID_PROGRAM_HANDLE_ERROR is generated if the program is invalid.

HISTORY
cgD3D11GetCompiledProgram was introduced in Cg 3.0.

SEE ALSO
cgD3D11LoadProgram