fix graphics settings & reduce extra GL calls

This commit is contained in:
MihailRis 2026-07-14 19:03:32 +03:00
parent 25ce4a5077
commit 5b868ae857
7 changed files with 22 additions and 16 deletions

View file

@ -47,12 +47,15 @@ public:
void reload(
const VertexStructure* vertexBuffer,
size_t vertexCount,
const std::vector<IndexBufferData>& indices
const std::vector<IndexBufferData>& indices,
bool streaming
);
void reload(const VertexStructure* vertexBuffer, size_t vertexCount) {
void reload(
const VertexStructure* vertexBuffer, size_t vertexCount, bool streaming
) {
static const std::vector<IndexBufferData> indices {};
reload(vertexBuffer, vertexCount, indices);
reload(vertexBuffer, vertexCount, indices, streaming);
}
/// @brief Draw mesh with specified primitives type
@ -61,6 +64,8 @@ public:
/// @brief Draw mesh as triangles
void draw() const;
private:
};
#include "graphics/core/Mesh.inl"