VertexFormatTests VertexFormatPosition3DTextureUVColor Method Delta Engine Documentation

Namespace: DeltaEngine.Graphics.Tests
Assembly: DeltaEngine.Graphics.Tests (in DeltaEngine.Graphics.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public void VertexFormatPosition3DTextureUVColor()
Examples

[Test]
public void VertexFormatPosition3DTextureUVColor()
{
    var elements = new[] {
        new VertexElement(VertexElementType.Position3D),
        new VertexElement(VertexElementType.TextureUV),
        new VertexElement(VertexElementType.Color)};
    var format = new VertexFormat(elements);
    Assert.AreEqual(24, format.Stride);
    Assert.AreEqual(0, elements[0].Offset);
    Assert.AreEqual(12, elements[1].Offset);
    Assert.AreEqual(20, elements[2].Offset);
}
See Also