]>
Commit | Line | Data |
---|---|---|
108bd0fe | 1 | #ifndef ALIITSV11HYBRID_H |
2 | #define ALIITSV11HYBRID_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
012f0f4c | 6 | // $Id$ |
7 | ||
8 | // $Log$ | |
bf210566 | 9 | // Revision 1.3 2007/05/08 16:57:42 masera |
10 | // Updates concerning the geometry: versioning system, new V11hybrid version, bug fixes (B.Nilsend and L. Gaudichet | |
11 | // | |
012f0f4c | 12 | |
108bd0fe | 13 | //======================================================================== |
14 | // | |
15 | // Geometry of the Inner Tracking System | |
16 | // | |
17 | // This geometry is a mix between the old geometry (originally coded | |
18 | // in AliITSvPPRasymmFMD) and the new TGeo geometry (v11). | |
19 | // | |
20 | // Ludovic Gaudichet (gaudichet@to.infn.it) | |
21 | // | |
22 | //======================================================================== | |
23 | ||
24 | #include "AliITS.h" | |
012f0f4c | 25 | #include "AliITSInitGeometry.h" |
108bd0fe | 26 | |
27 | class AliITSv11GeometrySDD; | |
bf210566 | 28 | class AliITSv11GeometrySSD; |
108bd0fe | 29 | |
30 | class AliITSv11Hybrid : public AliITS { | |
31 | ||
32 | public: | |
33 | AliITSv11Hybrid(); | |
34 | AliITSv11Hybrid(const char *name, const char *title); | |
35 | virtual ~AliITSv11Hybrid() ; | |
36 | virtual void BuildGeometry(); | |
37 | virtual void CreateGeometry(); | |
38 | virtual void CreateMaterials(); | |
39 | virtual Int_t IsVersion() const {// returns the ITS version number | |
40 | return 110;} | |
41 | virtual void Init(); | |
42 | virtual void SetDefaults(); | |
43 | virtual void DrawModule() const; | |
44 | virtual void StepManager(); | |
45 | virtual void AddAlignableVolumes() const; | |
46 | virtual void SetWriteDet(Bool_t det=kFALSE){ // set .det write | |
47 | fGeomDetOut = det;} | |
48 | virtual void SetWriteDet(const char *f){ // set write file | |
49 | strncpy(fWrite,f,60);fGeomDetOut = kTRUE;} | |
50 | virtual void SetReadDet(Bool_t det=kFALSE){ //set .det read | |
51 | fGeomDetIn = det;} | |
52 | virtual void SetReadDet(const char *f){ // set read file | |
53 | strncpy(fRead,f,60);fGeomDetIn = kTRUE;} | |
54 | virtual void SetEUCLIDFileName(const char *f){ // set write file | |
55 | fEuclidGeometry=f; SetEUCLID();} | |
56 | virtual void SetMinorVersion(Int_t v=2){ // Choose between existing minor versions | |
57 | fMinorVersion = v;} | |
58 | virtual void SetThicknessDet1(Float_t v=200.){ | |
59 | // Set detector thickness in layer 1 | |
60 | fDet1 = v;} | |
61 | virtual void SetThicknessDet2(Float_t v=200.){ | |
62 | // Set detector thickness in layer 2 | |
63 | fDet2 = v;} | |
64 | virtual void SetThicknessChip1(Float_t v=150.){ | |
65 | // Set chip thickness in layer 1 | |
66 | fChip1 = v;} | |
67 | virtual void SetThicknessChip2(Float_t v=150.){ | |
68 | // Set chip thickness in layer 2 | |
69 | fChip2 = v;} | |
70 | virtual void SetRails(Int_t v=0){ | |
71 | // Set flag for rails | |
72 | fRails = v;} | |
73 | virtual void SetCoolingFluid(Int_t v=1){ | |
74 | // Set flag for cooling fluid | |
75 | fFluid = v;} | |
76 | virtual void SetDensityServicesByThickness(){// uses services density | |
77 | // calculation based on the thickness of the services. | |
78 | fByThick = kTRUE;} | |
79 | virtual void SetDensityServicesByMass(){// uses services density | |
80 | // calculation based on the Mass of the services. | |
81 | fByThick = kFALSE;} | |
82 | virtual const char *GetEULIIDFileName() const{ // return .euc file name | |
83 | return fEuclidGeometry.Data();} | |
84 | virtual Bool_t GetWriteDet() const { // returns value GeomDetOut flag. | |
85 | return fGeomDetOut;} | |
86 | virtual Bool_t GetReadDet() const { // returns value GeomDetIn flag. | |
87 | return fGeomDetIn;} | |
88 | virtual char *GetReadDetFileName(){ // return .det read file name | |
89 | if(fRead[0]!='\0') return fRead; else return fEuclidGeomDet;} | |
90 | virtual char *GetWriteDetFileName(){ // return .det write file name | |
91 | if(fWrite[0]!='\0') return fWrite; else return fEuclidGeomDet;} | |
92 | virtual Int_t GetMajorVersion() const {// return Major Version Number | |
93 | return fMajorVersion;} | |
94 | virtual Int_t GetMinorVersion() const {// return Major Version Number | |
95 | return fMinorVersion;} | |
96 | virtual Float_t GetThicknessDet1() const { | |
97 | // Get detector thickness in layer 1 | |
98 | return fDet1;} | |
99 | virtual Float_t GetThicknessDet2() const { | |
100 | // Get detector thickness in layer 2 | |
101 | return fDet2;} | |
102 | virtual Float_t GetThicknessChip1() const { | |
103 | // Get chip thickness in layer 1 | |
104 | return fChip1;} | |
105 | virtual Float_t GetThicknessChip2()const { | |
106 | // Get chip thickness in layer 2 | |
107 | return fChip2;} | |
108 | virtual Int_t GetRails() const { | |
109 | // Get flag for rails | |
110 | return fRails;} | |
111 | virtual Int_t GetCoolingFluid() const{ | |
112 | // Get flag for cooling fluid | |
113 | return fFluid;} | |
114 | ||
115 | protected: | |
116 | void CreateOldGeometry(); | |
bf210566 | 117 | void SetT2Lmatrix(const char *name, Double_t yShift, |
118 | Bool_t yFlip, Bool_t yRot180=kFALSE) const; // Set T2L matrix in TGeoPNEntries | |
108bd0fe | 119 | |
120 | private: | |
121 | AliITSv11Hybrid(const AliITSv11Hybrid &source); // copy constructor | |
122 | AliITSv11Hybrid& operator=(const AliITSv11Hybrid &source); // assignment operator | |
123 | void InitAliITSgeom(); | |
124 | ||
108bd0fe | 125 | Bool_t fGeomDetOut; // Flag to write .det file out |
126 | Bool_t fGeomDetIn; // Flag to read .det file or directly from Geat. | |
127 | Bool_t fByThick; // Flag to use services materials by thickness | |
128 | // ture, or mass false. | |
129 | Int_t fMajorVersion; // Major version number == IsVersion | |
130 | Int_t fMinorVersion; // Minor version number | |
131 | char fEuclidGeomDet[60];// file where detector transormation are define. | |
132 | char fRead[60]; //! file name to read .det file | |
133 | char fWrite[60]; //! file name to write .det file | |
134 | Float_t fDet1; // thickness of detector in SPD layer 1 | |
135 | Float_t fDet2; // thickness of detector in SPD layer 2 | |
136 | Float_t fChip1; // thickness of chip in SPD layer 1 | |
137 | Float_t fChip2; // thickness of chip in SPD layer 2 | |
138 | Int_t fRails; // flag to switch rails on (=1) and off (=0) | |
139 | Int_t fFluid; // flag to switch between water (=1) and freon (=0) | |
140 | Int_t fIDMother; //! ITS Mother Volume id. | |
141 | ||
012f0f4c | 142 | AliITSInitGeometry fInitGeom; //! Get access to decoding and AliITSgeom init functins |
143 | AliITSv11GeometrySDD *fSDDgeom; //! SDD Geometry | |
bf210566 | 144 | AliITSv11GeometrySSD *fSSDgeom; //! SSD Geometry |
108bd0fe | 145 | |
bf210566 | 146 | ClassDef(AliITSv11Hybrid,3) |
108bd0fe | 147 | }; |
148 | ||
149 | #endif |