Table of Contents

Struct VertexPositionColorNormalTexture

Namespace
Microsoft.Xna.Framework.Graphics
Assembly
MonoGame.Framework.dll

Describes a custom vertex format structure that contains position, color, normal data, and one set of texture coordinates.

public struct VertexPositionColorNormalTexture : IVertexType
Implements
Inherited Members

Constructors

VertexPositionColorNormalTexture(Vector3, Color, Vector3, Vector2)

Creates an instance of VertexPositionColorTexture.

public VertexPositionColorNormalTexture(Vector3 position, Color color, Vector3 normal, Vector2 textureCoordinate)

Parameters

position Vector3

Position of the vertex.

color Color

Color of the vertex.

normal Vector3

The vertex normal.

textureCoordinate Vector2

Texture coordinate of the vertex.

Fields

Color

The vertex color.

public Color Color

Field Value

Color

Normal

The XYZ surface normal.

public Vector3 Normal

Field Value

Vector3

Position

The XYZ vertex position.

public Vector3 Position

Field Value

Vector3

TextureCoordinate

UV texture coordinates.

public Vector2 TextureCoordinate

Field Value

Vector2

VertexDeclaration

Vertex declaration, which defines per-vertex data.

public static readonly VertexDeclaration VertexDeclaration

Field Value

VertexDeclaration

Methods

Equals(object)

Compares an object with the vertex.

public override bool Equals(object obj)

Parameters

obj object

The object to compare.

Returns

bool

true if the object is equal to the current vertex; false otherwise.

GetHashCode()

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int

A 32-bit signed integer that is the hash code for this instance.

ToString()

Retrieves a string representation of this object.

public override string ToString()

Returns

string

String representation of this object.

Operators

operator ==(VertexPositionColorNormalTexture, VertexPositionColorNormalTexture)

Returns a value that indicates whether two VertexPositionColorNormalTexture are equal

public static bool operator ==(VertexPositionColorNormalTexture left, VertexPositionColorNormalTexture right)

Parameters

left VertexPositionColorNormalTexture

The object on the left of the equality operator.

right VertexPositionColorNormalTexture

The object on the right of the equality operator.

Returns

bool

true if the objects are the same; false otherwise.

operator !=(VertexPositionColorNormalTexture, VertexPositionColorNormalTexture)

Returns a value that indicates whether two VertexPositionColorNormalTexture are different

public static bool operator !=(VertexPositionColorNormalTexture left, VertexPositionColorNormalTexture right)

Parameters

left VertexPositionColorNormalTexture

The object on the left of the inequality operator.

right VertexPositionColorNormalTexture

The object on the right of the inequality operator.

Returns

bool

true if the objects are different; false otherwise.