From e9cdd72ffc2c5ac9f26128afc884725c3da109e5 Mon Sep 17 00:00:00 2001 From: Josh Holtrop Date: Thu, 11 Jun 2015 21:14:35 -0400 Subject: [PATCH] specify attribute locations when creating Programs --- test/test.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test/test.cpp b/test/test.cpp index e06c4c5..e00b6fd 100644 --- a/test/test.cpp +++ b/test/test.cpp @@ -35,14 +35,14 @@ bool init(void) vs->create_from_file(GL_VERTEX_SHADER, "test/vert.glsl"); fs->create_from_file(GL_FRAGMENT_SHADER, "test/frag.glsl"); - program->create(vs, fs); -// program->bind_attribute("position", 0); + program->create(vs, fs, + "position", 0); vs2->create_from_file(GL_VERTEX_SHADER, "test/vert2.glsl"); fs2->create_from_file(GL_FRAGMENT_SHADER, "test/frag2.glsl"); - program2->create(vs2, fs2); -// program2->bind_attribute("position", 0); -// program2->bind_attribute("color", 1); + program2->create(vs2, fs2, + "position", 0, + "color", 1); GLfloat coords[] = { -0.5, -0.5,