summaryrefslogtreecommitdiff
path: root/themes/TreeShape.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'themes/TreeShape.cpp')
-rw-r--r--themes/TreeShape.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/themes/TreeShape.cpp b/themes/TreeShape.cpp
index 797ceca..08170ea 100644
--- a/themes/TreeShape.cpp
+++ b/themes/TreeShape.cpp
@@ -59,6 +59,12 @@ TreeShapeLoadResult TreeShape::load(Renderer2d* renderer) {
glEnableVertexAttribArray(renderer->attributes.color);
glVertexAttribPointer(renderer->attributes.color, 4, GL_FLOAT, GL_FALSE, sizeof(Renderer2dVertex), (GLvoid *)offsetof(Renderer2dVertex, color));
+ for (int32 idx = 0; idx < 4; idx++) {
+ glEnableVertexAttribArray(renderer->attributes.vMatrix + idx);
+ glVertexAttribPointer(renderer->attributes.vMatrix + idx, 4, GL_FLOAT, GL_FALSE, sizeof(Renderer2dVertex), (GLvoid *)(offsetof(Renderer2dVertex, vMatrix) + (idx * 16)));
+ glVertexAttribDivisor(renderer->attributes.vMatrix + idx, 1);
+ }
+
glBindBuffer(GL_ARRAY_BUFFER, 0);
glBindVertexArray(0);