]>
Commit | Line | Data |
---|---|---|
ab2f6604 | 1 | #ifndef ALIGTUBE_H |
2 | #define ALIGTUBE_H | |
3 | ||
4 | #include "AliGShape.h" | |
5 | ||
6 | const Int_t kDivNum = 20; //default number of divisions | |
7 | ||
8 | class AliGTube: public AliGShape { | |
9 | ||
10 | protected: | |
11 | Double_t* fCoTab; // Table of cos(fPhi1) .... cos(fPhil+fDphi1) | |
12 | Float_t fAspectRatio; // defines (the ellipse semi-axis in Y)/(the ellipse semi-axis in X) | |
13 | Float_t fDz; // half length in z | |
14 | Int_t fNdiv; // number of segments (precision) | |
15 | Float_t fRmax; // ellipse semi-axis in X outside | |
16 | Float_t fRmin; // ellipse semi-axis in X inside | |
17 | Double_t* fSiTab; // Table of sin(fPhi1) .... sin(fPhil+fDphi1) | |
18 | ||
19 | virtual void MakeTableOfCoSin(); // Create the table of the fSiTab; fCoTab | |
20 | ||
21 | public: | |
22 | AliGTube(); /* Default Constructor */ | |
23 | AliGTube( Text_t *name, Text_t *title, Float_t rmin, Float_t rmax, Float_t dz, Float_t aspect=1); /* Constructor*/ | |
24 | AliGTube( Text_t *name, Text_t *title, Float_t rmax, Float_t dz); /* Constructor */ | |
25 | AliGTube( AliGTube *tube ); | |
26 | ~AliGTube(); /* Destructor */ | |
27 | ||
28 | void Draw(Option_t *option); | |
29 | void DrawShape(Option_t *option); // *MENU* | |
30 | Float_t GetAspectRatio(){return fAspectRatio;} | |
31 | Float_t GetDz() {return fDz;} | |
32 | Int_t GetNdiv() {return fNdiv;} | |
33 | Int_t GetNumberOfDivisions () const {if (fNdiv) return fNdiv; else return kDivNum;} | |
34 | Float_t GetRmax() {return fRmax;} | |
35 | Float_t GetRmin() {return fRmin;} | |
36 | void Paint(Option_t *option); | |
37 | void PaintGLPoints(Float_t *vertex); | |
38 | void SetDz(Float_t dz) {fDz= dz;} | |
39 | void SetPoints(Float_t *buff); | |
40 | void SetRmin(Float_t rmin) {fRmin= rmin;} | |
41 | void SetRmax(Float_t rmax) {fRmax= rmax;} | |
42 | void Sizeof3D() const; | |
43 | ||
44 | ClassDef(AliGTube,1) // Simple cone class | |
45 | }; | |
46 | ||
47 | #endif |