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