...
The ordinal position of a parameter in the parameter table is the integer paramId
used to evaluate parameter inputs using the RixShadingContext::EvalParam
method. Because these need to be kept in sync, it is recommended that you create a parameter enumeration to keep (a private enum
type) to keep track of the order that your parameters were created in the table. The enumeration can be used later on when calling RixShadingContext::EvalParam
in the body of the shader. Following the three parameter table entries above:
Code Block |
---|
|
enum paramId
{
k_resultC=0, // output
k_density,
k_placementMatrix,
k_numParams
}; |
Note |
---|
In order to facilitate the reuse of the same parameter enumeration for pattern output computation, it is highly recommended that all outputs be placed at the beginning of the parameter table. |
Anchor |
---|
| synchronization |
---|
| synchronization |
---|
|
Synchronization
...