From 783f4427bcc931122fbe6a5070a37806ef66240b Mon Sep 17 00:00:00 2001 From: cinnaboot Date: Sat, 29 Jan 2022 09:17:57 -0500 Subject: [PATCH] clean up initTransforms() a bit --- src/shader.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/shader.cpp b/src/shader.cpp index 03c1794..00c1316 100644 --- a/src/shader.cpp +++ b/src/shader.cpp @@ -246,9 +246,9 @@ initTransforms(MemoryArena* arena, xform_ubo->name = arenaCopyCStr(arena, "matrices"); glBindBuffer(xform_ubo->target, xform_ubo->id); - glBufferData(xform_ubo->target, sizeof(*xforms), xforms, - GL_DYNAMIC_DRAW); - // bindbufferbase + glBufferData(xform_ubo->target, sizeof(*xforms), xforms, GL_DYNAMIC_DRAW); + + // NOTE: bindbufferbase xform_ubo->binding_idx = gl_ctx->binding_count++; glBindBufferBase(xform_ubo->target, xform_ubo->binding_idx, xform_ubo->id); glBindBuffer(xform_ubo->target, 0);