AttributeType
Here are the different data types available for vertex attributes in a Mesh. The ones that have a smaller range take up less memory, which improves performance a bit. The "u" stands for "unsigned", which means it can't hold negative values but instead has a larger positive range.
Value | Description |
byte | A signed 8 bit number, from -128 to 127. |
ubyte | An unsigned 8 bit number, from 0 to 255. |
short | A signed 16 bit number, from -32768 to 32767. |
ushort | An unsigned 16 bit number, from 0 to 65535. |
int | A signed 32 bit number, from -2147483648 to 2147483647. |
uint | An unsigned 32 bit number, from 0 to 4294967295. |
float | A 32 bit floating-point number (large range, but can start to lose precision). |
See also
lovr.graphics.newMesh
Mesh:getVertexFormat
Mesh
lovr.graphics