00001 00002 // BoxDrawArray.h // 00004 00005 #ifndef BOXARRAY_H 00006 #define BOXARRAY_H 00007 00008 #include "X3DTypes.h" 00009 #include "X3DGLTypes.h" 00010 00011 #include <vector> 00012 00013 namespace X3DTK { 00014 namespace GL { 00015 00018 00019 class BoxDrawArray 00020 { 00021 public: 00023 static BoxDrawArray *getInstance(); 00025 void removeInstance(); 00026 00028 unsigned int getBoxSize() const; 00030 const void *getBoxVertexArrayAddress() const; 00032 const unsigned int *getBoxIndexArrayAddress() const; 00033 00034 private: 00036 BoxDrawArray(); 00037 00038 static int _count; 00039 static BoxDrawArray *_ref; 00040 00041 std::vector<N3F_V3F> _boxVertexArray; 00042 std::vector<unsigned int> _boxIndexArray; 00043 }; 00044 00045 } 00046 } 00047 00048 #endif