TextureStateManager.TextureCoordinateIndex Property

Language:

Defines the index of the texture coordinate set to use with the current texture stage.

Definition

Visual Basic Public Property TextureCoordinateIndex As Integer
C# public int TextureCoordinateIndex { get; set; }
C++ public:
property int TextureCoordinateIndex {
        int get();
        void set(int value);
}
JScript public function get TextureCoordinateIndex() : int
public function set TextureCoordinateIndex(int);

Property Value

System.Int32
Index of the texture coordinate set.

This property is read/write. 

Remarks

Up to eight sets of texture coordinates per vertex can be specified. If a vertex does not include a set of texture coordinates at the specified index, the system reverts to the u and v coordinates (0,0) by default.

When rendering with vertex shaders, each stage's texture coordinate index must be set to its default value. The default index for each stage is equal to the stage index. Set this state to the zero-based index of the coordinate set for each vertex that this texture stage uses.

Additionally, applications can include TextureCoordinateIndex values as part of a logical OR with the index being set, to request that Microsoft DirectX automatically generate the input texture coordinates for a texture transformation.

The system uses the index strictly to determine texture wrapping mode when using a TextureCoordinateIndex value other than PassThru, which resolves to zero. These flags are most useful when performing environment mapping.


Send comments about this topic to Microsoft. © Microsoft Corporation. All rights reserved.

Feedback? Please provide us with your comments on this topic.