]> git.tdb.fi Git - libs/gl.git/blobdiff - source/programdata.h
Throw an exception if there's too many uniforms in a ProgramData
[libs/gl.git] / source / programdata.h
index c367097bd886752fc94697ebfeb5c013acdffb64..d9eaf7469e337bf93f5ea64612b57e8f34d7fe54 100644 (file)
@@ -2,6 +2,7 @@
 #define MSP_GL_PROGRAMDATA_H_
 
 #include <map>
+#include <stdexcept>
 #include <msp/datafile/objectloader.h>
 #include "datatype.h"
 #include "matrix.h"
 namespace Msp {
 namespace GL {
 
+class too_many_uniforms: public std::runtime_error
+{
+public:
+       too_many_uniforms(const std::string &w): std::runtime_error(w) { }
+       virtual ~too_many_uniforms() throw() { }
+};
+
 class Buffer;
 class Uniform;
 class UniformBlock;