4 using System.Runtime.InteropServices;
6 using SiliconStudio.Core.Mathematics;
8 namespace SiliconStudio.
Paradox.Graphics
13 [StructLayout(LayoutKind.Sequential)]
29 Swizzle = (int)swizzle;
55 public static readonly
int Size = 28;
73 public override bool Equals(
object obj)
75 if (ReferenceEquals(null, obj))
return false;
83 int hashCode = Position.GetHashCode();
86 hashCode = (hashCode * 397) ^ Swizzle.GetHashCode();
93 return left.Equals(right);
98 return !left.Equals(right);
103 return string.Format(
"Position: {0}, Color: {1}, Texcoord: {2}, Swizzle: {3}", Position,
Color,
TextureCoordinate, Swizzle);
static VertexElement Color(PixelFormat format, int offsetInBytes=AppendAligned)
Declares a VertexElement with the semantic "COLOR".
bool Equals(Color other)
Determines whether the specified Color is equal to this instance.
The layout of a vertex buffer with a set of VertexElement.
Represents a two dimensional mathematical vector.
static VertexElement TextureCoordinate(PixelFormat format, int offsetInBytes=AppendAligned)
Declares a VertexElement with the semantic "TEXCOORD".
Describes a custom vertex format structure that contains position, color, texture and swizzle informa...
TextureCoordinate
The texture coordinate.
Vector4 Position
XYZ position.
override int GetHashCode()
Returns a hash code for this instance.
Represents a four dimensional mathematical vector.
Color Color
The vertex color.
SiliconStudio.Core.Mathematics.Color Color
VertexPositionColorTextureSwizzle(Vector4 position, Color color, Vector2 textureCoordinate, SwizzleMode swizzle)
Initializes a new VertexPositionColorTexture instance.
Represents a 32-bit color (4 bytes) in the form of RGBA (in byte order: R, G, B, A).
static VertexElement Position(PixelFormat format, int offsetInBytes=AppendAligned)
Declares a VertexElement with the semantic "POSITION".
override bool Equals(object obj)
Vector2 TextureCoordinate
UV texture coordinates.
bool Equals(VertexPositionColorTextureSwizzle other)
override int GetHashCode()
SwizzleMode
Specify how to swizzle a vector.
PixelFormat
Defines various types of pixel formats.
override string ToString()
A description of a single element for the input-assembler stage. This structure is related to Direct3...
float Swizzle
The Swizzle mode