From 0c821b2eb013de712041d2b337612b9a6297695f Mon Sep 17 00:00:00 2001 From: "Steinar H. Gunderson" Date: Mon, 21 Dec 2015 13:46:23 +0100 Subject: [PATCH] Make register_int call register_uniform_int, now that we require GLSL 1.30. --- effect.cpp | 1 + effect.h | 5 +---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/effect.cpp b/effect.cpp index 9a30b93..3446b42 100644 --- a/effect.cpp +++ b/effect.cpp @@ -61,6 +61,7 @@ void Effect::register_int(const string &key, int *value) { assert(params_int.count(key) == 0); params_int[key] = value; + register_uniform_int(key, value); } void Effect::register_float(const string &key, float *value) diff --git a/effect.h b/effect.h index fe76a75..67e6423 100644 --- a/effect.h +++ b/effect.h @@ -316,11 +316,8 @@ protected: // // Neither of these take ownership of the pointer. - // int is special since GLSL pre-1.30 doesn't have integer uniforms. - // Thus, ints that you register will _not_ be converted to GLSL uniforms. + // These correspond directly to int/float/vec2/vec3/vec4 in GLSL. void register_int(const std::string &key, int *value); - - // These correspond directly to float/vec2/vec3/vec4 in GLSL. void register_float(const std::string &key, float *value); void register_vec2(const std::string &key, float *values); void register_vec3(const std::string &key, float *values); -- 2.39.2