BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
MdcROOTGeo Class Reference

#include <MdcROOTGeo.h>

Inheritance diagram for MdcROOTGeo:

Public Member Functions

 MdcROOTGeo ()
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
 MdcROOTGeo (Bool_t cgem_flag=0)
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGDML (const char *gdmlFile, const char *setupName)
 Initialize ROOTGeo from GDML.
void InitFromROOT (TGeoVolume *vol)
 Initialize ROOTGeo from TGeoVolume logicalMdc.
void Init2DGeometry ()
 Initialize 2D Geometry.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetVolumeDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetHalfVisible ()
 Set half visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
void SetPhysicalDefaultVis ()
 Set default physical node attributes;.
void SetDetector ()
 Draw Detecor (what is detector depends on you).
void SetHits ()
 Set all physicalNodes corresponding to digiCol;.
void SetTFire (Bool_t input)
void SetQFire (Bool_t input)
void SetQNotOverflow (Bool_t input)
void SetColorfulWire (Bool_t input)
void SetMdcTimeSubEvTime (Bool_t input)
void SetVisMdcDetector ()
 Set Mdc default detector visibility;.
void SetVisMdcHits ()
 Set Mdc hits visibility;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
void SetVolumeMdc (TGeoVolume *vol)
 Set Mdc volume, while initializing from ROOT;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalSegment (int segment)
 Get segment physical node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
Mdc2DWireGet2DWire (Int_t layer, Int_t replica)
 Get Mdc2DWire;.
Int_t GetSimuLayer (Int_t trueLayer)
 Trans trueLayer to simuLayer (0~42)->(0~49).
Bool_t IsHit (Int_t layer, Int_t wire)
 Judge whether the digiCol contains (layer, wire).
void Draw (Option_t *option)
 Draw function.
void DrawHits (Option_t *option)
 Draw 2D hits.
 MdcROOTGeo (Bool_t cgem_flag=0)
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGDML (const char *gdmlFile, const char *setupName)
 Initialize ROOTGeo from GDML.
void InitFromROOT (TGeoVolume *vol)
 Initialize ROOTGeo from TGeoVolume logicalMdc.
void Init2DGeometry ()
 Initialize 2D Geometry.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetVolumeDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetHalfVisible ()
 Set half visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
void SetPhysicalDefaultVis ()
 Set default physical node attributes;.
void SetDetector ()
 Draw Detecor (what is detector depends on you).
void SetHits ()
 Set all physicalNodes corresponding to digiCol;.
void SetTFire (Bool_t input)
void SetQFire (Bool_t input)
void SetQNotOverflow (Bool_t input)
void SetColorfulWire (Bool_t input)
void SetMdcTimeSubEvTime (Bool_t input)
void SetVisMdcDetector ()
 Set Mdc default detector visibility;.
void SetVisMdcHits ()
 Set Mdc hits visibility;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
void SetVolumeMdc (TGeoVolume *vol)
 Set Mdc volume, while initializing from ROOT;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalSegment (int segment)
 Get segment physical node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
Mdc2DWireGet2DWire (Int_t layer, Int_t replica)
 Get Mdc2DWire;.
Int_t GetSimuLayer (Int_t trueLayer)
 Trans trueLayer to simuLayer (0~42)->(0~49).
Bool_t IsHit (Int_t layer, Int_t wire)
 Judge whether the digiCol contains (layer, wire).
void Draw (Option_t *option)
 Draw function.
void DrawHits (Option_t *option)
 Draw 2D hits.
 MdcROOTGeo ()
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
 MdcROOTGeo (Bool_t cgem_flag=0)
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGDML (const char *gdmlFile, const char *setupName)
 Initialize ROOTGeo from GDML.
void InitFromROOT (TGeoVolume *vol)
 Initialize ROOTGeo from TGeoVolume logicalMdc.
void Init2DGeometry ()
 Initialize 2D Geometry.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetVolumeDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetHalfVisible ()
 Set half visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
void SetPhysicalDefaultVis ()
 Set default physical node attributes;.
void SetDetector ()
 Draw Detecor (what is detector depends on you).
void SetHits ()
 Set all physicalNodes corresponding to digiCol;.
void SetTFire (Bool_t input)
void SetQFire (Bool_t input)
void SetQNotOverflow (Bool_t input)
void SetColorfulWire (Bool_t input)
void SetMdcTimeSubEvTime (Bool_t input)
void SetVisMdcDetector ()
 Set Mdc default detector visibility;.
void SetVisMdcHits ()
 Set Mdc hits visibility;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
void SetVolumeMdc (TGeoVolume *vol)
 Set Mdc volume, while initializing from ROOT;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalSegment (int segment)
 Get segment physical node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
Mdc2DWireGet2DWire (Int_t layer, Int_t replica)
 Get Mdc2DWire;.
Int_t GetSimuLayer (Int_t trueLayer)
 Trans trueLayer to simuLayer (0~42)->(0~49).
Bool_t IsHit (Int_t layer, Int_t wire)
 Judge whether the digiCol contains (layer, wire).
void Draw (Option_t *option)
 Draw function.
void DrawHits (Option_t *option)
 Draw 2D hits.
 MdcROOTGeo ()
 Constructor.
 ~MdcROOTGeo ()
 Destructor.
void InitFromGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
void SetNode ()
 Set the pointers to theirs nodes;.
int CorrectReplica (int layer, int replica)
 Correct some axial layer id to copyNo;.
void SetDefaultVis ()
 Set default visual attributes;.
void SetAllVisible ()
 Set all visible;.
void SetQuarterVisible ()
 Set quater visible;.
void SetPhysicalNode ()
 Set the pointers to the physical nodes;.
int GetSegmentNb ()
 Get number of segments;.
int GetLayerNb ()
 Get number of layers;.
int GetReplicaNb (int layer)
 Get number of replicas on each layer;.
TGeoVolume * GetVolumeMdc ()
 Get Mdc volume;.
TGeoVolume * GetVolumeSegment (int segment)
 Get segment volume;.
TGeoVolume * GetVolumeLayer (int layer)
 Get layer volume;.
TGeoVolume * GetVolumeReplica (int layer)
 Get replica volume;.
TGeoNode * GetSegment (int segment, int no)
 Get segment node;.
TGeoNode * GetLayer (int layer)
 Get layer node;.
TGeoNode * GetReplica (int layer, int replica)
 Get replica node;.
TGeoPhysicalNode * GetPhysicalReplica (int layer, int replica)
 Get replica physical node;.
Public Member Functions inherited from SubDetectorROOTGeo
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
void SetChildNo (int childNo)
TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
virtual void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
virtual int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
virtual void SetChildNo (int childNo)
virtual TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
virtual TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
virtual TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
virtual TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.
virtual int GetHitsNum ()
 Get number of hits in HitsArray;.
virtual TGeoPhysicalNode * GetHit (int i)
 Get ith hit in HitsArray;.
virtual void SetDetectorOn ()
 Set all physicalNodes in m_DeteorsArray visible;.
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
virtual void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
virtual int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
virtual void SetChildNo (int childNo)
virtual TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
virtual TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
virtual TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
virtual TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.
virtual int GetHitsNum ()
 Get number of hits in HitsArray;.
virtual TGeoPhysicalNode * GetHit (int i)
 Get ith hit in HitsArray;.
virtual void SetDetectorOn ()
 Set all physicalNodes in m_DeteorsArray visible;.
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
void SetChildNo (int childNo)
TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
virtual void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
virtual int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
virtual void SetChildNo (int childNo)
virtual TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
virtual TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
virtual TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
virtual TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.
virtual int GetHitsNum ()
 Get number of hits in HitsArray;.
virtual TGeoPhysicalNode * GetHit (int i)
 Get ith hit in HitsArray;.
virtual void SetDetectorOn ()
 Set all physicalNodes in m_DeteorsArray visible;.
 SubDetectorROOTGeo ()
 Constructor.
virtual ~SubDetectorROOTGeo ()
 Destructor.
void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of ROOTGeo.
int IsInitialized ()
 If the ROOT geometry of this subdetctor is initialized;.
void SetChildNo (int childNo)
TGeoVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
TGeoVolume * GetTopVolume ()
 Get the top(world) volume;.
TGeoVolumeAssembly * GetAssemblyVolume (const std::string &an)
 Get an assembly by name;.
TGeoNode * GetNode (const std::string &nn)
 Get a node(physical volume) by name;.

Additional Inherited Members

Protected Attributes inherited from SubDetectorROOTGeo
int m_ROOTGeoInit
int m_childNo
TGeoVolume * m_TopVolume
int m_2DGeoInit
TObjArray * m_DetectorsArray
TObjArray * m_HitsArray
TObjArray * m_2DHitsArray

Detailed Description

Class MdcGeo contains all of the objects necessary to describe the mdc geometry.

Author
Zhengyun You \URL{youzy.nosp@m.@hep.nosp@m..pku..nosp@m.cn}

Definition at line 29 of file DetectorDescription/ROOTGeo/include/ROOTGeo/MdcROOTGeo.h.

Constructor & Destructor Documentation

◆ MdcROOTGeo() [1/6]

MdcROOTGeo::MdcROOTGeo ( )

Constructor.

Definition at line 35 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

35 {
36 // Default constructor.
37 for ( int layer = 0; layer < m_kLayer; layer++ )
38 {
39 for ( int replica = 0; replica < m_kReplicaMax; replica++ )
40 {
41 m_NodeReplica[layer][replica] = 0;
42 m_PhysicalReplica[layer][replica] = 0;
43 }
44 }
45
46 for ( int i = 0; i < m_kCorrectLayer; i++ )
47 { m_CorrectMap[m_kiCorrectLayer[i]] = m_kiCorrectReplica[i]; }
48}

