Compounds | |
struct | DebugDumper |
class | ShAttrib |
A generic attribute (or parameter) holding N values. More... | |
class | ShBackend |
class | ShBackendCode |
class | ShBasicBlock |
A basic block. More... | |
class | ShBlock |
A generic block or token. More... | |
class | ShBlockList |
class | ShCheckDims |
Utility template to check whether dimensions are equal or scalar. More... | |
class | ShCheckDims< 1, false, 1, false > |
class | ShCheckDims< 1, false, 1, true > |
class | ShCheckDims< 1, true, 1, false > |
class | ShCheckDims< 1, true, 1, true > |
class | ShCheckDims< 1, true, N, ScalarRHS > |
class | ShCheckDims< N, false, N, false > |
class | ShCheckDims< N, false, N, true > |
class | ShCheckDims< N, ScalarLHS, 1, true > |
class | ShCheckDims< N, true, N, false > |
class | ShCheckDims< N, true, N, true > |
class | ShConstant |
A shader-compile-time constant. More... | |
class | ShCtrlGraph |
A control-flow graph. More... | |
struct | ShCtrlGraphBranch |
class | ShCtrlGraphNode |
class | ShCubeTextureNode |
class | ShDataTextureNode |
class | ShDomTree |
A dominator tree in a flowgraph. More... | |
struct | ShEnvironment |
Global settings for the current program. More... | |
class | ShException |
A generic exception. More... | |
class | ShImage |
class | ShImageException |
An exception relating to an ShImage operation. More... | |
class | ShIntEqual |
Enforce that A == B (will not instantiate otherwise). More... | |
class | ShIntEqual< A, A > |
struct | ShLifeTime |
class | ShLinearAllocator |
A simple, basic-block based linear register allocator. More... | |
class | ShMatrix |
A matrix of Rows by Cols elements. More... | |
class | ShMatrixRows |
A few rows from a matrix. More... | |
struct | ShOperationInfo |
Information related to a specific operation. More... | |
class | ShOptimizer |
class | ShParseException |
An exception representing a parse error. More... | |
class | ShParser |
class | ShProgramNode |
A particular Sh program. More... | |
class | ShRefCount |
A reference-counting smart pointer. More... | |
class | ShRefCountable |
A class which can be reference-counted. More... | |
class | ShStatement |
A single statement. More... | |
class | ShSwizzle |
Represents swizzling of a variable. More... | |
class | ShSwizzleException |
Thrown when an invalid swizzle is specified (e.g. More... | |
class | ShTexture |
class | ShTexture1D |
class | ShTexture2D |
class | ShTextureCube |
class | ShTextureNode |
class | ShToken |
A token in the (unparsed) parse tree. More... | |
struct | ShTokenArgument |
A token argument, e.g. to SH_IF or SH_FOR. More... | |
class | ShTokenizer |
A tokenizer. More... | |
class | ShTokenizerException |
An exception indicating a tokenizer error. More... | |
class | ShVariable |
A reference and interface to a generic n-tuple variable. More... | |
class | ShVariableN |
A variable of length N. More... | |
class | ShVariableNode |
A generic n-tuple variable. More... | |
Enumerations | |
enum | ShOperation { SH_OP_ASN, SH_OP_NEG, SH_OP_ADD, SH_OP_MUL, SH_OP_DIV, SH_OP_SLT, SH_OP_SLE, SH_OP_SGT, SH_OP_SGE, SH_OP_SEQ, SH_OP_SNE, SH_OP_ABS, SH_OP_ACOS, SH_OP_ASIN, SH_OP_ATAN, SH_OP_ATAN2, SH_OP_CEIL, SH_OP_COS, SH_OP_DOT, SH_OP_FRAC, SH_OP_MAX, SH_OP_MIN, SH_OP_POW, SH_OP_SIN, SH_OP_SQRT, SH_OP_NORM, SH_OP_TEX, SH_OP_COND, SH_OP_KIL } |
Kinds of operations. More... | |
enum | ShTokenType |
Possible types a token can have. More... | |
Functions | |
SH_SPECIAL_TYPE (ShColor, color) | |
An N-color. | |
template<int N, typename T> ShVariableN< N, T > | operator+ (const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Addition. | |
template<int N, typename T> ShVariableN< N, T > | operator- (const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Subtraction. | |
template<int N, int M, typename T> ShVariableN< N, T > | operator * (const ShVariableN< N, T > &left, const ShVariableN< M, T > &right) |
Componentwise/scalar multiplication. | |
template<int N, int M, typename T> ShVariableN< N, T > | operator/ (const ShVariableN< N, T > &left, const ShVariableN< M, T > &right) |
Componentwise/scalar division. | |
template<int N, typename T> ShVariableN< N, T > | operator^ (const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Conventional power operation. | |
template<int N, typename T> ShVariableN< N, T > | cond (const ShVariableN< N, T > &condition, const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Conditional assignment (COND/CMP) dest[i] = (src1[i] > 0.0 ? src2[i] : src3[i]) Note: CMP in the ARB_{vertex,fragment}_program spec has src1[i] < 0.0, not greater than. | |
template<int N, typename T> ShVariableN< N, T > | abs (const ShVariableN< N, T > &var) |
Absolute value. | |
template<int N, typename T> ShVariableN< N, T > | acos (const ShVariableN< N, T > &var) |
Arccosine of x. x in [-1, 1], result in [-pi/2, pi/2]. | |
template<int N, typename T> ShVariableN< N, T > | asin (const ShVariableN< N, T > &var) |
Arcsine of x. x in [-1, 1]. Result in [0, pi]. | |
template<int N, typename T> ShVariableN< N, T > | cos (const ShVariableN< N, T > &var) |
Cosine of x. | |
template<int N, typename T> ShVariableN< N, T > | frac (const ShVariableN< N, T > &var) |
Fractional part. | |
template<int N, typename T> ShVariableN< N, T > | max (const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Componentwise maximum. | |
template<int N, typename T> ShVariableN< N, T > | min (const ShVariableN< N, T > &left, const ShVariableN< N, T > &right) |
Componentwise minimum. | |
template<int N, typename T> ShVariableN< N, T > | sin (const ShVariableN< N, T > &var) |
Sine of x. | |
template<int Rows, int Cols, int Kind, typename T> ShMatrix< Cols, Rows, SH_VAR_TEMP, T > | transpose (const ShMatrix< Rows, Cols, Kind, T > &m) |
Transpose of a matrix. | |
template<int M, int N, int P, int Kind, int Kind2, typename T> ShMatrix< M, P, SH_VAR_TEMP, T > | operator| (const ShMatrix< M, N, Kind, T > &a, const ShMatrix< N, P, Kind2, T > &b) |
Matrix multiplication. | |
template<int M, int N, int Kind, typename T> ShVariableN< M, T > | operator| (const ShMatrix< M, N, Kind, T > &a, const ShVariableN< N, T > &b) |
Treat a variable as a column vector and multiply it with a matrix. | |
SH_SPECIAL_TYPE (ShNormal, surface normal) | |
A surface normal with N dimensions. | |
SH_SPECIAL_TYPE (ShPoint, point) | |
An N-Point. | |
SH_SPECIAL_TYPE_PARENT (ShPosition, position, ShPoint) | |
A vertex position. | |
SH_SPECIAL_TYPE (ShTexCoord, texture coordinate) | |
A texture coordinate with N dimensions. | |
std::ostream & | shPrintIndent (std::ostream &out, int indent) |
Print "indent" spaces to out. | |
SH_SPECIAL_TYPE (ShVector, vector) | |
An N-Vector. | |
Variables | |
const int | shShaderKinds |
How many kinds of shaders there are in the pipeline at most. | |
const ShOperationInfo | opInfo [] |
Update this if you add or change operations in ShOperation. | |
char * | tokenNames [] |
Names of token types. |
All Sh classes, functions and objects reside within this namespace.
|
Kinds of operations. If you change this, be sure to change the opInfo array in ShStatement.cpp
Definition at line 40 of file ShStatement.hpp. |
|
Possible types a token can have. If you add to this list or change it, be sure to change tokenNames in ShToken.cpp. Definition at line 42 of file ShToken.hpp. Referenced by SH::ShToken::type(). |
|
Update this if you add or change operations in ShOperation.
Definition at line 35 of file ShStatement.cpp. |
|
Names of token types. Change this if you change the ShTokenType enumeration.
Definition at line 38 of file ShToken.cpp. Referenced by SH::ShToken::print(). |