BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
DetectorDescription/ROOTGeo/include/ROOTGeo/EmcROOTGeo.h
Go to the documentation of this file.
1//$id$
2/*
3 * 2004/11/29 Zhengyun You Peking University
4 * Emc Geometry General for EventDisplay
5 *
6 * 2004/12/11 Zhengyun You Peking University
7 * named from EmcGeo to EmcROOTGeo
8 * inherit from class SubDetectorROOTGeo
9 *
10 * 2005/04/04 Zhengyun You Peking University
11 * Emc End geometry added
12 */
13
14#ifndef EMC_ROOT_GEO_H
15#define EMC_ROOT_GEO_H
16
17#include <TGeoNode.h>
18#include <TGeoPhysicalNode.h>
19#include <TGeoVolume.h>
20
21#include "SubDetectorROOTGeo.h"
22/**
23 * Class EmcGeo contains all of the objects necessary to describe the
24 * emc geometry.
25 *
26 * @author Zhengyun You \URL{mailto:youzy@hep.pku.cn}
27 *
28 */
29
31public:
32 /// Constructor.
33 EmcROOTGeo();
34
35 /// Destructor.
37
38 /// Initialize the instance of ROOTGeo.
39 void InitFromGdml( const char* gdmlFile, const char* setupName );
40
41 /// Set the pointers to theirs nodes;
42 void SetNode();
43
44 /// Set default visual attributes;
45 void SetDefaultVis();
46
47 /// Set all visible;
48 void SetAllVisible();
49
50 /// Set quater visible;
51 void SetQuarterVisible();
52
53 /// Set the pointers to the physical nodes;
54 void SetPhysicalNode();
55
56 /// Get number of part;
57 int GetPartNb();
58
59 /// Get number of theta on part;
60 int GetThetaNb( int part );
61
62 /// Get number of phi on part;
63 int GetPhiNb( int part );
64
65 /// Get Emc volume;
66 TGeoVolume* GetVolumeEmc() { return m_Emc; }
67
68 /// Get part volume;
69 TGeoVolume* GetVolumePart( int part );
70
71 /// Get phi volume;
72 TGeoVolume* GetVolumePhi( int part, int phi );
73
74 /// Get theta volume;
75 TGeoVolume* GetVolumeTheta( int part, int phi, int theta );
76
77 /// Get crystal volume;
78 TGeoVolume* GetVolumeCrystal( int part, int phi, int theta );
79
80 /// Get part node;
81 TGeoNode* GetPart( int part );
82
83 /// Get phi node;
84 TGeoNode* GetPhi( int part, int phi );
85
86 /// Get theta node;
87 TGeoNode* GetTheta( int part, int phi, int theta );
88
89 /// Get crystal one;
90 TGeoNode* GetCrystal( int part, int phi, int theta );
91
92 /// Get crystal physical node;
93 TGeoPhysicalNode* GetPhysicalCrystal( int part, int phi, int theta );
94
95private:
96 static const int m_kPart = 3;
97 static const int m_kPhiBr = 120;
98 static const int m_kThetaBr = 44;
99 // static const int m_kPhiEc = 16;
100 // static const int m_kThetaEc = 35;
101 int m_kPhiEc;
102 int m_kThetaEc;
103
104 TGeoVolume* m_Emc;
105 TGeoNode* m_NodeTheta[m_kPart][m_kPhiBr][m_kThetaBr]; // m_kPhiBr > m_kPhiEc, m_kThetaBr >
106 // m_kThetaEc
107 TGeoPhysicalNode* m_PhysicalCrystal[m_kPart][m_kPhiBr][m_kThetaBr];
108
109 // Volume refer to logicalVolume, only refer to the one exists.
110 // Node refer to physicalVolume, each real theta has a corresponding physical volume,
111 // althought they may be the same one. PhysicalNode gives the path combined by physical
112 // volume, it's unique for each real theta.
113};
114
115#endif /* EMC_ROOT_GEO_H */
TGeoVolume * GetVolumeCrystal(int part, int phi, int theta)
Get crystal volume;.
TGeoNode * GetCrystal(int part, int phi, int theta)
Get crystal one;.
void InitFromGdml(const char *gdmlFile, const char *setupName)
Initialize the instance of ROOTGeo.
TGeoVolume * GetVolumeTheta(int part, int phi, int theta)
Get theta volume;.
TGeoNode * GetTheta(int part, int phi, int theta)
Get theta node;.
TGeoVolume * GetVolumePart(int part)
Get part volume;.
TGeoNode * GetPart(int part)
Get part node;.
void SetDefaultVis()
Set default visual attributes;.
int GetPhiNb(int part)
Get number of phi on part;.
TGeoVolume * GetVolumePhi(int part, int phi)
Get phi volume;.
void SetPhysicalNode()
Set the pointers to the physical nodes;.
void SetNode()
Set the pointers to theirs nodes;.
int GetThetaNb(int part)
Get number of theta on part;.
TGeoNode * GetPhi(int part, int phi)
Get phi node;.
TGeoPhysicalNode * GetPhysicalCrystal(int part, int phi, int theta)
Get crystal physical node;.
void SetQuarterVisible()
Set quater visible;.