diff --git a/libs/gfx/include/psemek/gfx/gltf_mesh.hpp b/libs/gfx/include/psemek/gfx/gltf_mesh.hpp index ef3ae6cb..83a25587 100644 --- a/libs/gfx/include/psemek/gfx/gltf_mesh.hpp +++ b/libs/gfx/include/psemek/gfx/gltf_mesh.hpp @@ -23,7 +23,7 @@ namespace psemek::gfx std::size_t index_offset; GLenum index_type; - void draw(); + void draw() const; }; std::vector primitives; diff --git a/libs/gfx/source/gltf_mesh.cpp b/libs/gfx/source/gltf_mesh.cpp index ce525b3e..ba9cd233 100644 --- a/libs/gfx/source/gltf_mesh.cpp +++ b/libs/gfx/source/gltf_mesh.cpp @@ -5,7 +5,7 @@ namespace psemek::gfx { - void gltf_mesh::mesh::primitive::draw() + void gltf_mesh::mesh::primitive::draw() const { vao.bind(); gl::DrawElements(gl::TRIANGLES, index_count, index_type, reinterpret_cast(index_offset));