◆ ~MdcROOTGeo() [1/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

Definition at line 50 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

50{}

◆ MdcROOTGeo() [2/6]

MdcROOTGeo::MdcROOTGeo ( Bool_t cgem_flag = 0)

Constructor.

Definition at line 46 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

48 m_MdcColor = 3;
49 m_segmentColor = 0;
50 m_hypeColor = 3;
51 m_tubeColor = 4;
52 // m_twistedTubsColor = kBlue;
53 m_twistedTubsColor = 9; // Long Peixun's update: Blue -> Green, as same as XY View
54 // m_replicaColor = kCyan;
55 m_replicaColor = 8; // Long Peixun's update: Grey -> Blue, as same as XY View
56
57 // Long Peixun's update: According to CGEM flag, set start wire layer
58 if ( cgem_flag ) m_StartLayer = 8;
59 else m_StartLayer = 0;
60
61 k_TFire = kTRUE;
62 k_QFire = kTRUE;
63 k_QNotOverflow = kFALSE;
64
65 // Default constructor.
66 for ( int layer = 0; layer < m_kLayer; layer++ )
67 {
68 m_NodeLayer[layer] = 0;
69 for ( int replica = 0; replica < m_kReplicaMax; replica++ )
70 {
71 m_NodeReplica[layer][replica] = 0;
72 m_PhysicalReplica[layer][replica] = 0;
73 }
74 }
75
76 for ( int i = 0; i < m_kCorrectLayer; i++ )
77 { m_CorrectMap[m_kiCorrectLayer[i]] = m_kiCorrectReplica[i]; }
78
79 for ( int layer = 0; layer < m_kTrueLayer; layer++ )
80 {
81 for ( int replica = 0; replica < m_kReplicaMax; replica++ )
82 { m_Mdc2DWire[layer][replica] = 0; }
83 }
84}

