]> git.tdb.fi Git - libs/gl.git/blobdiff - source/primitivebuilder.h
Add append() method and and operator[] to VertexArray
[libs/gl.git] / source / primitivebuilder.h
index cfe0a02c8bbea18cf04ba114d8999c3514f70009..8cc1e7292b29598f1f93a228f4ee837459f1ff0a 100644 (file)
@@ -27,7 +27,7 @@ class PrimitiveBuilder: public VertexBuilder
 {
 protected:
        VertexArray &array;
-       RefPtr<VertexArrayBuilder> builder;
+       VertexArrayBuilder vab;
        PrimitiveType type;
        bool in_batch;
 
@@ -35,11 +35,13 @@ protected:
 public:
        void begin(PrimitiveType);
        void end();
+       void element(unsigned);
        PrimitiveType get_type() const;
 protected:
        virtual void vertex_(float, float, float, float);
        virtual void begin_() =0;
        virtual void end_() =0;
+       virtual void element_(unsigned) =0;
 };
 
 } // namespace GL