00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef FX_DISABLEGL
00025
00026 #if FX_GRAPHINGMODULE
00027
00028 #ifndef FXGLSPHERE_H
00029 #define FXGLSPHERE_H
00030
00031 #ifndef FXGLSHAPE_H
00032 #include "FXGLShape.h"
00033 #endif
00034
00035 namespace FX {
00036
00037
00039 class FXGRAPHINGMODULEAPI FXGLSphere : public FXGLShape {
00040 FXDECLARE(FXGLSphere)
00041 public:
00042 FXfloat radius;
00043 FXint slices;
00044 FXint stacks;
00045 protected:
00046 FXGLSphere();
00047 virtual void drawshape(FXGLViewer* viewer);
00048 public:
00049 enum {
00050 ID_LAST=FXGLShape::ID_LAST
00051 };
00052 public:
00053
00055 FXGLSphere(FXfloat x,FXfloat y,FXfloat z,FXfloat r=1.0f);
00056
00058 FXGLSphere(FXfloat x,FXfloat y,FXfloat z,FXfloat r,const FXMaterial& mtl);
00059
00061 FXGLSphere(const FXGLSphere& orig);
00062
00064 virtual FXGLObject* copy();
00065
00067 void setRadius(FXfloat r){ radius=r; }
00068 FXfloat getRadius() const { return radius; }
00069
00071 void setSlices(FXint s){ slices=s; }
00072 FXint getSlices() const { return slices; }
00073
00075 void setStacks(FXint s){ stacks=s; }
00076 FXint getStacks() const { return stacks; }
00077
00079 virtual void save(FXStream& store) const;
00080
00082 virtual void load(FXStream& store);
00083
00085 virtual ~FXGLSphere();
00086 };
00087
00088 }
00089
00090 #endif
00091 #endif
00092 #endif