]> git.tdb.fi Git - libs/gl.git/blobdiff - source/vertexarray.h
Minor fixes, courtesy of Apple's compiler
[libs/gl.git] / source / vertexarray.h
index 26204b312134e4bc1c5ebf2ebe845c19ff205304..82a6b6ac5260cb3bd074404480187022f2b03b37 100644 (file)
@@ -26,10 +26,18 @@ public:
        };
 
 private:
+       struct Array
+       {
+               unsigned char component;
+               unsigned char offset;
+
+               Array();
+       };
+
        VertexFormat format;
        std::vector<float> data;
        unsigned stride;
-       std::vector<unsigned char> arrays;
+       std::vector<Array> arrays;
        RefPtr<Buffer> vbuf;
        bool defer_vbuf;
        mutable bool dirty;
@@ -62,6 +70,8 @@ public:
        const float *operator[](unsigned i) const { return &data[0]+i*stride; }
 
        void apply() const;
+private:
+       static void apply_arrays(const std::vector<Array> *, const std::vector<Array> *, const float *, unsigned);
 };
 
 } // namespace GL