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