◆ ~MdcROOTGeo() [2/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

◆ MdcROOTGeo() [3/6]

MdcROOTGeo::MdcROOTGeo ( Bool_t cgem_flag = 0)

Constructor.

◆ ~MdcROOTGeo() [3/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

◆ MdcROOTGeo() [4/6]

MdcROOTGeo::MdcROOTGeo ( )

Constructor.

◆ ~MdcROOTGeo() [4/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

◆ MdcROOTGeo() [5/6]

MdcROOTGeo::MdcROOTGeo ( Bool_t cgem_flag = 0)

Constructor.

◆ ~MdcROOTGeo() [5/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

◆ MdcROOTGeo() [6/6]

MdcROOTGeo::MdcROOTGeo ( )

Constructor.

◆ ~MdcROOTGeo() [6/6]

MdcROOTGeo::~MdcROOTGeo ( )

Destructor.

Member Function Documentation

◆ CorrectReplica() [1/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

Definition at line 132 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

132 {
133 int rep = replica;
134 for ( intMap::iterator iter = m_CorrectMap.begin(); iter != m_CorrectMap.end(); iter++ )
135 {
136 if ( layer == ( *iter ).first || ( layer >= m_kStereoLayerIn + m_kAxialLayerIn +
137 m_kStereoLayerOut + m_kAxialLayerOut &&
138 layer - m_kAxialLayerOut == ( *iter ).first ) )
139 {
140 rep -= ( *iter ).second;
141 if ( rep < 0 ) rep += m_kReplica[layer];
142 }
143 }
144
145 // std::cout << "layer" << layer << " " << replica << "->" << rep << std::endl;
146 return rep;
147}
EvtStreamInputIterator< typename Generator::result_type > iter(Generator gen, int N=0)

Referenced by SetNode().

◆ CorrectReplica() [2/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

◆ CorrectReplica() [3/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

◆ CorrectReplica() [4/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

◆ CorrectReplica() [5/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

◆ CorrectReplica() [6/6]

int MdcROOTGeo::CorrectReplica ( int layer,
int replica )

Correct some axial layer id to copyNo;.

◆ Draw() [1/3]

void MdcROOTGeo::Draw ( Option_t * option)

Draw function.

Definition at line 1102 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1102 {
1103 TString opt = option;
1104 opt.ToUpper();
1105
1106 if ( !m_2DGeoInit ) cout << "MdcROOTGeo::Draw2D(), 2D Geometry not initialized!" << endl;
1107 BesView* view = dynamic_cast<BesView*>( gPad->GetView() );
1108 if ( !view ) cout << "MdcROOTGeo::Draw(), BesView not found" << endl;
1109
1110 if ( view->GetVisMdcGlobal() )
1111 { // MdcVisGlobal
1112 if ( opt.Contains( "XY" ) )
1113 {
1114 m_MdcXY->Draw( "" );
1115 // Long Peixun's update: Annotate
1116 // for (Int_t i = 0; i < 4; i++) {
1117 // m_MdcXYSuper[i]->Draw("");
1118 // }
1119 }
1120
1121 if ( opt.Contains( "ZR" ) )
1122 {
1123 for ( Int_t i = 0; i < 2; i++ )
1124 {
1125 // m_MdcZR[i]->SetRotatable(true); //Long Peixun's update: Move to initializer
1126 m_MdcZR[i]->Draw( "" );
1127 }
1128 }
1129
1130 TString wireOpt;
1131 if ( view->GetVisMdcTubes() ) wireOpt += "TUBE";
1132 if ( view->GetVisMdcWires() ) wireOpt += ",WIRE";
1133
1134 Int_t replicaDraw = 0; // change draw sequence in a circle, (-1: 0->Max; 1: Max->0)
1135 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
1136 for ( Int_t layer = m_StartLayer; layer < m_kTrueLayer; layer++ )
1137 {
1138 Int_t simuLayer = GetSimuLayer( layer );
1139 for ( int replica = 0; replica < m_kReplica[simuLayer]; replica++ )
1140 {
1141 if ( m_kStereoDir[layer] == -1 ) replicaDraw = replica;
1142 else if ( m_kStereoDir[layer] == 1 ) replicaDraw = m_kReplica[simuLayer] - 1 - replica;
1143 else replicaDraw = replica;
1144
1145 if ( m_Mdc2DWire[layer][replicaDraw] )
1146 {
1147 // cout << layer << " " << replicaDraw << endl;
1148 // m_Mdc2DWire[layer][replicaDraw]->SetHighlighted(false);
1149 m_Mdc2DWire[layer][replicaDraw]->SetFired( false );
1150 m_Mdc2DWire[layer][replicaDraw]->Draw( wireOpt );
1151 }
1152 }
1153 }
1154 }
1155}
Int_t GetSimuLayer(Int_t trueLayer)
Trans trueLayer to simuLayer (0~42)->(0~49).

◆ Draw() [2/3]

void MdcROOTGeo::Draw ( Option_t * option)

Draw function.

◆ Draw() [3/3]

void MdcROOTGeo::Draw ( Option_t * option)

Draw function.

◆ DrawHits() [1/3]

void MdcROOTGeo::DrawHits ( Option_t * option)

Draw 2D hits.

Definition at line 1157 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1157 {
1158 // cout << "Draw Hits" << endl;
1159 BesView* view = dynamic_cast<BesView*>( gPad->GetView() );
1160 if ( !view ) cout << "MdcROOTGeo::DrawHits(), BesView not found" << endl;
1161
1162 // cout << "VisMdcHitsGlobal " << view->GetVisMdcHitsGlobal() << endl;
1163 // cout << "VisMdcHits " << view->GetVisMdcHits() << endl;
1164
1165 if ( view->GetVisMdcHitsGlobal() )
1166 {
1167 TString wireOpt( "" );
1168 if ( view->GetVisMdcTubes() ) wireOpt += ",TUBE";
1169 if ( view->GetVisMdcHits() ) wireOpt += ",WIRE";
1170
1171 // Long Peixun's update: Use m_2DHitsArray which contains ready hits rather than rebuild
1172 // hits
1173 for ( int i = 0; i < m_2DHitsArray->GetEntries(); ++i )
1174 {
1175 Mdc2DWire* aWire = (Mdc2DWire*)m_2DHitsArray->At( i );
1176 if ( aWire )
1177 {
1178 if ( ( k_TFire ) && ( aWire->GetTimeChannel() == 0x7FFFFFFF ) ) continue;
1179 if ( ( k_QFire ) && ( aWire->GetChargeChannel() == 0x7FFFFFFF ) ) continue;
1180 if ( ( k_QNotOverflow ) && aWire->GetQOverflow() ) continue;
1181 aWire->SetFired( true );
1182 aWire->SetColorfulWire( k_ColorfulWire, k_MdcTimeSubEvTime );
1183 aWire->Draw( wireOpt );
1184 }
1185 }
1186
1187 /* if (m_MdcDigiCol) {
1188 for (int i = 0; i < m_MdcDigiCol->GetEntries(); i++) {
1189 TMdcDigi *aMdcDigi = (TMdcDigi*)m_MdcDigiCol->At(i);
1190
1191 Identifier aMdcID( aMdcDigi->getIntId() );
1192 int layer = MdcID::layer( aMdcID );
1193 int wire = MdcID::wire( aMdcID );
1194 unsigned int overflow = aMdcDigi->getOverflow();
1195
1196 Mdc2DWire *aWire = 0;
1197 aWire = m_Mdc2DWire[layer][wire];
1198 if (aWire){
1199 if ((k_TFire) && (aMdcDigi->getTimeChannel() == 0x7FFFFFFF)){
1200 continue;
1201 }
1202 if ((k_QFire) && (aMdcDigi->getChargeChannel() == 0x7FFFFFFF)){
1203 continue;
1204 }
1205 //if ((!k_TOverflow) && ((overflow&1)>0) ){
1206 // continue;
1207 //}
1208 if ((k_QNotOverflow) && ((overflow&2)>0) ){
1209 continue;
1210 }
1211 aWire->SetFired(true);
1212 aWire->SetColorfulWire(k_ColorfulWire,k_MdcTimeSubEvTime);
1213 aWire->Draw(wireOpt);
1214 }
1215 }
1216 } */
1217 }
1218}
void SetColorfulWire(Bool_t colorfulWire, Bool_t subEvTime)
virtual void Draw(Option_t *option="")
virtual void SetFired(bool status=true)

◆ DrawHits() [2/3]

void MdcROOTGeo::DrawHits ( Option_t * option)

Draw 2D hits.

◆ DrawHits() [3/3]

void MdcROOTGeo::DrawHits ( Option_t * option)

Draw 2D hits.

◆ Get2DWire() [1/3]

Mdc2DWire * MdcROOTGeo::Get2DWire ( Int_t layer,
Int_t replica )

Get Mdc2DWire;.

Definition at line 1078 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1078 {
1079 if ( m_Mdc2DWire[layer][wire] ) return m_Mdc2DWire[layer][wire];
1080 else return 0;
1081}

◆ Get2DWire() [2/3]

Mdc2DWire * MdcROOTGeo::Get2DWire ( Int_t layer,
Int_t replica )

Get Mdc2DWire;.

◆ Get2DWire() [3/3]

Mdc2DWire * MdcROOTGeo::Get2DWire ( Int_t layer,
Int_t replica )

Get Mdc2DWire;.

◆ GetLayer() [1/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

Definition at line 403 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

403 {
404 std::stringstream osname;
405 if ( layer >= 0 && layer < m_kStereoLayerIn )
406 {
407 osname << "pv_"
408 << "logical"
409 << "Mdc"
410 << "Stereo"
411 << "Layer" << layer << "_" << layer;
412 }
413 else if ( layer >= m_kStereoLayerIn && layer < m_kStereoLayerIn + m_kAxialLayerIn )
414 {
415 osname << "pv_"
416 << "logical"
417 << "Mdc"
418 << "Axial"
419 << "Layer" << layer << "_" << layer;
420 }
421 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
422 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
423 {
424 osname << "pv_"
425 << "logical"
426 << "Mdc"
427 << "Stereo"
428 << "Layer" << layer << "_" << layer;
429 }
430 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut &&
431 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut )
432 {
433 osname << "pv_"
434 << "logical"
435 << "Mdc"
436 << "Axial"
437 << "Layer" << layer << "_0"
438 << "_" << 2 * layer - m_kStereoLayerIn - m_kAxialLayerIn - m_kStereoLayerOut;
439 }
440 else if ( layer >=
441 m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut &&
442 layer < m_kLayer )
443 {
444 osname << "pv_"
445 << "logical"
446 << "Mdc"
447 << "Axial"
448 << "Layer" << layer - m_kAxialLayerOut << "_1"
449 << "_"
450 << 2 * ( layer - m_kAxialLayerOut ) - m_kStereoLayerIn - m_kAxialLayerIn -
451 m_kStereoLayerOut + 1;
452 }
453
454 // std::cout << osname.str() << std::endl;
455 return GetNode( osname.str() );
456}
TGeoNode * GetNode(const std::string &nn)
Get a node(physical volume) by name;.

Referenced by Init2DGeometry(), SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetPhysicalNode(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetLayer() [2/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

◆ GetLayer() [3/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

◆ GetLayer() [4/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

◆ GetLayer() [5/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

◆ GetLayer() [6/6]

TGeoNode * MdcROOTGeo::GetLayer ( int layer)

Get layer node;.

◆ GetLayerNb() [1/6]

int MdcROOTGeo::GetLayerNb ( )

Get number of layers;.

◆ GetLayerNb() [2/6]

int MdcROOTGeo::GetLayerNb ( )
inline

Get number of layers;.

Definition at line 95 of file EventDisplay/BesVisLib/include/BesVisLib/MdcROOTGeo.h.

95{ return m_kLayer; }

◆ GetLayerNb() [3/6]

int MdcROOTGeo::GetLayerNb ( )
inline

Get number of layers;.

Definition at line 95 of file InstallArea/x86_64-el9-gcc13-dbg/include/BesVisLib/MdcROOTGeo.h.

95{ return m_kLayer; }

◆ GetLayerNb() [4/6]

int MdcROOTGeo::GetLayerNb ( )

Get number of layers;.

◆ GetLayerNb() [5/6]

int MdcROOTGeo::GetLayerNb ( )
inline

Get number of layers;.

Definition at line 95 of file InstallArea/x86_64-el9-gcc13-opt/include/BesVisLib/MdcROOTGeo.h.

95{ return m_kLayer; }

◆ GetLayerNb() [6/6]

int MdcROOTGeo::GetLayerNb ( )

Get number of layers;.

◆ GetPhysicalReplica() [1/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

Definition at line 472 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

472 {
473 if ( m_PhysicalReplica[layer][replica] != 0 ) { return m_PhysicalReplica[layer][replica]; }
474 else
475 {
476 std::cout << "PhysicalNode: "
477 << "Layer" << layer << "Replica" << replica << " not found" << std::endl;
478 return 0;
479 }
480}

Referenced by Init2DGeometry(), SetHits(), and SetPhysicalDefaultVis().

◆ GetPhysicalReplica() [2/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

◆ GetPhysicalReplica() [3/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

◆ GetPhysicalReplica() [4/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

◆ GetPhysicalReplica() [5/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

◆ GetPhysicalReplica() [6/6]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalReplica ( int layer,
int replica )

Get replica physical node;.

◆ GetPhysicalSegment() [1/3]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalSegment ( int segment)

Get segment physical node;.

Definition at line 1059 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1059 {
1060 if ( m_PhysicalSegment[segment] != 0 ) { return m_PhysicalSegment[segment]; }
1061 else
1062 {
1063 // std::cout << "PhysicalNode: " << "Segment" << segment << " not found" << std::endl;
1064 return 0;
1065 }
1066}

◆ GetPhysicalSegment() [2/3]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalSegment ( int segment)

Get segment physical node;.

◆ GetPhysicalSegment() [3/3]

TGeoPhysicalNode * MdcROOTGeo::GetPhysicalSegment ( int segment)

Get segment physical node;.

◆ GetReplica() [1/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

Definition at line 458 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

458 {
459 if ( m_NodeReplica[layer][replica] != 0 )
460 {
461 // std::cout << " replica " << layer << " " << replica << " found " << std::endl;
462 return m_NodeReplica[layer][replica];
463 }
464 else
465 {
466 std::cout << "Node: "
467 << "Layer" << layer << "Replica" << replica << " not found" << std::endl;
468 return 0;
469 }
470}

Referenced by SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetPhysicalNode(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetReplica() [2/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

◆ GetReplica() [3/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

◆ GetReplica() [4/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

◆ GetReplica() [5/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

◆ GetReplica() [6/6]

TGeoNode * MdcROOTGeo::GetReplica ( int layer,
int replica )

Get replica node;.

◆ GetReplicaNb() [1/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 65 of file DetectorDescription/ROOTGeo/include/ROOTGeo/MdcROOTGeo.h.

65{ return m_kReplica[layer]; }

◆ GetReplicaNb() [2/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 98 of file EventDisplay/BesVisLib/include/BesVisLib/MdcROOTGeo.h.

98{ return m_kReplica[layer]; }

◆ GetReplicaNb() [3/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 98 of file InstallArea/x86_64-el9-gcc13-dbg/include/BesVisLib/MdcROOTGeo.h.

98{ return m_kReplica[layer]; }

◆ GetReplicaNb() [4/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 65 of file InstallArea/x86_64-el9-gcc13-dbg/include/ROOTGeo/MdcROOTGeo.h.

65{ return m_kReplica[layer]; }

◆ GetReplicaNb() [5/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 98 of file InstallArea/x86_64-el9-gcc13-opt/include/BesVisLib/MdcROOTGeo.h.

98{ return m_kReplica[layer]; }

◆ GetReplicaNb() [6/6]

int MdcROOTGeo::GetReplicaNb ( int layer)
inline

Get number of replicas on each layer;.

Definition at line 65 of file InstallArea/x86_64-el9-gcc13-opt/include/ROOTGeo/MdcROOTGeo.h.

65{ return m_kReplica[layer]; }

◆ GetSegment() [1/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

Definition at line 383 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

383 {
384 std::stringstream osname;
385 if ( segment == 1 || segment == 2 )
386 {
387 osname << "pv_"
388 << "logical"
389 << "Mdc"
390 << "Segment" << segment << "_" << m_kLayer + segment - 1;
391 }
392 else
393 {
394 osname << "pv_"
395 << "logical"
396 << "Mdc"
397 << "Segment" << segment << "_" << m_kLayer + 2 + ( segment - 3 ) * 2 + no;
398 }
399
400 return GetNode( osname.str() );
401}

Referenced by SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetSegment() [2/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

◆ GetSegment() [3/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

◆ GetSegment() [4/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

◆ GetSegment() [5/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

◆ GetSegment() [6/6]

TGeoNode * MdcROOTGeo::GetSegment ( int segment,
int no )

Get segment node;.

◆ GetSegmentNb() [1/6]

int MdcROOTGeo::GetSegmentNb ( )

Get number of segments;.

◆ GetSegmentNb() [2/6]

int MdcROOTGeo::GetSegmentNb ( )
inline

Get number of segments;.

Definition at line 92 of file EventDisplay/BesVisLib/include/BesVisLib/MdcROOTGeo.h.

92{ return m_kSegment; }

◆ GetSegmentNb() [3/6]

int MdcROOTGeo::GetSegmentNb ( )
inline

Get number of segments;.

Definition at line 92 of file InstallArea/x86_64-el9-gcc13-dbg/include/BesVisLib/MdcROOTGeo.h.

92{ return m_kSegment; }

◆ GetSegmentNb() [4/6]

int MdcROOTGeo::GetSegmentNb ( )

Get number of segments;.

◆ GetSegmentNb() [5/6]

int MdcROOTGeo::GetSegmentNb ( )
inline

Get number of segments;.

Definition at line 92 of file InstallArea/x86_64-el9-gcc13-opt/include/BesVisLib/MdcROOTGeo.h.

92{ return m_kSegment; }

◆ GetSegmentNb() [6/6]

int MdcROOTGeo::GetSegmentNb ( )

Get number of segments;.

◆ GetSimuLayer() [1/3]

Int_t MdcROOTGeo::GetSimuLayer ( Int_t trueLayer)

Trans trueLayer to simuLayer (0~42)->(0~49).

Definition at line 1083 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1083 {
1084 if ( trueLayer < 36 || trueLayer >= m_kTrueLayer ) return trueLayer;
1085 if ( trueLayer >= 36 ) return ( 36 + 2 * ( trueLayer - 36 ) );
1086 return trueLayer;
1087}

Referenced by Draw(), Init2DGeometry(), and SetHits().

◆ GetSimuLayer() [2/3]

Int_t MdcROOTGeo::GetSimuLayer ( Int_t trueLayer)

Trans trueLayer to simuLayer (0~42)->(0~49).

◆ GetSimuLayer() [3/3]

Int_t MdcROOTGeo::GetSimuLayer ( Int_t trueLayer)

Trans trueLayer to simuLayer (0~42)->(0~49).

◆ GetVolumeLayer() [1/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

Definition at line 291 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

291 {
292 std::stringstream osname;
293 if ( layer >= 0 && layer < m_kStereoLayerIn )
294 {
295 osname << "logical"
296 << "Mdc"
297 << "Stereo"
298 << "Layer" << layer;
299 }
300 else if ( layer >= m_kStereoLayerIn && layer < m_kStereoLayerIn + m_kAxialLayerIn )
301 {
302 osname << "logical"
303 << "Mdc"
304 << "Axial"
305 << "Layer" << layer;
306 }
307 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
308 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
309 {
310 osname << "logical"
311 << "Mdc"
312 << "Stereo"
313 << "Layer" << layer;
314 }
315 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut &&
316 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut )
317 {
318 osname << "logical"
319 << "Mdc"
320 << "Axial"
321 << "Layer" << layer << "_0";
322 }
323 else if ( layer >=
324 m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut &&
325 layer < m_kLayer )
326 {
327 osname << "logical"
328 << "Mdc"
329 << "Axial"
330 << "Layer" << layer - m_kAxialLayerOut << "_1";
331 }
332
333 return GetLogicalVolume( osname.str() );
334}
TGeoVolume * GetLogicalVolume(const std::string &vn)
Get a logical volume by name;.

Referenced by SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetVolumeLayer() [2/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

◆ GetVolumeLayer() [3/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

◆ GetVolumeLayer() [4/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

◆ GetVolumeLayer() [5/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

◆ GetVolumeLayer() [6/6]

TGeoVolume * MdcROOTGeo::GetVolumeLayer ( int layer)

Get layer volume;.

◆ GetVolumeMdc() [1/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 68 of file DetectorDescription/ROOTGeo/include/ROOTGeo/MdcROOTGeo.h.

68{ return m_Mdc; }

Referenced by Init2DGeometry().

◆ GetVolumeMdc() [2/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 104 of file EventDisplay/BesVisLib/include/BesVisLib/MdcROOTGeo.h.

104{ return m_Mdc; }

◆ GetVolumeMdc() [3/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 104 of file InstallArea/x86_64-el9-gcc13-dbg/include/BesVisLib/MdcROOTGeo.h.

104{ return m_Mdc; }

◆ GetVolumeMdc() [4/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 68 of file InstallArea/x86_64-el9-gcc13-dbg/include/ROOTGeo/MdcROOTGeo.h.

68{ return m_Mdc; }

◆ GetVolumeMdc() [5/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 104 of file InstallArea/x86_64-el9-gcc13-opt/include/BesVisLib/MdcROOTGeo.h.

104{ return m_Mdc; }

◆ GetVolumeMdc() [6/6]

TGeoVolume * MdcROOTGeo::GetVolumeMdc ( )
inline

Get Mdc volume;.

Definition at line 68 of file InstallArea/x86_64-el9-gcc13-opt/include/ROOTGeo/MdcROOTGeo.h.

68{ return m_Mdc; }

◆ GetVolumeReplica() [1/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

Definition at line 336 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

336 {
337 std::stringstream osname;
338 if ( layer >= 0 && layer < m_kStereoLayerIn )
339 {
340 osname << "logical"
341 << "Mdc"
342 << "Stereo"
343 << "Layer" << layer << "TwistedTubs";
344 }
345 else if ( layer >= m_kStereoLayerIn && layer < m_kStereoLayerIn + m_kAxialLayerIn )
346 {
347 osname << "logical"
348 << "Mdc"
349 << "Axial"
350 << "Layer" << layer << "Replica";
351 }
352 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
353 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
354 {
355 osname << "logical"
356 << "Mdc"
357 << "Stereo"
358 << "Layer" << layer << "TwistedTubs";
359 }
360 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut &&
361 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut )
362 {
363 osname << "logical"
364 << "Mdc"
365 << "Axial"
366 << "Layer" << layer << "_0"
367 << "Replica";
368 }
369 else if ( layer >=
370 m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut &&
371 layer < m_kLayer )
372 {
373 osname << "logical"
374 << "Mdc"
375 << "Axial"
376 << "Layer" << layer - m_kAxialLayerOut << "_1"
377 << "Replica";
378 }
379
380 return GetLogicalVolume( osname.str() );
381}

Referenced by SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetVolumeReplica() [2/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

◆ GetVolumeReplica() [3/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

◆ GetVolumeReplica() [4/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

◆ GetVolumeReplica() [5/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

◆ GetVolumeReplica() [6/6]

TGeoVolume * MdcROOTGeo::GetVolumeReplica ( int layer)

Get replica volume;.

◆ GetVolumeSegment() [1/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

Definition at line 283 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

283 {
284 std::stringstream osname;
285 osname << "logical"
286 << "Mdc"
287 << "Segment" << segment;
288 return GetLogicalVolume( osname.str() );
289}

Referenced by SetAllVisible(), SetDefaultVis(), SetHalfVisible(), SetQuarterVisible(), and SetVolumeDefaultVis().

◆ GetVolumeSegment() [2/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

◆ GetVolumeSegment() [3/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

◆ GetVolumeSegment() [4/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

◆ GetVolumeSegment() [5/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

◆ GetVolumeSegment() [6/6]

TGeoVolume * MdcROOTGeo::GetVolumeSegment ( int segment)

Get segment volume;.

◆ Init2DGeometry() [1/3]

void MdcROOTGeo::Init2DGeometry ( )

Initialize 2D Geometry.

Definition at line 112 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

112 {
113 if ( m_ROOTGeoInit != 1 && m_ROOTGeoInit != 2 )
114 {
115 cout << "MdcROOTGeo::Init2DGeometry, ROOT Geometry not Initialized yet!" << endl;
116 return;
117 }
118
119 m_2DGeoInit = 1;
120 Int_t mdcColor = 11; // 1002; // 41, 29
121 Int_t mdcLineColor = 15;
122 Int_t mdcXYStyle = 1001; // 3001;
123 Int_t mdcZRStyle = 1001; // 3007;
124 Int_t mdcStereoSuperColor = 38;
125 Int_t mdcAxialSuperColor = 4;
126
127 Double_t local[3] = { 0.0, 0.0, 0.0 };
128 Double_t master[3] = { 0.0, 0.0, 0.0 };
129 // Int_t nPoints = 4;
130 Double_t P[306] = { 0.0 }; // Long Peixun's update: 300 -> 306, at most 102 points
131 Double_t center[3] = { 0.0, 0.0, 0.0 };
132 TString name;
133
134 //----------XY-----------
135 // Mdc
136 TGeoTube* mdcShape = (TGeoTube*)GetVolumeMdc()->GetShape();
137 // Long Peixun's update: Consider CGEM detector
138 Double_t rmin = mdcShape->GetRmin();
139 if ( m_StartLayer > 0 ) // if contains CGEM
140 {
141 TGeoTube* mdcShapeOuter = (TGeoTube*)( GetLayer( m_StartLayer )->GetVolume() )->GetShape();
142 rmin = mdcShapeOuter->GetRmin();
143 }
144
145 m_MdcXY = new BesCircle2D( "Mdc", "Mdc", rmin, mdcShape->GetRmax(), &center[0] );
146 m_MdcXY->SetNSegment( 360 );
147 m_MdcXY->SetFillColor( mdcColor );
148 m_MdcXY->SetFillStyle( mdcXYStyle );
149 m_MdcXY->SetLineColor( mdcLineColor );
150
151 // Long Peixun's update: Annotate
152 /* // Mdc Supers
153 Int_t layerIn[4] = {0,
154 m_kStereoLayerIn,
155 m_kStereoLayerIn+m_kAxialLayerIn,
156 m_kStereoLayerIn+m_kAxialLayerIn+m_kStereoLayerOut
157 };
158 Int_t layerOut[4] = {m_kStereoLayerIn-1,
159 m_kStereoLayerIn+m_kAxialLayerIn-1,
160 m_kStereoLayerIn+m_kAxialLayerIn+m_kStereoLayerOut-1,
161 m_kLayer-1
162 };
163 for (Int_t i = 0; i < 4; i++) {
164 TGeoTube *mdcSuperShapeIn =
165 (TGeoTube*)(GetLayer(layerIn[i])->GetVolume())->GetShape(); TGeoTube *mdcSuperShapeOut =
166 (TGeoTube*)(GetLayer(layerOut[i])->GetVolume())->GetShape(); name = TString("MdcSuper" +
167 i); m_MdcXYSuper[i] = new BesCircle2D(name, name, mdcSuperShapeIn->GetRmin(),
168 mdcSuperShapeOut->GetRmax(), &center[0]); if (i%2 == 0)
169 m_MdcXYSuper[i]->SetFillColor(mdcStereoSuperColor); else
170 m_MdcXYSuper[i]->SetFillColor(mdcAxialSuperColor);
171 } */
172
173 // Mdc Wires
174 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
175 for ( Int_t layer = m_StartLayer; layer < m_kTrueLayer; layer++ )
176 {
177 Int_t simuLayer = GetSimuLayer( layer );
178 for ( int replica = 0; replica < m_kReplica[simuLayer]; replica++ )
179 {
180 // cout << "layer " << layer << " replica " << replica << endl;
181 TGeoPhysicalNode* wirePhyNode = GetPhysicalReplica( simuLayer, replica );
182 name = TString( "Mdc Layer " );
183 name += layer;
184 name += " Wire ";
185 name += replica;
186
187 if ( m_kStereoDir[layer] != 0 )
188 { // stereo Layer
189 TGeoArb8* wireShape = (TGeoArb8*)wirePhyNode->GetShape();
190 Double_t *localArb8Point, masterArb8Point[24];
191 localArb8Point = wireShape->GetVertices();
192 for ( Int_t i = 0; i < 8; i++ )
193 {
194 local[0] = localArb8Point[2 * i];
195 local[1] = localArb8Point[2 * i + 1];
196 if ( i < 4 ) local[2] = wireShape->GetDz() * ( -1.0 );
197 else local[2] = wireShape->GetDz();
198
199 wirePhyNode->GetMatrix( -1 * wirePhyNode->GetLevel() )
200 ->LocalToMaster( local, &master[0] ); // transform to top
201 for ( Int_t j = 0; j < 3; j++ ) { masterArb8Point[3 * i + j] = master[j]; }
202 }
203
204 m_Mdc2DWire[layer][replica] = new Mdc2DWire( name, name, 8, &masterArb8Point[0] );
205 }
206 else
207 { // axial Layer
208
209 TGeoTubeSeg* wireShape = (TGeoTubeSeg*)wirePhyNode->GetShape();
210
211 Double_t centerR = 0.5 * ( wireShape->GetRmin() + wireShape->GetRmax() );
212 if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
213 centerR = wireShape->GetRmax();
214 Double_t centerPhi =
215 0.5 * ( wireShape->GetPhi1() + wireShape->GetPhi2() ) * TMath::DegToRad();
216 local[0] = centerR * cos( centerPhi );
217 local[1] = centerR * sin( centerPhi );
218 local[2] = 0.0;
219 wirePhyNode->GetMatrix( -1 * wirePhyNode->GetLevel() )
220 ->LocalToMaster( local, &master[0] ); // transform to top
221
222 Double_t rmin = wireShape->GetRmin();
223 Double_t rmax = wireShape->GetRmax();
224 if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
225 rmax = rmin + 2 * ( rmax - rmin );
226 m_Mdc2DWire[layer][replica] =
227 new Mdc2DWire( name, name, rmin, rmax, wireShape->GetDz(), centerPhi, &master[0] );
228 }
229 }
230 }
231
232 //----------ZR-----------
233 // Mdc
234 Int_t iPoint = 0;
235 TGeoTube* aMdcLayer = 0;
236
237 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
238 for ( Int_t layer = m_StartLayer; layer < m_kLayer; layer++ )
239 {
240 aMdcLayer = (TGeoTube*)GetLayer( layer )->GetVolume()->GetShape();
241 P[3 * iPoint] = 0.0;
242 P[3 * iPoint + 1] = aMdcLayer->GetRmin();
243 P[3 * iPoint + 2] = aMdcLayer->GetDz();
244 iPoint++;
245 }
246
247 P[3 * iPoint] = 0.0;
248 P[3 * iPoint + 1] = aMdcLayer->GetRmax();
249 P[3 * iPoint + 2] = aMdcLayer->GetDz();
250 iPoint++;
251 P[3 * iPoint] = 0.0;
252 P[3 * iPoint + 1] = aMdcLayer->GetRmax();
253 P[3 * iPoint + 2] = aMdcLayer->GetDz() * ( -1.0 );
254 iPoint++;
255
256 for ( Int_t layer = m_kLayer - 1; layer >= m_StartLayer; layer-- )
257 {
258 aMdcLayer = (TGeoTube*)GetLayer( layer )->GetVolume()->GetShape();
259 P[3 * iPoint] = 0.0;
260 P[3 * iPoint + 1] = aMdcLayer->GetRmin();
261 P[3 * iPoint + 2] = aMdcLayer->GetDz() * ( -1.0 );
262 iPoint++;
263 }
264
265 m_MdcZR[0] = new BesPolygon2D( "MdcZRUp", "MdcZRUp", iPoint, &P[0] );
266
267 for ( Int_t i = 0; i < iPoint; i++ ) P[3 * i + 1] *= -1.0;
268
269 m_MdcZR[1] = new BesPolygon2D( "MdcZRDown", "MdcZRDown", iPoint, &P[0] );
270
271 for ( Int_t i = 0; i < 2; i++ )
272 {
273 m_MdcZR[i]->SetFillColor( mdcColor );
274 m_MdcZR[i]->SetFillStyle( mdcZRStyle );
275 m_MdcZR[i]->SetLineColor( mdcLineColor );
276 m_MdcZR[i]->SetRotatable( true ); // Long Peixun's update
277 }
278}
double P(RecMdcKalTrack *trk)
TGeoNode * GetLayer(int layer)
Get layer node;.
TGeoPhysicalNode * GetPhysicalReplica(int layer, int replica)
Get replica physical node;.

◆ Init2DGeometry() [2/3]

void MdcROOTGeo::Init2DGeometry ( )

Initialize 2D Geometry.

◆ Init2DGeometry() [3/3]

void MdcROOTGeo::Init2DGeometry ( )

Initialize 2D Geometry.

◆ InitFromGDML() [1/3]

void MdcROOTGeo::InitFromGDML ( const char * gdmlFile,
const char * setupName )

Initialize ROOTGeo from GDML.

Definition at line 100 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

100 {
101 m_ROOTGeoInit = 2;
102 ReadGdml( gdmlFile, setupName );
103 SetNode();
104}
void SetNode()
Set the pointers to theirs nodes;.
void ReadGdml(const char *gdmlFile, const char *setupName)
Initialize the instance of ROOTGeo.

◆ InitFromGDML() [2/3]

void MdcROOTGeo::InitFromGDML ( const char * gdmlFile,
const char * setupName )

Initialize ROOTGeo from GDML.

◆ InitFromGDML() [3/3]

void MdcROOTGeo::InitFromGDML ( const char * gdmlFile,
const char * setupName )

Initialize ROOTGeo from GDML.

◆ InitFromGdml() [1/3]

void MdcROOTGeo::InitFromGdml ( const char * gdmlFile,
const char * setupName )

Initialize the instance of ROOTGeo.

Definition at line 52 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

52 {
53 ReadGdml( gdmlFile, setupName );
54 SetNode();
56
57 m_ROOTGeoInit = 1;
58}
void SetDefaultVis()
Set default visual attributes;.

◆ InitFromGdml() [2/3]

void MdcROOTGeo::InitFromGdml ( const char * gdmlFile,
const char * setupName )

Initialize the instance of ROOTGeo.

◆ InitFromGdml() [3/3]

void MdcROOTGeo::InitFromGdml ( const char * gdmlFile,
const char * setupName )

Initialize the instance of ROOTGeo.

◆ InitFromROOT() [1/3]

void MdcROOTGeo::InitFromROOT ( TGeoVolume * vol)

Initialize ROOTGeo from TGeoVolume logicalMdc.

Definition at line 106 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

106 {
107 m_ROOTGeoInit = 1;
108 SetVolumeMdc( vol );
109 SetNode();
110}
void SetVolumeMdc(TGeoVolume *vol)
Set Mdc volume, while initializing from ROOT;.

◆ InitFromROOT() [2/3]

void MdcROOTGeo::InitFromROOT ( TGeoVolume * vol)

Initialize ROOTGeo from TGeoVolume logicalMdc.

◆ InitFromROOT() [3/3]

void MdcROOTGeo::InitFromROOT ( TGeoVolume * vol)

Initialize ROOTGeo from TGeoVolume logicalMdc.

◆ IsHit() [1/3]

Bool_t MdcROOTGeo::IsHit ( Int_t layer,
Int_t wire )

Judge whether the digiCol contains (layer, wire).

Definition at line 1089 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

1089 {
1090 if ( m_MdcDigiCol )
1091 {
1092 for ( int i = 0; i < m_MdcDigiCol->GetEntries(); i++ )
1093 {
1094 Identifier mdcID( ( (TMdcDigi*)m_MdcDigiCol->At( i ) )->getIntId() );
1095 if ( layer == MdcID::layer( mdcID ) && wire == MdcID::wire( mdcID ) ) { return kTRUE; }
1096 }
1097 }
1098
1099 return kFALSE;
1100}
static int layer(const Identifier &id)
Values of different levels (failure returns 0).
Definition MdcID.cxx:47
static int wire(const Identifier &id)
Definition MdcID.cxx:52

◆ IsHit() [2/3]

Bool_t MdcROOTGeo::IsHit ( Int_t layer,
Int_t wire )

Judge whether the digiCol contains (layer, wire).

◆ IsHit() [3/3]

Bool_t MdcROOTGeo::IsHit ( Int_t layer,
Int_t wire )

Judge whether the digiCol contains (layer, wire).

◆ SetAllVisible() [1/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

Definition at line 200 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

200 {
201 for ( int segment = 1; segment <= m_kSegment; segment++ )
202 { GetVolumeSegment( segment )->SetVisibility( 0 ); }
203
204 for ( int layer = 0; layer < m_kLayer; layer++ )
205 {
206 GetVolumeLayer( layer )->SetVisibility( 1 );
207 GetVolumeReplica( layer )->SetVisibility( 0 );
208 }
209
210 for ( int segment = 1; segment <= m_kSegment; segment++ )
211 {
212 for ( int no = 0; no < 2; no++ ) { GetSegment( segment, no )->SetVisibility( 1 ); }
213 }
214
215 for ( int layer = 0; layer < m_kLayer; layer++ )
216 {
217 GetLayer( layer )->SetVisibility( 1 );
218 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
219 { GetReplica( layer, replica )->SetVisibility( 0 ); }
220 }
221}
TGeoNode * GetSegment(int segment, int no)
Get segment node;.
TGeoVolume * GetVolumeLayer(int layer)
Get layer volume;.
TGeoNode * GetReplica(int layer, int replica)
Get replica node;.
TGeoVolume * GetVolumeReplica(int layer)
Get replica volume;.
TGeoVolume * GetVolumeSegment(int segment)
Get segment volume;.

◆ SetAllVisible() [2/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

◆ SetAllVisible() [3/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

◆ SetAllVisible() [4/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

◆ SetAllVisible() [5/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

◆ SetAllVisible() [6/6]

void MdcROOTGeo::SetAllVisible ( )

Set all visible;.

◆ SetColorfulWire() [1/3]

void MdcROOTGeo::SetColorfulWire ( Bool_t input)

Definition at line 844 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

844{ k_ColorfulWire = input; }

◆ SetColorfulWire() [2/3]

void MdcROOTGeo::SetColorfulWire ( Bool_t input)

◆ SetColorfulWire() [3/3]

void MdcROOTGeo::SetColorfulWire ( Bool_t input)

◆ SetDefaultVis() [1/3]

void MdcROOTGeo::SetDefaultVis ( )

Set default visual attributes;.

Definition at line 149 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

149 {
150 // std::cout << "begin of set defaultvis" << std::endl;
151 int mdcColor = 3;
152 int segmentColor = 0;
153 int hypeColor = 3;
154 int tubeColor = 4;
155 int twistedTubsColor = 3;
156 int replicaColor = 4;
157
158 m_Mdc->SetLineColor( mdcColor );
159 m_Mdc->SetVisibility( 0 );
160
161 for ( int segment = 1; segment <= m_kSegment; segment++ )
162 {
163 GetVolumeSegment( segment )->SetLineColor( segmentColor );
164 GetVolumeSegment( segment )->SetVisibility( 0 );
165 }
166
167 for ( int layer = 0; layer < m_kLayer; layer++ )
168 {
169 if ( ( layer >= 0 && layer < m_kStereoLayerIn ) ||
170 ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
171 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut ) )
172 {
173 GetVolumeLayer( layer )->SetLineColor( hypeColor );
174 GetVolumeReplica( layer )->SetLineColor( twistedTubsColor );
175 }
176 else
177 {
178 GetVolumeLayer( layer )->SetLineColor( tubeColor );
179 GetVolumeReplica( layer )->SetLineColor( replicaColor );
180 }
181 GetVolumeLayer( layer )->SetVisibility( 0 );
182 GetVolumeReplica( layer )->SetVisibility( 1 );
183 }
184
185 for ( int segment = 1; segment <= m_kSegment; segment++ )
186 {
187 for ( int no = 0; no < 2; no++ ) { GetSegment( segment, no )->SetVisibility( 0 ); }
188 }
189
190 for ( int layer = 0; layer < m_kLayer; layer++ )
191 {
192 GetLayer( layer )->SetVisibility( 0 );
193 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
194 { GetReplica( layer, replica )->SetVisibility( 0 ); }
195 }
196
197 // std::cout << "end of set defaultvis" << std::endl;
198}

Referenced by InitFromGdml().

◆ SetDefaultVis() [2/3]

void MdcROOTGeo::SetDefaultVis ( )

Set default visual attributes;.

◆ SetDefaultVis() [3/3]

void MdcROOTGeo::SetDefaultVis ( )

Set default visual attributes;.

◆ SetDetector() [1/3]

void MdcROOTGeo::SetDetector ( )

Draw Detecor (what is detector depends on you).

Definition at line 655 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

655 {
656 BesView* view = 0;
657 if ( gPad ) view = dynamic_cast<BesView*>( gPad->GetView() );
658 // if (view) cout << "viewVisFull3DMdc " << view->GetVisFull3DMdc() << endl;
659
660 m_DetectorsArray->Clear();
661 for ( int segment = 0; segment < 2 * m_kSegment - 2; segment++ )
662 {
663 TGeoPhysicalNode* phyNode = 0;
664 phyNode = m_PhysicalSegment[segment];
665 // cout << m_PhysicalSegment[segment]->GetName() << endl;
666 if ( phyNode )
667 {
668 phyNode->SetVisibility( 0 ); // set all invisible before set any visible
669 if ( ( segment >= 2 && segment <= 3 ) || segment > 59 )
670 { m_DetectorsArray->Add( phyNode ); }
671 else if ( view && view->GetVisFull3DMdc() ) { m_DetectorsArray->Add( phyNode ); }
672 }
673 }
674 /*
675 for (int part = 0; part < m_kPart; part++) {
676 int nPhi = (part == 1 ? m_kPhiBr : m_kPhiEc);
677 for (int phi = 0; phi < nPhi; phi++) {
678 int nTheta = (part == 1 ? m_kThetaBr : m_kThetaEc);
679 for (int theta = 0; theta < nTheta; theta++) {
680 // This is you detector, set it on
681 if ( (part == 1 && theta != 0 && theta != 43 && ((phi != 0 && phi != 60) || theta%2 == 0))
682 || (part != 1 && theta != 0) ) { m_PhysicalCrystal[part][phi][theta]->SetVisibility(0);
683 }
684
685 // This is you hit
686 // when you are to set fired hits to another color, say red,
687 // SetIsVolAtt(kFALSE) and to then SetLineColor(kRed);
688 if (phi == 12 && theta == 5) {
689 m_PhysicalCrystal[part][phi][theta]->SetVisibility(1);
690 m_PhysicalCrystal[part][phi][theta]->SetLineColor(2);
691 }
692 }
693 }
694 }
695 std::cout << "end of set detector on" << std::endl;
696 */
697}

◆ SetDetector() [2/3]

void MdcROOTGeo::SetDetector ( )

Draw Detecor (what is detector depends on you).

◆ SetDetector() [3/3]

void MdcROOTGeo::SetDetector ( )

Draw Detecor (what is detector depends on you).

◆ SetHalfVisible() [1/3]

void MdcROOTGeo::SetHalfVisible ( )

Set half visible;.

Definition at line 543 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

543 {
544 for ( int segment = 1; segment <= m_kSegment; segment++ )
545 { GetVolumeSegment( segment )->SetVisibility( 0 ); }
546
547 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
548 for ( int layer = m_StartLayer; layer < m_kLayer; layer++ )
549 {
550 GetVolumeLayer( layer )->SetVisibility( 0 );
551 GetVolumeReplica( layer )->SetVisibility( 1 );
552 }
553
554 for ( int segment = 1; segment <= m_kSegment; segment++ )
555 {
556 for ( int no = 0; no < 2; no++ ) { GetSegment( segment, no )->SetVisibility( 0 ); }
557 }
558
559 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
560 for ( int layer = m_StartLayer; layer < m_kLayer; layer++ )
561 {
562 GetLayer( layer )->SetVisibility( 0 );
563 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
564 {
565 if ( replica < m_kReplica[layer] / 4 || replica > m_kReplica[layer] * 3 / 4 )
566 GetReplica( layer, replica )->SetVisibility( 1 );
567 else GetReplica( layer, replica )->SetVisibility( 0 );
568 }
569 }
570}

◆ SetHalfVisible() [2/3]

void MdcROOTGeo::SetHalfVisible ( )

Set half visible;.

◆ SetHalfVisible() [3/3]

void MdcROOTGeo::SetHalfVisible ( )

Set half visible;.

◆ SetHits() [1/3]

void MdcROOTGeo::SetHits ( )

Set all physicalNodes corresponding to digiCol;.

Definition at line 699 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

699 {
700 // set previous event hits to default vis
701 // Long Peixun's update: Annotate cout
702 // cout << "m_HitsArray size(): " << m_HitsArray->GetEntries() << endl;
703 // cout << "m_2DHitsArray size(): " << m_2DHitsArray->GetEntries() << endl;
704 for ( int i = 0; i < m_HitsArray->GetEntries(); i++ )
705 {
706 TGeoPhysicalNode* phyNode = (TGeoPhysicalNode*)m_HitsArray->At( i );
707 phyNode->SetVisibility( 0 );
708 }
709 m_HitsArray->Clear( "C" );
710
711 // set previous event 2D hits info to default
712 for ( int i = 0; i < m_2DHitsArray->GetEntries(); i++ )
713 {
714 Mdc2DWire* aWire = (Mdc2DWire*)m_2DHitsArray->At( i );
715 aWire->ClearInfo();
716 aWire->AddInfo( aWire->GetTitle() );
717 aWire->CloseInfo();
718 }
719 m_2DHitsArray->Clear( "C" );
720
721 // set new hits
722 // Long Peixun's update: Consider gEvent == NULL
723 int NDigiCol = 0;
724 if ( gEvent )
725 {
726 m_MdcDigiCol = gEvent->GetMdcDigiCol();
727 // Long Peixun's update: Consider m_MdcDigiCol == NULL
728 if ( m_MdcDigiCol ) NDigiCol = m_MdcDigiCol->GetEntries();
729 else NDigiCol = 0;
730 }
731
732 for ( int i = 0; i < NDigiCol; i++ )
733 {
734 TMdcDigi* aMdcDigi = (TMdcDigi*)m_MdcDigiCol->At( i );
735 Identifier aMdcID( aMdcDigi->getIntId() );
736 int layer = MdcID::layer( aMdcID );
737 int wire = MdcID::wire( aMdcID );
738
739 Double_t time = RawDataUtil::MdcTime( aMdcDigi->getTimeChannel() );
740 Int_t charge = RawDataUtil::MdcCharge( aMdcDigi->getChargeChannel() );
741
742 TGeoPhysicalNode* phyNode = 0;
743 if ( layer < 36 )
744 { // number of layers in the three inner
745 phyNode = GetPhysicalReplica( layer, wire );
746 if ( phyNode ) m_HitsArray->Add( phyNode );
747 }
748 else
749 {
750 phyNode = GetPhysicalReplica( GetSimuLayer( layer ), wire );
751 if ( phyNode ) m_HitsArray->Add( phyNode );
752 phyNode = GetPhysicalReplica( GetSimuLayer( layer ) + 1, wire );
753 if ( phyNode ) m_HitsArray->Add( phyNode );
754 }
755
756 Mdc2DWire* aWire = 0;
757 aWire = m_Mdc2DWire[layer][wire];
758 if ( aWire )
759 {
760 aWire->ClearInfo();
761 aWire->AddInfo( aWire->GetTitle() );
762 double evTime = gEvent->GetHeader().GetEvTime();
763
764 char data[200]; // Long Peixun's update: 100 -> 200
765 if ( time > 1000000 ) { sprintf( data, "NO time" ); }
766 else
767 {
768 sprintf( data, "time=%-.1f ns", time );
769 if ( fabs( evTime ) > 0.0001 )
770 { sprintf( data, "%s, Tdrift(Raw)=%-.1f ns", data, time - evTime + 230 ); }
771 }
772 if ( charge > 1000000 ) { sprintf( data, "%s, NO charge", data ); }
773 else { sprintf( data, "%s, charge=%d", data, charge ); }
774 aWire->AddInfo( TString( data ) );
775 sprintf( data, "Fired" );
776 aWire->AddInfo( TString( data ) );
777
778 aWire->SetTime( time ); // yzhang
779 aWire->SetCharge( charge ); // yzhang
780 unsigned int overflow = aMdcDigi->getOverflow();
781 aWire->SetQOverflow( overflow & 2 ); // yzhang
782 aWire->SetEvTime( evTime );
783
784 // Long Peixun's update: Set raw channel data of aWire
785 aWire->SetTimeChannel( aMdcDigi->getTimeChannel() );
786 aWire->SetChargeChannel( aMdcDigi->getChargeChannel() );
787
788 aWire->CloseInfo();
789
790 m_2DHitsArray->Add( aWire );
791 }
792 }
793}
sprintf(cut, "kal_costheta0_em>-0.93&&kal_costheta0_em<0.93&&kal_pxy0_em>=0.05+%d*0.1&&kal_" "pxy0_em<0.15+%d*0.1&&NGch>=2", j, j)
TTree * data
Double_t time
void SetChargeChannel(UInt_t cc)
virtual void ClearInfo()
void SetQOverflow(Bool_t qOvfl)
virtual void CloseInfo()
void SetTime(Double_t time)
void SetEvTime(Double_t time)
void SetTimeChannel(UInt_t tc)
void SetCharge(Double_t charge)
static double MdcTime(int timeChannel)
static double MdcCharge(int chargeChannel)
UInt_t getOverflow() const
Definition TMdcDigi.cxx:35
UInt_t getIntId() const
Definition TRawData.cxx:42
UInt_t getChargeChannel() const
Definition TRawData.cxx:48
UInt_t getTimeChannel() const
Definition TRawData.cxx:45

◆ SetHits() [2/3]

void MdcROOTGeo::SetHits ( )

Set all physicalNodes corresponding to digiCol;.

◆ SetHits() [3/3]

void MdcROOTGeo::SetHits ( )

Set all physicalNodes corresponding to digiCol;.

◆ SetMdcTimeSubEvTime() [1/3]

void MdcROOTGeo::SetMdcTimeSubEvTime ( Bool_t input)

Definition at line 846 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

846{ k_MdcTimeSubEvTime = input; }

◆ SetMdcTimeSubEvTime() [2/3]

void MdcROOTGeo::SetMdcTimeSubEvTime ( Bool_t input)

◆ SetMdcTimeSubEvTime() [3/3]

void MdcROOTGeo::SetMdcTimeSubEvTime ( Bool_t input)

◆ SetNode() [1/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

Definition at line 60 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

60 {
61 m_Mdc = GetTopVolume();
62 if ( !m_Mdc ) std::cout << "m_Mdc = 0" << std::endl;
63
64 for ( int layer = 0; layer < m_kLayer; layer++ )
65 {
66 // std::cout << "Layer " << layer << std::endl;
67 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
68 {
69 std::stringstream osname;
70 int rep = replica;
71 if ( layer >= 0 && layer < m_kStereoLayerIn )
72 {
73 osname << "pv_"
74 << "logical"
75 << "Mdc"
76 << "Stereo"
77 << "Layer" << layer << "TwistedTubs"
78 << "_" << rep;
79 }
80 else if ( layer >= m_kStereoLayerIn && layer < m_kStereoLayerIn + m_kAxialLayerIn )
81 {
82 rep = CorrectReplica( layer, rep );
83 osname << "pv_"
84 << "logical"
85 << "Mdc"
86 << "Axial"
87 << "Layer" << layer << "Replica"
88 << "_" << rep;
89 }
90 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
91 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut )
92 {
93 osname << "pv_"
94 << "logical"
95 << "Mdc"
96 << "Stereo"
97 << "Layer" << layer << "TwistedTubs"
98 << "_" << rep;
99 }
100 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut &&
101 layer <
102 m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut + m_kAxialLayerOut )
103 {
104 rep = CorrectReplica( layer, rep );
105 osname << "pv_"
106 << "logical"
107 << "Mdc"
108 << "Axial"
109 << "Layer" << layer << "_0"
110 << "Replica"
111 << "_" << rep;
112 }
113 else if ( layer >= m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut +
114 m_kAxialLayerOut &&
115 layer < m_kLayer )
116 {
117 rep = CorrectReplica( layer, rep );
118 osname << "pv_"
119 << "logical"
120 << "Mdc"
121 << "Axial"
122 << "Layer" << layer - m_kAxialLayerOut << "_1"
123 << "Replica"
124 << "_" << rep;
125 }
126
127 m_NodeReplica[layer][replica] = GetNode( osname.str() );
128 }
129 }
130}
int CorrectReplica(int layer, int replica)
Correct some axial layer id to copyNo;.

Referenced by InitFromGDML(), InitFromGdml(), and InitFromROOT().

◆ SetNode() [2/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

◆ SetNode() [3/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

◆ SetNode() [4/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

◆ SetNode() [5/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

◆ SetNode() [6/6]

void MdcROOTGeo::SetNode ( )

Set the pointers to theirs nodes;.

◆ SetPhysicalDefaultVis() [1/3]

void MdcROOTGeo::SetPhysicalDefaultVis ( )

Set default physical node attributes;.

Definition at line 620 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

620 {
621 // for (int part = 0; part < m_kPart; part++)
622 // {
623 // int nPhi = (part == 1 ? m_kPhiBr : m_kPhiEc);
624 // for (int phi = 0; phi < nPhi; phi++)
625 // {
626 // int nTheta = (part == 1 ? m_kThetaBr : m_kThetaEc);
627 // for (int theta = 0; theta < nTheta; theta++)
628 // {
629 // m_PhysicalCrystal[part][phi][theta]->SetIsVolAtt(kFALSE);
630 // if (part == 1)
631 // m_PhysicalCrystal[part][phi][theta]->SetLineColor(m_brCrystalColor); else
632 // m_PhysicalCrystal[part][phi][theta]->SetLineColor(m_ecCrystalColor);
633 // }
634 // }
635 // }
636
637 for ( int layer = m_StartLayer; layer < m_kLayer; layer++ )
638 {
639 if ( ( layer >= 0 && layer < m_kStereoLayerIn ) ||
640 ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
641 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut ) )
642 {
643 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
644 GetPhysicalReplica( layer, replica )->SetLineColor( m_twistedTubsColor );
645 }
646 else
647 {
648 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
649 GetPhysicalReplica( layer, replica )->SetLineColor( m_replicaColor );
650 }
651 }
652 // std::cout << "end of set defaultvis" << std::endl;
653}

◆ SetPhysicalDefaultVis() [2/3]

void MdcROOTGeo::SetPhysicalDefaultVis ( )

Set default physical node attributes;.

◆ SetPhysicalDefaultVis() [3/3]

void MdcROOTGeo::SetPhysicalDefaultVis ( )

Set default physical node attributes;.

◆ SetPhysicalNode() [1/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

Definition at line 249 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

249 {
250 int twistedTubsColor = 3;
251 int replicaColor = 4;
252
253 if ( gGeoManager == 0 ) std::cout << "Create gGeoManager first" << std::endl;
254 TGeoNode* bes = gGeoManager->GetTopNode();
255 // std::cout << "m_childNo " << m_childNo << std::endl;
256 TGeoNode* mdc = bes->GetDaughter( m_childNo );
257
258 // if(!m_Mdc) std::cout << "m_Mdc = 0" << std::endl;
259
260 for ( int layer = 0; layer < m_kLayer; layer++ )
261 {
262 TGeoNode* nodeLayer = GetLayer( layer );
263 // std::cout << "Layer " << layer << std::endl;
264 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
265 {
266 TGeoNode* nodeReplica = GetReplica( layer, replica );
267 m_PhysicalReplica[layer][replica] = gGeoManager->MakePhysicalNode(
268 TString( "/" ) + bes->GetName() + TString( "/" ) + mdc->GetName() + TString( "/" ) +
269 nodeLayer->GetName() + TString( "/" ) + nodeReplica->GetName() );
270 m_PhysicalReplica[layer][replica]->SetVisibility( 0 );
271 m_PhysicalReplica[layer][replica]->SetIsVolAtt( kFALSE );
272 if ( ( layer >= 0 && layer < m_kStereoLayerIn ) ||
273 ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
274 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut ) )
275 { m_PhysicalReplica[layer][replica]->SetLineColor( twistedTubsColor ); }
276 else { m_PhysicalReplica[layer][replica]->SetLineColor( replicaColor ); }
277 // if (m_PhysicalReplica[layer][replica]->IsVolAttributes()) std::cout << "yes " <<
278 // std::endl;
279 }
280 }
281}
std::string mdc

◆ SetPhysicalNode() [2/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

◆ SetPhysicalNode() [3/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

◆ SetPhysicalNode() [4/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

◆ SetPhysicalNode() [5/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

◆ SetPhysicalNode() [6/6]

void MdcROOTGeo::SetPhysicalNode ( )

Set the pointers to the physical nodes;.

◆ SetQFire() [1/3]

void MdcROOTGeo::SetQFire ( Bool_t input)

Definition at line 839 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

839 {
840 k_QFire = input;
841 // cout << "Mdc ROOT Geometry ADC Match: " << k_QMatch << endl;
842}

◆ SetQFire() [2/3]

void MdcROOTGeo::SetQFire ( Bool_t input)

◆ SetQFire() [3/3]

void MdcROOTGeo::SetQFire ( Bool_t input)

◆ SetQNotOverflow() [1/3]

void MdcROOTGeo::SetQNotOverflow ( Bool_t input)

Definition at line 834 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

834 {
835 k_QNotOverflow = input;
836 // cout << "Mdc ROOT Geometry TDC Match: " << k_TMatch << endl;
837}

◆ SetQNotOverflow() [2/3]

void MdcROOTGeo::SetQNotOverflow ( Bool_t input)

◆ SetQNotOverflow() [3/3]

void MdcROOTGeo::SetQNotOverflow ( Bool_t input)

◆ SetQuarterVisible() [1/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

Definition at line 223 of file DetectorDescription/ROOTGeo/src/MdcROOTGeo.cxx.

223 {
224 for ( int segment = 1; segment <= m_kSegment; segment++ )
225 { GetVolumeSegment( segment )->SetVisibility( 0 ); }
226
227 for ( int layer = 0; layer < m_kLayer; layer++ )
228 {
229 GetVolumeLayer( layer )->SetVisibility( 0 );
230 GetVolumeReplica( layer )->SetVisibility( 1 );
231 }
232
233 for ( int segment = 1; segment <= m_kSegment; segment++ )
234 {
235 for ( int no = 0; no < 2; no++ ) { GetSegment( segment, no )->SetVisibility( 0 ); }
236 }
237
238 for ( int layer = 0; layer < m_kLayer; layer++ )
239 {
240 GetLayer( layer )->SetVisibility( 0 );
241 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
242 {
243 if ( replica < m_kReplica[layer] / 4 ) GetReplica( layer, replica )->SetVisibility( 0 );
244 else GetReplica( layer, replica )->SetVisibility( 1 );
245 }
246 }
247}

◆ SetQuarterVisible() [2/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

◆ SetQuarterVisible() [3/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

◆ SetQuarterVisible() [4/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

◆ SetQuarterVisible() [5/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

◆ SetQuarterVisible() [6/6]

void MdcROOTGeo::SetQuarterVisible ( )

Set quater visible;.

◆ SetTFire() [1/3]

void MdcROOTGeo::SetTFire ( Bool_t input)

Definition at line 823 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

823 {
824 k_TFire = input;
825 // cout << "Mdc ROOT Geometry TDC Match: " << k_TMatch << endl;
826}

◆ SetTFire() [2/3]

void MdcROOTGeo::SetTFire ( Bool_t input)

◆ SetTFire() [3/3]

void MdcROOTGeo::SetTFire ( Bool_t input)

◆ SetVisMdcDetector() [1/3]

void MdcROOTGeo::SetVisMdcDetector ( )

Set Mdc default detector visibility;.

Definition at line 795 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

795 {
796 BesView* view = 0;
797 if ( gPad ) view = dynamic_cast<BesView*>( gPad->GetView() );
798
799 for ( int i = 0; i < m_DetectorsArray->GetEntries(); i++ )
800 {
801 TGeoPhysicalNode* phyNode = (TGeoPhysicalNode*)m_DetectorsArray->At( i );
802 if ( view && view->GetVisMdcGlobal() )
803 {
804 phyNode->SetVisibility( 1 );
805 continue;
806 }
807 phyNode->SetVisibility( 0 );
808 }
809}

◆ SetVisMdcDetector() [2/3]

void MdcROOTGeo::SetVisMdcDetector ( )

Set Mdc default detector visibility;.

◆ SetVisMdcDetector() [3/3]

void MdcROOTGeo::SetVisMdcDetector ( )

Set Mdc default detector visibility;.

◆ SetVisMdcHits() [1/3]

void MdcROOTGeo::SetVisMdcHits ( )

Set Mdc hits visibility;.

Definition at line 811 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

811 {
812 BesView* view = 0;
813 if ( gPad ) view = dynamic_cast<BesView*>( gPad->GetView() );
814
815 for ( int i = 0; i < m_HitsArray->GetEntries(); i++ )
816 {
817 TGeoPhysicalNode* phyNode = (TGeoPhysicalNode*)m_HitsArray->At( i );
818 if ( view && view->GetVisMdcHitsGlobal() ) { phyNode->SetVisibility( 1 ); }
819 else { phyNode->SetVisibility( 0 ); }
820 }
821}

◆ SetVisMdcHits() [2/3]

void MdcROOTGeo::SetVisMdcHits ( )

Set Mdc hits visibility;.

◆ SetVisMdcHits() [3/3]

void MdcROOTGeo::SetVisMdcHits ( )

Set Mdc hits visibility;.

◆ SetVolumeDefaultVis() [1/3]

void MdcROOTGeo::SetVolumeDefaultVis ( )

Set default visual attributes;.

Definition at line 423 of file EventDisplay/BesVisLib/src/MdcROOTGeo.cxx.

423 {
424 // std::cout << "begin of set defaultvis" << std::endl;
425 m_Mdc->SetLineColor( m_MdcColor );
426 m_Mdc->SetVisibility( 0 );
427
428 for ( int segment = 1; segment <= m_kSegment; segment++ )
429 {
430 GetVolumeSegment( segment )->SetLineColor( m_segmentColor );
431 // if (segment > 3) GetVolumeSegment(segment)->SetVisibility(0);
432 GetVolumeSegment( segment )->SetVisibility( 1 );
433 }
434
435 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
436 for ( int layer = m_StartLayer; layer < m_kLayer; layer++ )
437 {
438 if ( ( layer >= 0 && layer < m_kStereoLayerIn ) ||
439 ( layer >= m_kStereoLayerIn + m_kAxialLayerIn &&
440 layer < m_kStereoLayerIn + m_kAxialLayerIn + m_kStereoLayerOut ) )
441 {
442 GetVolumeLayer( layer )->SetLineColor( m_hypeColor );
443 GetVolumeReplica( layer )->SetLineColor( m_twistedTubsColor );
444 }
445 else
446 {
447 GetVolumeLayer( layer )->SetLineColor( m_tubeColor );
448 GetVolumeReplica( layer )->SetLineColor( m_replicaColor );
449 }
450 GetVolumeLayer( layer )->SetVisibility( 0 );
451 GetVolumeReplica( layer )->SetVisibility( 1 );
452 }
453
454 for ( int segment = 1; segment <= m_kSegment; segment++ )
455 {
456 for ( int no = 0; no < 2; no++ ) { GetSegment( segment, no )->SetVisibility( 0 ); }
457 }
458
459 // Long Peixun's update: Ignore layer 0~7 if detector contains CGEM
460 for ( int layer = m_StartLayer; layer < m_kLayer; layer++ )
461 {
462 GetLayer( layer )->SetVisibility( 0 );
463 for ( int replica = 0; replica < m_kReplica[layer]; replica++ )
464 { GetReplica( layer, replica )->SetVisibility( 0 ); }
465 }
466
467 // std::cout << "end of set defaultvis" << std::endl;
468}

◆ SetVolumeDefaultVis() [2/3]

void MdcROOTGeo::SetVolumeDefaultVis ( )

Set default visual attributes;.

◆ SetVolumeDefaultVis() [3/3]

void MdcROOTGeo::SetVolumeDefaultVis ( )

Set default visual attributes;.

◆ SetVolumeMdc() [1/3]

void MdcROOTGeo::SetVolumeMdc ( TGeoVolume * vol)
inline

Set Mdc volume, while initializing from ROOT;.

Definition at line 101 of file EventDisplay/BesVisLib/include/BesVisLib/MdcROOTGeo.h.

101{ m_Mdc = vol; }

Referenced by InitFromROOT().

◆ SetVolumeMdc() [2/3]

void MdcROOTGeo::SetVolumeMdc ( TGeoVolume * vol)
inline

Set Mdc volume, while initializing from ROOT;.

Definition at line 101 of file InstallArea/x86_64-el9-gcc13-dbg/include/BesVisLib/MdcROOTGeo.h.

101{ m_Mdc = vol; }

◆ SetVolumeMdc() [3/3]

void MdcROOTGeo::SetVolumeMdc ( TGeoVolume * vol)
inline

Set Mdc volume, while initializing from ROOT;.

Definition at line 101 of file InstallArea/x86_64-el9-gcc13-opt/include/BesVisLib/MdcROOTGeo.h.

101{ m_Mdc = vol; }

The documentation for this class was generated from the following files: