DecOp

Engine/source/shaderGen/shaderOp.h

More...

Private Types

Parent 

Public Functions

DecOp(Var * in1)
print(Stream & stream)

Detailed Description

DecOp - Declaration Operation - Used when declaring a variable in a shader feature. It will automatically print the type of the variable and then the variable name. If a shader feature set up code like:

Var *foo = new Var;
foo->setType( "float" );
foo->setName( "foo" );
LangElement *fooDecl = new DecOp( foo );

LangElement *statement = new GenOp( "   @ = 8.0 * 5.0;", fooDecl );

The output in the shader file would be:

float foo = 8.0 * 5.0;

Private Types

typedef ShaderOp Parent 

Public Functions

DecOp(Var * in1)

print(Stream & stream)

Reimplemented from: LangElement