00001 00002 00003 00005 00006 00011 00016 00021 // GLCylinder.h // 00023 00024 #ifndef GLCYLINDER_H 00025 #define GLCYLINDER_H 00026 00027 #include "X3DGLGeometry3DNode.h" 00028 00029 namespace X3DTK { 00030 namespace GL { 00031 00032 class CylinderDrawArray; 00033 00036 00037 class Cylinder : public X3DGeometry3DNode 00038 { 00039 public: 00041 Cylinder(); 00043 virtual SFNode clone() const; 00045 virtual ~Cylinder(); 00046 00048 void setRadius(SFFloat radius); 00050 void setHeight(SFFloat height); 00052 void setSide(SFBool side); 00054 void setBottom(SFBool bottom); 00056 void setTop(SFBool top); 00058 void setCylinderArray(CylinderDrawArray *cylinderArray); 00059 00061 inline SFFloat getRadius() const {return _radius;}; 00063 inline SFFloat getHeight() const {return _height;}; 00065 inline SFBool getSide() const {return _side;}; 00067 inline SFBool getBottom() const {return _bottom;}; 00069 inline SFBool getTop() const {return _top;}; 00071 inline CylinderDrawArray *getCylinderArray() const {return _cylinderArray;}; 00072 00074 virtual void update(); 00076 virtual void render() const; 00077 00078 protected: 00080 Cylinder(const Cylinder &C); 00081 00082 private: 00084 SFFloat _radius; 00086 SFFloat _height; 00088 SFBool _side; 00090 SFBool _bottom; 00092 SFBool _top; 00094 CylinderDrawArray *_cylinderArray; 00095 }; 00096 00097 } 00098 } 00099 00100 #endif