GraphicsAPI reference
Class VertexLayout
Namespace: MicroEngine.Graphics.Devices
Assembly: MicroEngine.Graphics.dll
Guide: The graphics device
Interleaved vertex layout of one vertex buffer (slot 0).
public sealed record VertexLayout : IEquatable<VertexLayout>Inheritance
Implements
Constructors
VertexLayout(int, IReadOnlyList<VertexAttribute>)
Interleaved vertex layout of one vertex buffer (slot 0).
public VertexLayout(int Stride, IReadOnlyList<VertexAttribute> Attributes)Parameters
Stride int
Bytes per vertex.
Attributes IReadOnlyList<VertexAttribute>
Attributes, at most MaxVertexAttributes.
Fields
Vertex2D
The layout of Vertex2D: position Float2 @0, texcoord Float2 @8, colour Float4 @16, stride 32.
public static readonly VertexLayout Vertex2DField Value
Properties
Attributes
Attributes, at most MaxVertexAttributes.
public IReadOnlyList<VertexAttribute> Attributes { get; init; }Property Value
IReadOnlyList<VertexAttribute>
Stride
Bytes per vertex.
public int Stride { get; init; }Property Value
Methods
<Clone>$()
public VertexLayout <Clone>$()Returns
Deconstruct(out int, out IReadOnlyList<VertexAttribute>)
public void Deconstruct(out int Stride, out IReadOnlyList<VertexAttribute> Attributes)Parameters
Stride int
Attributes IReadOnlyList<VertexAttribute>
Equals(object?)
public override bool Equals(object? obj)Parameters
obj object?
Returns
Equals(VertexLayout?)
public bool Equals(VertexLayout? other)Parameters
other VertexLayout?
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(VertexLayout?, VertexLayout?)
public static bool operator ==(VertexLayout? left, VertexLayout? right)Parameters
left VertexLayout?
right VertexLayout?
Returns
operator !=(VertexLayout?, VertexLayout?)
public static bool operator !=(VertexLayout? left, VertexLayout? right)Parameters
left VertexLayout?
right VertexLayout?