]> git.tdb.fi Git - libs/gl.git/blobdiff - source/core/uniformblock.h
Check the flat qualifier from the correct member
[libs/gl.git] / source / core / uniformblock.h
index 5e88f0f80de81919ebcc510defaccc6f778e7b47..1144158d2ee3ae760bb994be535b8657c9650faa 100644 (file)
@@ -11,10 +11,17 @@ namespace Msp {
 namespace GL {
 
 /**
-Stores uniforms with a specific layout.  Both named and default uniform blocks
-are supported.
+Stores uniform values in a block of memory.
+
+For named uniform blocks the values are stored according to the reflected
+layout of the block, ready for use by shaders.  For the default uniform block,
+the location of the uniform is multiplied by 16 to obtain the memory offset.
+
+Applications normally don't need to deal with UniformBlocks directly.  They're
+managed by the ProgramData class, which provides a higher-level interface for
+setting uniform values.
 */
-class UniformBlock: public UniformBlockBackend, public NonCopyable, public Bufferable
+class UniformBlock: public UniformBlockBackend, public Bufferable
 {
 private:
        std::vector<char> data;
@@ -29,6 +36,7 @@ private:
 
 public:
        void store(const ReflectData::UniformInfo &, std::size_t, const void *);
+       void check_store_range(std::size_t, std::size_t);
 };
 
 } // namespace GL