Semantics supported by Viewport 2.0 to be used with MShaderInstance

 
 
 

To hardware render effects in Viewport 2.0, you can use the following semantics with the MShaderInstance API class.

NoteThe dx11Shader.mll plug-in is an MPxShaderOverride. Therefore, it must parse the effects to determine and bind the semantics. By comparison, MshaderInstance does all this automatically, although it is more restrictive.
Semantic Usage Type Group
World World transformation Matrix Item
WorldTranspose World transformation, transposed Matrix Item
WorldInverse World transformation, inverted Matrix Item
WorldInverseTranspose World transformation, inverted and transposed Matrix Item
       
View View transformation Matrix Frame
ViewTranspose View transformation, transposed Matrix Frame
ViewInverse View transformation, inverted Matrix Frame
ViewInverseTranspose View transformation, inverted and transposed Matrix Frame
       
Projection Projection transformation Matrix Frame
ProjectionTranspose Projection transformation, transposed Matrix Frame
ProjectionInverse Projection transformation, inverted Matrix Frame
ProjectionInverseTranspose Projection transformation, inverted and transposed Matrix Frame
       
WorldView World-view transformation Matrix Item
WorldViewTranspose World-view transformation, transposed Matrix Item
WorldViewInverse World-view transformation, inverted Matrix Item
WorldViewInverseTranspose World-view transformation, inverted and transposed Matrix Item
       
ViewProjection View-projection transformation Matrix Frame
ViewProjectionTranspose View-projection transformation, transposed Matrix Frame
ViewProjectionInverse View-projection transformation, inverted Matrix Frame
ViewProjectionInverseTranspose View-projection transformation, inverted and transposed Matrix Frame
       
WorldViewProjection World-view-projection transformation Matrix Item
WorldViewProjectionTranspose World-view-projection transformation, transposed Matrix Item
WorldViewProjectionInverse World-view-projection transformation, inverted Matrix Item
WorldViewProjectionInverseTranspose World-view-projection transformation, inverted and transposed Matrix Item
       
ViewDirection World-space direction of the view (camera) Float3 Frame
ViewPosition World-space position of the view (camera) Float3 Frame
LocalViewer Whether a local or non-local view direction is to be used bool Frame
       
ViewportPixelSize Dimensions of the current viewport in pixels, width and height Float2 Frame
       
ClippingPlanes The coefficients of active clipping planes, one float4 per plane Float4 Array Clipping
ClippingPlaneCount The number of active clipping planes Int Clipping
       
AlphaTestFunction The alpha test comparison function

1 = Never

2 = Less

3 = Equal

4 = Less or Equal

5 = Greater

6 = Not Equal

7 = Greater or Equal

8 = Always

Int Alpha Test
AlphaTestReference The alpha test reference value, in the range of (0.0, 1.0) Float Alpha Test