VertexFormat

Vertex format elements list

Constructors

this
this(VertexElement[] elems)

make using element list

this
this(VertexElementType[] types)

init from vertex element types, using default sizes for types

Members

Functions

dump
string dump(float* data)
Undocumented in source. Be warned that the author may not have intended to support it.
elementOffset
int elementOffset(VertexElementType type)
Undocumented in source. Be warned that the author may not have intended to support it.
hasElement
bool hasElement(VertexElementType type)
Undocumented in source. Be warned that the author may not have intended to support it.
opEquals
bool opEquals(VertexFormat fmt)

compare

opIndex
VertexElement opIndex(int index)

get element by index

set
void set(float* vertex, VertexElementType type, vec2 value)

set vec2 component value of vertex

set
void set(float* vertex, VertexElementType type, vec3 value)

set vec3 component value of vertex

set
void set(float* vertex, VertexElementType type, vec4 value)

set vec4 component value of vertex

Properties

isValid
bool isValid [@property getter]

returns true if it's valid vertex format

length
int length [@property getter]

get number of elements

vertexFloats
int vertexFloats [@property getter]

returns vertex size in floats

vertexSize
int vertexSize [@property getter]

returns vertex size in bytes

Meta