00001 #ifndef __PROG_PARAM__
00002 #define __PROG_PARAM__
00003
00004 #include "Uniform.h"
00005 #include "UniformGLSL.h"
00006
00007 namespace apig {
00008
00009
00010 class ProgParam {
00011 public:
00012 ProgParam(Uniform *value, UniformGLSL *param, bool ownValue) : value(value), param(param), ownValue(ownValue) {}
00013
00014 ~ProgParam() { delete param; if (ownValue) delete value; }
00015
00016 void update() const { value->update(param); }
00017
00018 private:
00019 Uniform *value;
00020 UniformGLSL *param;
00021 const bool ownValue;
00022 };
00023
00024 }
00025
00026 #endif