CGEM BOSS 6.6.5.i
BESIII Offline Software System
Loading...
Searching...
No Matches
BesGeometry.h
Go to the documentation of this file.
1//
2// BesGeometry.h
3//
4
5#ifndef BES_GEOMETRY
6#define BES_GEOMETRY
7
8#include <TGeometry.h>
9
10#include "BesView.h"
11#include "CgemROOTGeo.h"
12#include "MdcROOTGeo.h"
13#include "TofROOTGeo.h"
14#include "EmcROOTGeo.h"
15#include "MucROOTGeo.h"
16#include "BesCircle2D.h"
17#include "BesPolygon2D.h"
18
19class BesGeometry : public TObject {
20
21 public:
23 virtual ~BesGeometry();
24
25 //Long Peixun's update: Add parameters for MRPC and CGEM
26 virtual void InitFromGDML(const TString fPath, bool mrpc = false, bool cgem = false);
27 virtual void InitFromROOT(TGeoVolume* volBes);
28 virtual void InitGeometry();
29
30 const char* GetFilename(const char* RunPeriod);
31 virtual void SetDefaultVis();
32 virtual void SetPhysicalDefaultVis(); //Long Peixun's update: Reset 3D color
33 virtual void Draw(Option_t *option = "3D");
34 virtual void Draw3D();
35 virtual void Draw2DXY();
36 virtual void Draw2DZR();
37
38 //Long Peixun's update: Add CGEM unfolded drawing function
39 virtual void DrawCgemUF(int layer);
40
41 Float_t GetBesR() { return m_BesR; }
42 Float_t GetBesZ() { return m_BesZ; }
43
44 TGeoVolume *GetVolBes() { return m_Bes; }
45 TGeoVolume *GetVolumeBeamPipe() { return m_BeamPipe; }
46
47 CgemROOTGeo *GetCgemROOTGeo() { return m_CgemROOTGeo; } //Long Peixun's update: for CGEM
48 MdcROOTGeo *GetMdcROOTGeo() { return m_MdcROOTGeo; }
49 TofROOTGeo *GetTofROOTGeo() { return m_TofROOTGeo; }
50 EmcROOTGeo *GetEmcROOTGeo() { return m_EmcROOTGeo; }
51 MucROOTGeo *GetMucROOTGeo() { return m_MucROOTGeo; }
52
53 //Long Peixun update: Add CGEM Volume code
54 TGeoVolume *GetVolumeCgem() { return m_CgemROOTGeo->GetVolumeCgem(); }
55
56 TGeoVolume *GetVolumeMdc() { return m_MdcROOTGeo->GetVolumeMdc(); }
57 TGeoVolume *GetVolumeMdcSegment(int segment) { return m_MdcROOTGeo->GetVolumeSegment(segment); }
58 TGeoVolume *GetVolumeMdcLayer(int layer) { return m_MdcROOTGeo->GetVolumeLayer(layer); }
59 TGeoVolume *GetVolumeMdcReplica(int layer) { return m_MdcROOTGeo->GetVolumeReplica(layer); }
60 TGeoPhysicalNode *GetPhysicalMdcReplica(int layer, int replica) { return m_MdcROOTGeo->GetPhysicalReplica(layer, replica); }
61
62 TGeoVolume *GetVolumeTof() { return m_TofROOTGeo->GetVolumeTof(); }
63 //TGeoVolumeAssembly *GetVolumeTofAssembly(int part) { return m_TofROOTGeo->GetVolumeAssembly(part); }
64 //TGeoVolume *GetVolumeTofScin(int part) { return m_TofROOTGeo->GetVolumeScin(part); }
65 //TGeoVolume *GetVolumeTofBucket(int part) { return m_TofROOTGeo->GetVolumeBucket(part); }
66 TGeoPhysicalNode *GetPhysicalTofScin(int part, int layer, int scin) { return m_TofROOTGeo->GetPhysicalScin(part, layer, scin); }
67
68 TGeoVolume *GetVolumeEmc() { return m_EmcROOTGeo->GetVolumeEmc(); }
69 TGeoVolume *GetVolumeEmcPart(int part) { return m_EmcROOTGeo->GetVolumePart(part); }
70 TGeoVolume *GetVolumeEmcPhi(int part, int phi) { return m_EmcROOTGeo->GetVolumePhi(part, phi); }
71 TGeoVolume *GetVolumeEmcTheta(int part, int phi, int theta) { return m_EmcROOTGeo->GetVolumeTheta(part, phi, theta); }
72 TGeoVolume *GetVolumeEmcCrystal(int part, int phi, int theta) { return m_EmcROOTGeo->GetVolumeCrystal(part, phi, theta); }
73 TGeoPhysicalNode *GetPhysicalEmcCrystal(int part, int phi, int theta) { return m_EmcROOTGeo->GetPhysicalCrystal(part, phi, theta); }
74
75 TGeoVolume *GetVolumeMuc() { return m_MucROOTGeo->GetVolumeMuc(); }
76 TGeoVolume *GetVolumeMucAbsorber(int part, int seg, int absorber) { return m_MucROOTGeo->GetVolumeAbsorber(part, seg, absorber); }
77 TGeoVolume *GetVolumeMucAbsorberPanel(int part, int seg, int absorber, int panel) { return m_MucROOTGeo->GetVolumeAbsorberPanel(part, seg, absorber, panel); }
78 TGeoVolume *GetVolumeMucGap(int part, int seg, int gap) { return m_MucROOTGeo->GetVolumeGap(part, seg, gap); }
79 TGeoVolume *GetVolumeMucStripPlane(int part, int seg, int gap) { return m_MucROOTGeo->GetVolumeStripPlane(part, seg, gap); }
80 TGeoVolume *GetVolumeMucStrip(int part, int seg, int gap, int strip) { return m_MucROOTGeo->GetVolumeStripPlane(part, seg, gap); }
81 TGeoVolume *GetVolumeMucGasChamber(int part, int seg, int gap, int panel, int gasChamber) { return m_MucROOTGeo->GetVolumeGasChamber(part, seg, gap, panel, gasChamber); }
82 TGeoVolume *GetVolumeMucBakelite(int part, int seg, int gap, int RpcUpDown, int panel, int bakelite) { return m_MucROOTGeo->GetVolumeBakelite(part, seg, gap, RpcUpDown, panel, bakelite); }
83 TGeoPhysicalNode *GetPhysicalMucGap(int part, int seg, int gap) { return m_MucROOTGeo->GetPhysicalGap(part, seg, gap); }
84 TGeoPhysicalNode *GetPhysicalMucStrip(int part, int seg, int gap, int strip) { return m_MucROOTGeo->GetPhysicalStrip(part, seg, gap, strip); }
85
86 private:
87 Double_t m_BesR;
88 Double_t m_BesZ;
89
90 Double_t m_BeamPipeRMin;
91 Double_t m_BeamPipeRMax;
92 Double_t m_BeamPipeZ;
93
94 TGeoVolume *m_Bes; //Bes world volume
95 TGeoVolume *m_BeamPipe; //Beam Pipe volume
96 TGeoVolume *m_Cgem; //Long Peixun's update: Add CGEM detector
97 TGeoVolume *m_Mdc;
98 TGeoVolume *m_Tof;
99 TGeoVolume *m_Emc;
100 TGeoVolume *m_Muc;
101 TGeoPhysicalNode *m_phyBeamPipe; //Long Peixun's update: for BeamPipe full 3D view
102
103 CgemROOTGeo *m_CgemROOTGeo; //Long Peixun's update: CgemROOTGeo
104 MdcROOTGeo *m_MdcROOTGeo; //MdcROOTGeo
105 TofROOTGeo *m_TofROOTGeo; //TofROOTGeo
106 EmcROOTGeo *m_EmcROOTGeo; //EmcROOTGeo
107 MucROOTGeo *m_MucROOTGeo; //MucROOTGeo
108
109 BesCircle2D *m_BeamPipeXY;
110 BesPolygon2D *m_BeamPipeZR;
111 BesPolygon2D *m_ZRPlaneOnXY;
112
113 Int_t m_BeamPipeColor; //Long Peixun's update: color of beampipe
114
115 ClassDef(BesGeometry, 1) // Bes Geometry
116};
117
119
120#endif
R__EXTERN BesGeometry * gBesGeometry
float Float_t
CgemROOTGeo * GetCgemROOTGeo()
Definition BesGeometry.h:47
TGeoVolume * GetVolBes()
Definition BesGeometry.h:44
TGeoVolume * GetVolumeMucStrip(int part, int seg, int gap, int strip)
Definition BesGeometry.h:80
TGeoVolume * GetVolumeMdc()
Definition BesGeometry.h:56
TGeoVolume * GetVolumeMucGap(int part, int seg, int gap)
Definition BesGeometry.h:78
TGeoPhysicalNode * GetPhysicalMucGap(int part, int seg, int gap)
Definition BesGeometry.h:83
TGeoVolume * GetVolumeMdcReplica(int layer)
Definition BesGeometry.h:59
virtual void InitGeometry()
TGeoPhysicalNode * GetPhysicalEmcCrystal(int part, int phi, int theta)
Definition BesGeometry.h:73
TGeoVolume * GetVolumeMucAbsorber(int part, int seg, int absorber)
Definition BesGeometry.h:76
TGeoVolume * GetVolumeBeamPipe()
Definition BesGeometry.h:45
TGeoVolume * GetVolumeEmcPart(int part)
Definition BesGeometry.h:69
TGeoVolume * GetVolumeMuc()
Definition BesGeometry.h:75
virtual void SetDefaultVis()
TGeoVolume * GetVolumeMucStripPlane(int part, int seg, int gap)
Definition BesGeometry.h:79
virtual ~BesGeometry()
virtual void Draw2DXY()
TGeoVolume * GetVolumeMucGasChamber(int part, int seg, int gap, int panel, int gasChamber)
Definition BesGeometry.h:81
EmcROOTGeo * GetEmcROOTGeo()
Definition BesGeometry.h:50
TGeoVolume * GetVolumeTof()
Definition BesGeometry.h:62
const char * GetFilename(const char *RunPeriod)
virtual void InitFromGDML(const TString fPath, bool mrpc=false, bool cgem=false)
TGeoVolume * GetVolumeEmcCrystal(int part, int phi, int theta)
Definition BesGeometry.h:72
MdcROOTGeo * GetMdcROOTGeo()
Definition BesGeometry.h:48
virtual void SetPhysicalDefaultVis()
TGeoVolume * GetVolumeEmc()
Definition BesGeometry.h:68
virtual void DrawCgemUF(int layer)
TGeoVolume * GetVolumeMdcSegment(int segment)
Definition BesGeometry.h:57
TGeoPhysicalNode * GetPhysicalMucStrip(int part, int seg, int gap, int strip)
Definition BesGeometry.h:84
TGeoVolume * GetVolumeMucAbsorberPanel(int part, int seg, int absorber, int panel)
Definition BesGeometry.h:77
TGeoVolume * GetVolumeEmcPhi(int part, int phi)
Definition BesGeometry.h:70
Float_t GetBesR()
Definition BesGeometry.h:41
TGeoVolume * GetVolumeEmcTheta(int part, int phi, int theta)
Definition BesGeometry.h:71
TGeoVolume * GetVolumeMucBakelite(int part, int seg, int gap, int RpcUpDown, int panel, int bakelite)
Definition BesGeometry.h:82
Float_t GetBesZ()
Definition BesGeometry.h:42
TGeoVolume * GetVolumeMdcLayer(int layer)
Definition BesGeometry.h:58
TGeoPhysicalNode * GetPhysicalMdcReplica(int layer, int replica)
Definition BesGeometry.h:60
virtual void Draw2DZR()
TGeoPhysicalNode * GetPhysicalTofScin(int part, int layer, int scin)
Definition BesGeometry.h:66
TGeoVolume * GetVolumeCgem()
Definition BesGeometry.h:54
virtual void InitFromROOT(TGeoVolume *volBes)
virtual void Draw3D()
MucROOTGeo * GetMucROOTGeo()
Definition BesGeometry.h:51
TofROOTGeo * GetTofROOTGeo()
Definition BesGeometry.h:49
TGeoVolume * GetVolumeCgem() const
Definition CgemROOTGeo.h:70
TGeoVolume * GetVolumeCrystal(int part, int phi, int theta)
Get crystal volume;.
TGeoVolume * GetVolumeTheta(int part, int phi, int theta)
Get theta volume;.
TGeoVolume * GetVolumePart(int part)
Get part volume;.
TGeoVolume * GetVolumePhi(int part, int phi)
Get phi volume;
TGeoPhysicalNode * GetPhysicalCrystal(int part, int phi, int theta)
Get crystal physical node;.
TGeoVolume * GetVolumeLayer(int layer)
Get layer volume;
TGeoVolume * GetVolumeReplica(int layer)
Get replica volume;.
TGeoVolume * GetVolumeSegment(int segment)
Get segment volume;.
TGeoPhysicalNode * GetPhysicalReplica(int layer, int replica)
Get replica physical node;.
TGeoVolume * GetVolumeStripPlane(int part, int seg, int gap)
Get strip plane volume;.
TGeoVolume * GetVolumeGasChamber(int part, int seg, int gap, int panel, int gasChamber)
Get rpc gas chamber volume;
TGeoPhysicalNode * GetPhysicalStrip(int part, int seg, int gap, int strip)
Get strip physical node;.
TGeoVolume * GetVolumeBakelite(int part, int seg, int gap, int panel, int bakelite)
Get rpc bakelite volume;
TGeoVolume * GetVolumeAbsorberPanel(int part, int seg, int absorber, int panel)
Get absorber panel volume;
TGeoVolume * GetVolumeGap(int part, int seg, int gap)
Get gap volume;
TGeoVolume * GetVolumeAbsorber(int part, int seg, int absorber)
Get absorber volume;
TGeoPhysicalNode * GetPhysicalGap(int part, int seg, int gap)
Get rpc gas chamber node;
TGeoPhysicalNode * GetPhysicalScin(int part, int scin)
Get scintillator physical node;.
c1_1 Draw()