Class for the "NVIDIA Cg Shader Program".
More...
#include <spCgShaderProgram.hpp>
List of all members.
Public Member Functions |
virtual | ~CgShaderProgram () |
bool | compile (const std::list< io::stringc > &ShaderBuffer, const io::stringc &EntryPoint="", const c8 **CompilerOptions=0) |
virtual bool | setConstant (const io::stringc &Name, const f32 Value) |
virtual bool | setConstant (const io::stringc &Name, const f32 *Buffer, s32 Count) |
virtual bool | setConstant (const io::stringc &Name, const s32 Value) |
virtual bool | setConstant (const io::stringc &Name, const s32 *Buffer, s32 Count) |
virtual bool | setConstant (const io::stringc &Name, const dim::vector3df &Position) |
virtual bool | setConstant (const io::stringc &Name, const dim::vector4df &Position) |
virtual bool | setConstant (const io::stringc &Name, const video::color &Color) |
virtual bool | setConstant (const io::stringc &Name, const dim::matrix4f &Matrix) |
Protected Member Functions |
| CgShaderProgram (ShaderClass *Table, const EShaderTypes Type, const EShaderVersions Version) |
bool | createProgram (const io::stringc &SourceCodeString, const io::stringc &EntryPoint, const c8 **CompilerOptions=0) |
virtual bool | compileCg (const io::stringc &SourceCodeString, const io::stringc &EntryPoint, const c8 **CompilerOptions=0)=0 |
virtual void | bind ()=0 |
virtual void | unbind ()=0 |
bool | getParam (const io::stringc &Name) |
bool | setupShaderConstants () |
Protected Attributes |
CGprofile | cgProfile_ |
CGprogram | cgProgram_ |
std::map< std::string,
CGparameter > | ParameterMap_ |
Static Protected Attributes |
static CGparameter | ActiveParam_ |
Friends |
class | CgShaderClass |
Detailed Description
Class for the "NVIDIA Cg Shader Program".
Constructor & Destructor Documentation
virtual sp::video::CgShaderProgram::~CgShaderProgram |
( |
|
) |
[virtual] |
Member Function Documentation
virtual void sp::video::CgShaderProgram::bind |
( |
|
) |
[protected, pure virtual] |
bool sp::video::CgShaderProgram::compile |
( |
const std::list< io::stringc > & |
ShaderBuffer, |
|
|
const io::stringc & |
EntryPoint = "" , |
|
|
const c8 ** |
CompilerOptions = 0 | |
|
) |
| | [virtual] |
Compiles the given shader source code.
- Parameters:
-
[in] | ShaderBuffer | Specifies the shader source code in form of a string container. Each string line has to end with the end-of-line character ('
')! |
[in] | EntryPoint | Specifies the shader entry point. This not required for GLSL shaders. But for HLSL and Cg. It's actually just the shader's main function name. |
[in] | CompilerOptions | Specifies the pointer to the comiler option strings. |
- Returns:
- True if the shader could be compiled successful.
Reimplemented from sp::video::Shader.
virtual bool sp::video::CgShaderProgram::compileCg |
( |
const io::stringc & |
SourceCodeString, |
|
|
const io::stringc & |
EntryPoint, |
|
|
const c8 ** |
CompilerOptions = 0 | |
|
) |
| | [protected, pure virtual] |
bool sp::video::CgShaderProgram::createProgram |
( |
const io::stringc & |
SourceCodeString, |
|
|
const io::stringc & |
EntryPoint, |
|
|
const c8 ** |
CompilerOptions = 0 | |
|
) |
| | [protected] |
bool sp::video::CgShaderProgram::getParam |
( |
const io::stringc & |
Name |
) |
[protected] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const f32 |
Value | |
|
) |
| | [virtual] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const s32 |
Value | |
|
) |
| | [virtual] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const video::color & |
Color | |
|
) |
| | [virtual] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const dim::matrix4f & |
Matrix | |
|
) |
| | [virtual] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const f32 * |
Buffer, |
|
|
s32 |
Count | |
|
) |
| | [virtual] |
virtual bool sp::video::CgShaderProgram::setConstant |
( |
const io::stringc & |
Name, |
|
|
const s32 * |
Buffer, |
|
|
s32 |
Count | |
|
) |
| | [virtual] |
bool sp::video::CgShaderProgram::setupShaderConstants |
( |
|
) |
[protected] |
virtual void sp::video::CgShaderProgram::unbind |
( |
|
) |
[protected, pure virtual] |
Friends And Related Function Documentation
Member Data Documentation
The documentation for this class was generated from the following file:
- D:/SoftwareEntwicklung/C++/HLC/Tools/SoftPixelEngine/repository/sources/Framework/Cg/spCgShaderProgram.hpp