From: Mikko Rasa Date: Mon, 22 Aug 2016 17:19:41 +0000 (+0300) Subject: Add integer overload of ProgramData::uniform1_array X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=30b779a9542b8e8ae5d23758c8b6da24d22c7fd7;p=libs%2Fgl.git Add integer overload of ProgramData::uniform1_array --- diff --git a/source/programdata.cpp b/source/programdata.cpp index 4b39d196..f75a4ebd 100644 --- a/source/programdata.cpp +++ b/source/programdata.cpp @@ -177,6 +177,11 @@ void ProgramData::uniform_matrix4(const string &name, const float *v) uniform(name, new UniformMatrix4x4f(v)); } +void ProgramData::uniform1_array(const string &name, unsigned n, const int *v) +{ + uniform(name, new UniformArray(n, v)); +} + void ProgramData::uniform1_array(const string &name, unsigned n, const float *v) { uniform(name, new UniformArray(n, v)); diff --git a/source/programdata.h b/source/programdata.h index 196abcb1..6e4b53fe 100644 --- a/source/programdata.h +++ b/source/programdata.h @@ -116,6 +116,7 @@ public: void uniform_matrix3(const std::string &, const float *); void uniform(const std::string &, const Matrix &); void uniform_matrix4(const std::string &, const float *); + void uniform1_array(const std::string &, unsigned, const int *); void uniform1_array(const std::string &, unsigned, const float *); void uniform2_array(const std::string &, unsigned, const float *); void uniform3_array(const std::string &, unsigned, const float *);