7#ifndef GLIM_GLIMBATCH_H
8#define GLIM_GLIMBATCH_H
22 void BeginBatch (
bool reserveBuffers =
true,
unsigned int vertexCount = 64 * 3,
unsigned int attributeCount = 1);
35 void Vertex (
float x,
float y,
float z = 0.0f);
55 GLIM_ATTRIBUTE Attribute4ub (
unsigned int attribLocation,
unsigned char a1,
unsigned char a2,
unsigned char a3,
unsigned char a4 = 255);
77 void Attribute4ub (
GLIM_ATTRIBUTE Attr,
unsigned char a1,
unsigned char a2,
unsigned char a3,
unsigned char a4 = 255) noexcept;
80 void Clear (
bool reserveBuffers,
unsigned int vertexCount,
unsigned int attributeCount);
An Implementation of the GLIM_Interface.
void Vertex(float x, float y, float z=0.0f)
Specifies a new vertex of a primitive.
void BeginBatch(bool reserveBuffers=true, unsigned int vertexCount=64 *3, unsigned int attributeCount=1)
GLIM_ATTRIBUTE Attribute4i(unsigned int attribLocation, int a1, int a2, int a3, int a4)
Specifies a new value for the attribute with the given name.
GLIM_ATTRIBUTE Attribute4ub(unsigned int attribLocation, unsigned char a1, unsigned char a2, unsigned char a3, unsigned char a4=255)
Specifies a new value for the attribute with the given name.
GLIM_ATTRIBUTE Attribute3i(unsigned int attribLocation, int a1, int a2, int a3)
Specifies a new value for the attribute with the given name.
glimBatchData & EndBatch(void) noexcept
Ends defining the batch. After this call "RenderBatch" can be called to actually render it.
unsigned int m_uiPrimitiveFirstIndex
GLIM_ATTRIBUTE Attribute1i(unsigned int attribLocation, int a1)
Specifies a new value for the attribute with the given location.
void Begin(GLIM_ENUM eType) noexcept
Begins gathering information about the given type of primitives.
const GLIM_BATCH & operator=(const GLIM_BATCH &cc)
GLIM_BATCH(const GLIM_BATCH &cc)
GLIM_ATTRIBUTE Attribute2i(unsigned int attribLocation, int a1, int a2)
Specifies a new value for the attribute with the given name.
GLIM_ATTRIBUTE Attribute1f(unsigned int attribLocation, float a1)
Specifies a new value for the attribute with the given name.
void End(void)
Ends gathering information about the primitives.
GLIM_ATTRIBUTE Attribute2f(unsigned int attribLocation, float a1, float a2)
Specifies a new value for the attribute with the given name.
unsigned int m_uiPrimitiveLastIndex
GLIM_ENUM m_PrimitiveType
unsigned int m_uiPrimitiveVertex
bool PrepareRender()
Renders n instances of the batch that has been defined previously.
GLIM_ATTRIBUTE Attribute3f(unsigned int attribLocation, float a1, float a2, float a3)
Specifies a new value for the attribute with the given name.
void Clear(bool reserveBuffers, unsigned int vertexCount, unsigned int attributeCount)
Deletes all data associated with this object.
bool isCleared(void) const noexcept
Returns true if the GLIM_BATCH contains no batch data.
GLIM_ATTRIBUTE Attribute4f(unsigned int attribLocation, float a1, float a2, float a3, float a4)
Specifies a new value for the attribute with the given name.
GLIM_ENUM
The enum holding all important GLIM configuration values.