SphereDrawArray.h

Go to the documentation of this file.
00001 #ifndef X3DTK_GL_SPHEREARRAY_H
00002 #define X3DTK_GL_SPHEREARRAY_H
00003 
00004 #include "GL_SceneGraphTypes.h"
00005 
00006 #include <vector>
00007 
00008 namespace X3DTK {
00009 namespace GL {
00010 
00020 class SphereDrawArray
00021 {
00022 public:
00024   static SphereDrawArray *getInstanceOfSection(unsigned int section);
00026   void removeInstance();
00027   
00029   unsigned int getSphereSize() const;
00031   const void *getSphereVertexArrayAddress() const;
00033   const unsigned int *getSphereIndexArrayAddress() const;
00034   
00035 private:
00036   unsigned int _section;
00037 
00040   SphereDrawArray(unsigned int section);
00041 
00042   typedef struct 
00043   {
00044     unsigned int count;
00045     SphereDrawArray *ref;
00046   } data;
00047   
00048   typedef std::list<std::pair<unsigned int, data> > refList;
00049 
00050   static refList _refList;
00051 
00052   std::vector<N3F_V3F> _sphereVertexArray;
00053   std::vector<unsigned int> _sphereIndexArray;
00054 };
00055 
00056 }
00057 }
00058 
00059 #endif

Generated on Fri Aug 27 13:16:22 2004 for X3DToolKit by doxygen 1.3.6