CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
FW3DViewGeometry Class Reference

#include <Fireworks/Core/interface/FW3DViewGeometry.h>

Inheritance diagram for FW3DViewGeometry:
FWViewGeometryList

Public Member Functions

 FW3DViewGeometry (const fireworks::Context &context)
 
TEveElementList const *const getHGCalEE ()
 
TEveElementList const *const getHGCalHSc ()
 
TEveElementList const *const getHGCalHSi ()
 
void showHGCalEE (bool)
 
void showHGCalHSc (bool)
 
void showHGCalHSi (bool)
 
void showMuonBarrel (bool)
 
void showMuonBarrelFull (bool)
 
void showMuonEndcap (bool)
 
void showPixelBarrel (bool)
 
void showPixelEndcap (bool)
 
void showTrackerBarrel (bool)
 
void showTrackerEndcap (bool)
 
 ~FW3DViewGeometry () override
 
- Public Member Functions inherited from FWViewGeometryList
 FWViewGeometryList (const fireworks::Context &context, bool projected=true)
 
void updateColors ()
 
void updateTransparency (bool projectedType)
 
 ~FWViewGeometryList () override
 

Private Member Functions

 FW3DViewGeometry (const FW3DViewGeometry &)=delete
 
const FW3DViewGeometryoperator= (const FW3DViewGeometry &)=delete
 

Private Attributes

TEveElementList * m_HGCalEEElements
 
TEveElementList * m_HGCalHScElements
 
TEveElementList * m_HGCalHSiElements
 
TEveElementList * m_muonBarrelElements
 
TEveElementList * m_muonBarrelFullElements
 
TEveElementList * m_muonEndcapElements
 
TEveElementList * m_muonEndcapFullElements
 
TEveElementList * m_pixelBarrelElements
 
TEveElementList * m_pixelEndcapElements
 
TEveElementList * m_trackerBarrelElements
 
TEveElementList * m_trackerEndcapElements
 

Additional Inherited Members

- Protected Member Functions inherited from FWViewGeometryList
void addToCompound (TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
 
- Protected Attributes inherited from FWViewGeometryList
TEveCompound * m_colorComp [kFWGeomColorSize]
 
const fireworks::Contextm_context
 
const FWGeometrym_geom
 

Detailed Description

Description: [one line class summary]

Usage: <usage>

Definition at line 30 of file FW3DViewGeometry.h.

Constructor & Destructor Documentation

FW3DViewGeometry::FW3DViewGeometry ( const fireworks::Context context)

Definition at line 44 of file FW3DViewGeometry.cc.

44  :
45  FWViewGeometryList(context, false),
48  m_pixelBarrelElements(nullptr),
49  m_pixelEndcapElements(nullptr),
50  m_trackerBarrelElements(nullptr),
51  m_trackerEndcapElements(nullptr),
52  m_HGCalEEElements(nullptr), m_HGCalHSiElements(nullptr), m_HGCalHScElements(nullptr)
53 {
54 
55  SetElementName("3D Geometry");
56 }
TEveElementList * m_pixelBarrelElements
TEveElementList * m_HGCalEEElements
FWViewGeometryList(const fireworks::Context &context, bool projected=true)
TEveElementList * m_HGCalHSiElements
TEveElementList * m_HGCalHScElements
TEveElementList * m_pixelEndcapElements
TEveElementList * m_muonEndcapFullElements
TEveElementList * m_muonEndcapElements
TEveElementList * m_muonBarrelElements
TEveElementList * m_trackerEndcapElements
TEveElementList * m_trackerBarrelElements
TEveElementList * m_muonBarrelFullElements
FW3DViewGeometry::~FW3DViewGeometry ( )
override

Definition at line 63 of file FW3DViewGeometry.cc.

64 {
65 }
FW3DViewGeometry::FW3DViewGeometry ( const FW3DViewGeometry )
privatedelete

Member Function Documentation

TEveElementList const* const FW3DViewGeometry::getHGCalEE ( )
inline

Definition at line 51 of file FW3DViewGeometry.h.

Referenced by FW3DViewBase::updateHGCalVisibility().

51 { return m_HGCalEEElements; }
TEveElementList * m_HGCalEEElements
TEveElementList const* const FW3DViewGeometry::getHGCalHSc ( )
inline

Definition at line 55 of file FW3DViewGeometry.h.

Referenced by FW3DViewBase::updateHGCalVisibility().

55 { return m_HGCalHScElements; }
TEveElementList * m_HGCalHScElements
TEveElementList const* const FW3DViewGeometry::getHGCalHSi ( )
inline

Definition at line 53 of file FW3DViewGeometry.h.

Referenced by FW3DViewBase::updateHGCalVisibility().

53 { return m_HGCalHSiElements; }
TEveElementList * m_HGCalHSiElements
const FW3DViewGeometry& FW3DViewGeometry::operator= ( const FW3DViewGeometry )
privatedelete
void FW3DViewGeometry::showHGCalEE ( bool  showHGCalEE)

Definition at line 421 of file FW3DViewGeometry.cc.

References create_public_lumi_plots::color, f, FWGeometry::getHGCSiliconEveShape(), FWGeometry::getMatchedIds(), FWGeometry::HGCalEE, kFwHGCalEEColorIndex, FWViewGeometryList::m_colorComp, FWViewGeometryList::m_geom, m_HGCalEEElements, and mitigatedMETSequence_cff::U.

Referenced by FW3DViewBase::setContext().

421  {
422  if( showHGCalEE && !m_HGCalEEElements ){
423  m_HGCalEEElements = new TEveElementList("HGCalEE");
424  for( const auto& id : m_geom->getMatchedIds( FWGeometry::HGCalEE ))
425  {
426  TEveGeoShape* shape = m_geom->getHGCSiliconEveShape( id );
427  const unsigned int layer = (id>>20)&0x1F;
428  shape->SetTitle(Form("HGCalEE %d", layer));
429  {
430  float color[3];
431  color[0] = color[1] = color[2] = 0.3f + 0.7f*(1.0f-layer/28.0f);
432  color[1] = 0.5f*(layer&2U) + 0.5f*color[1];
433  const bool isFine = ((id>>26)&0x3) == 0;
434  color[0] *= isFine ? 1.0f : 1.0f;
435  color[1] *= isFine ? 1.0f : 0.4f;
436  color[2] *= isFine ? 0.0f : 0.0f;
437  shape->SetMainColorRGB( color[0], color[1], color[2] );
438  shape->SetPickable(false);
439  m_colorComp[kFwHGCalEEColorIndex]->AddElement(shape);
440  }
441  m_HGCalEEElements->AddElement( shape );
442  }
443  AddElement( m_HGCalEEElements );
444  }
445  if (m_HGCalEEElements ){
446  m_HGCalEEElements->SetRnrState( showHGCalEE );
447  gEve->Redraw3D();
448  }
449 }
TEveGeoShape * getHGCSiliconEveShape(unsigned int id) const
Definition: FWGeometry.cc:325
TEveCompound * m_colorComp[kFWGeomColorSize]
TEveElementList * m_HGCalEEElements
double f[11][100]
const FWGeometry * m_geom
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
void FW3DViewGeometry::showHGCalHSc ( bool  showHGCalHSc)

Definition at line 482 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getHGCScintillatorEveShape(), FWGeometry::getMatchedIds(), FWGeometry::HGCalHSc, kFwHGCalHScColorIndex, FWViewGeometryList::m_geom, and m_HGCalHScElements.

Referenced by FW3DViewBase::setContext().

482  {
484  {
485  m_HGCalHScElements = new TEveElementList( "HGCalHSc" );
486  std::vector<unsigned int> ids = m_geom->getMatchedIds( FWGeometry::HGCalHSc );
487  for( const auto& id : m_geom->getMatchedIds( FWGeometry::HGCalHSc ))
488  {
489  TEveGeoShape* shape = m_geom->getHGCScintillatorEveShape( id );
490  const unsigned int layer = (id>>17)&0x1F;
491  shape->SetTitle(Form("HGCalHSc %d", layer));
493  m_HGCalHScElements->AddElement( shape );
494  }
495  AddElement( m_HGCalHScElements );
496  }
497  if( m_HGCalHScElements )
498  {
499  m_HGCalHScElements->SetRnrState( showHGCalHSc );
500  gEve->Redraw3D();
501  }
502 }
TEveElementList * m_HGCalHScElements
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
const FWGeometry * m_geom
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
TEveGeoShape * getHGCScintillatorEveShape(unsigned int id) const
Definition: FWGeometry.cc:391
void FW3DViewGeometry::showHGCalHSi ( bool  showHGCalHSi)

Definition at line 452 of file FW3DViewGeometry.cc.

References create_public_lumi_plots::color, f, FWGeometry::getHGCSiliconEveShape(), FWGeometry::getMatchedIds(), FWGeometry::HGCalHSi, kFwHGCalHSiColorIndex, FWViewGeometryList::m_colorComp, FWViewGeometryList::m_geom, m_HGCalHSiElements, and mitigatedMETSequence_cff::U.

Referenced by FW3DViewBase::setContext().

452  {
454  m_HGCalHSiElements = new TEveElementList("HGCalHSi");
455  for( const auto& id : m_geom->getMatchedIds( FWGeometry::HGCalHSi ))
456  {
457  TEveGeoShape* shape = m_geom->getHGCSiliconEveShape( id );
458  const unsigned int layer = (id>>20)&0x1F;
459  shape->SetTitle(Form("HGCalHSi %d",layer));
460  {
461  float color[3];
462  color[0] = color[1] = color[2] = 0.3f + 0.7f*(1.0f-layer/28.0f);
463  color[0] = 0.5f*(layer&2U) + 0.5f*color[0];
464  const bool isFine = ((id>>26)&0x3) == 0;
465  color[0] *= isFine ? 1.0f : 0.4f;
466  color[1] *= isFine ? 0.7f : 0.7f;
467  color[2] *= isFine ? 0.2f : 0.2f;
468  shape->SetMainColorRGB( color[0], color[1], color[2] );
469  shape->SetPickable(false);
470  m_colorComp[kFwHGCalHSiColorIndex]->AddElement(shape);
471  }
472  m_HGCalHSiElements->AddElement( shape );
473  }
474  AddElement( m_HGCalHSiElements );
475  }
476  if (m_HGCalHSiElements ){
477  m_HGCalHSiElements->SetRnrState( showHGCalHSi );
478  gEve->Redraw3D();
479  }
480 }
TEveGeoShape * getHGCSiliconEveShape(unsigned int id) const
Definition: FWGeometry.cc:325
TEveCompound * m_colorComp[kFWGeomColorSize]
TEveElementList * m_HGCalHSiElements
double f[11][100]
const FWGeometry * m_geom
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
void FW3DViewGeometry::showMuonBarrel ( bool  showMuonBarrel)

Definition at line 81 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), triggerObjects_cff::id, kFWMuonBarrelLineColorIndex, FWViewGeometryList::m_geom, m_muonBarrelElements, and alignCSCRings::s.

Referenced by FW3DViewBase::showMuonBarrel().

82 {
84  {
85  m_muonBarrelElements = new TEveElementList( "DT" );
86  for( Int_t iWheel = -2; iWheel <= 2; ++iWheel )
87  {
88  for ( Int_t iStation = 1; iStation <= 4; ++iStation )
89  {
90  // We display only the outer chambers to make the event look more
91  // prominent
92  if( iWheel == -2 || iWheel == 2 || iStation == 4 )
93  {
94  std::ostringstream s;
95  s << "Station" << iStation;
96  TEveElementList* cStation = new TEveElementList( s.str().c_str() );
97  m_muonBarrelElements->AddElement( cStation );
98  for( Int_t iSector = 1 ; iSector <= 14; ++iSector )
99  {
100  if( iStation < 4 && iSector > 12 ) continue;
101  DTChamberId id( iWheel, iStation, iSector );
102  TEveGeoShape* shape = m_geom->getEveShape( id.rawId() );
104  cStation->AddElement( shape );
105  }
106  }
107  }
108  }
109  AddElement( m_muonBarrelElements );
110  }
111 
113  {
114  m_muonBarrelElements->SetRnrState( showMuonBarrel );
115  gEve->Redraw3D();
116  }
117 }
void showMuonBarrel(bool)
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
TEveElementList * m_muonBarrelElements
const FWGeometry * m_geom
void FW3DViewGeometry::showMuonBarrelFull ( bool  showMuonBarrel)

Definition at line 120 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), triggerObjects_cff::id, kFWMuonBarrelLineColorIndex, FWViewGeometryList::m_geom, and m_muonBarrelFullElements.

Referenced by FW3DViewBase::showMuonBarrel().

121 {
123  {
124  m_muonBarrelFullElements = new TEveElementList( "DT Full" );
125  for (Int_t iWheel = -2; iWheel <= 2; ++iWheel)
126  {
127  TEveElementList* cWheel = new TEveElementList(TString::Format("Wheel %d", iWheel));
128  m_muonBarrelFullElements->AddElement(cWheel);
129  for (Int_t iStation = 1; iStation <= 4; ++iStation)
130  {
131  TEveElementList* cStation = new TEveElementList(TString::Format("Station %d", iStation));
132  cWheel->AddElement(cStation);
133  for (Int_t iSector = 1 ; iSector <= 14; ++iSector)
134  {
135  if( iStation < 4 && iSector > 12 ) continue;
136  DTChamberId id( iWheel, iStation, iSector );
137  TEveGeoShape* shape = m_geom->getEveShape(id.rawId());
138  shape->SetTitle(TString::Format("DT: W=%d, S=%d, Sec=%d\ndet-id=%u",
139  iWheel, iStation, iSector, id.rawId()));
141  cStation->AddElement(shape);
142  }
143  }
144  }
145  AddElement(m_muonBarrelFullElements);
146  }
147 
149  {
151  gEve->Redraw3D();
152  }
153 }
void showMuonBarrel(bool)
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
const FWGeometry * m_geom
TEveElementList * m_muonBarrelFullElements
void FW3DViewGeometry::showMuonEndcap ( bool  showMuonEndcap)

Definition at line 157 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), FWGeometry::VersionInfo::haveExtraDet(), triggerObjects_cff::id, kFWMuonEndcapLineColorIndex, FWViewGeometryList::m_geom, m_muonEndcapElements, GEMDetId::maxLayerId, ME0DetId::maxRegionId, GEMDetId::maxRegionId, GEMDetId::maxStationId, GEMDetId::minLayerId, ME0DetId::minRegionId, GEMDetId::minRegionId, GEMDetId::minRollId, GEMDetId::minStationId, alignCSCRings::s, and FWGeometry::versionInfo().

Referenced by FW3DViewBase::setContext().

158 {
160  {
161  m_muonEndcapElements = new TEveElementList( "EndCap" );
162 
163  for( Int_t iEndcap = 1; iEndcap <= 2; ++iEndcap ) // 1=forward (+Z), 2=backward(-Z)
164  {
165  TEveElementList* cEndcap = nullptr;
166  if( iEndcap == 1 )
167  cEndcap = new TEveElementList( "CSC Forward" );
168  else
169  cEndcap = new TEveElementList( "CSC Backward" );
170  m_muonEndcapElements->AddElement( cEndcap );
171  // Actual CSC geometry:
172  // Station 1 has 4 rings with 36 chambers in each
173  // Station 2: ring 1 has 18 chambers, ring 2 has 36 chambers
174  // Station 3: ring 1 has 18 chambers, ring 2 has 36 chambers
175  // Station 4: ring 1 has 18 chambers
176  Int_t maxChambers = 36;
177  for( Int_t iStation = 1; iStation <= 4; ++iStation )
178  {
179  std::ostringstream s; s << "Station" << iStation;
180  TEveElementList* cStation = new TEveElementList( s.str().c_str() );
181  cEndcap->AddElement( cStation );
182  for( Int_t iRing = 1; iRing <= 4; ++iRing )
183  {
184  if( iStation > 1 && iRing > 2 ) continue;
185  // if( iStation > 3 && iRing > 1 ) continue;
186  std::ostringstream s; s << "Ring" << iRing;
187  TEveElementList* cRing = new TEveElementList( s.str().c_str() );
188  cStation->AddElement( cRing );
189  ( iRing == 1 && iStation > 1 ) ? ( maxChambers = 18 ) : ( maxChambers = 36 );
190  for( Int_t iChamber = 1; iChamber <= maxChambers; ++iChamber )
191  {
192  Int_t iLayer = 0; // chamber
193  CSCDetId id( iEndcap, iStation, iRing, iChamber, iLayer );
194  TEveGeoShape* shape = m_geom->getEveShape( id.rawId() );
195  shape->SetTitle(TString::Format("CSC: %s, S=%d, R=%d, C=%d\ndet-id=%u",
196  cEndcap->GetName(), iStation, iRing, iChamber, id.rawId()));
197 
199  cRing->AddElement( shape );
200  }
201  }
202  }
203  }
204  // hardcoded gem and me0; need to find better way for different gem geometries
205  for( Int_t iRegion = GEMDetId::minRegionId; iRegion <= GEMDetId::maxRegionId; iRegion= iRegion+2){
206  TEveElementList* teEndcap = nullptr;
207  if( iRegion == 1 )
208  teEndcap = new TEveElementList( "GEM Forward" );
209  else
210  teEndcap = new TEveElementList( "GEM Backward" );
211  m_muonEndcapElements->AddElement( teEndcap );
212 
213  int mxSt = m_geom->versionInfo().haveExtraDet("GE2") ? GEMDetId::maxStationId :1;
214 
215  for( Int_t iStation = GEMDetId::minStationId; iStation <= mxSt; ++iStation ){
216  std::ostringstream s; s << "Station" << iStation;
217  TEveElementList* cStation = new TEveElementList( s.str().c_str() );
218  teEndcap->AddElement( cStation );
219 
220  Int_t iRing = 1;
221  for( Int_t iLayer = GEMDetId::minLayerId; iLayer <= GEMDetId::maxLayerId ; ++iLayer ){
222  int maxChamber = 36;
223  if (iStation >= 2) maxChamber = 18;
224 
225  for( Int_t iChamber = 1; iChamber <= maxChamber; ++iChamber ){
226  int maxRoll = iChamber%2 ? 9:10;
227  if (iStation == 2) maxRoll = 8;
228  if (iStation == 3) maxRoll = 12;
229 
230  for (Int_t iRoll = GEMDetId::minRollId; iRoll <= maxRoll ; ++iRoll ){
231  GEMDetId id( iRegion, iRing, iStation, iLayer, iChamber, iRoll );
232  TEveGeoShape* shape = m_geom->getEveShape( id.rawId() );
233  if (shape){
234  shape->SetTitle(TString::Format("GEM: , Rng=%d, St=%d, Ch=%d Rl=%d\ndet-id=%u",
235  iRing, iStation, iChamber, iRoll, id.rawId()));
236 
237  cStation->AddElement( shape );
239  }
240  }
241  }
242  }
243  }
244  }
245 
246  // adding me0
247  if (m_geom->versionInfo().haveExtraDet("ME0") ){
248  for( Int_t iRegion = ME0DetId::minRegionId; iRegion <= ME0DetId::maxRegionId; iRegion= iRegion+2 ){
249  TEveElementList* teEndcap = nullptr;
250  if( iRegion == 1 )
251  teEndcap = new TEveElementList( "ME0 Forward" );
252  else
253  teEndcap = new TEveElementList( "ME0 Backward" );
254  m_muonEndcapElements->AddElement( teEndcap );
255 
256  for( Int_t iLayer = 1; iLayer <= 6 ; ++iLayer ){
257  std::ostringstream s; s << "Layer" << iLayer;
258  TEveElementList* cLayer = new TEveElementList( s.str().c_str() );
259  teEndcap->AddElement( cLayer );
260 
261  for( Int_t iChamber = 1; iChamber <= 18; ++iChamber ){
262  Int_t iRoll = 1;
263  // for (Int_t iRoll = ME0DetId::minRollId; iRoll <= ME0DetId::maxRollId ; ++iRoll ){
264  ME0DetId id( iRegion, iLayer, iChamber, iRoll );
265  TEveGeoShape* shape = m_geom->getEveShape( id.rawId() );
266  if (shape){
267  shape->SetTitle(TString::Format("ME0: , Ch=%d Rl=%d\ndet-id=%u",
268  iChamber, iRoll, id.rawId()));
269 
271  cLayer->AddElement( shape );
272  }
273  }
274  }
275  }
276  }
277 
278  AddElement( m_muonEndcapElements );
279  }
280 
282  {
283  m_muonEndcapElements->SetRnrState( showMuonEndcap );
284  gEve->Redraw3D();
285  }
286 }
static const int minRegionId
Definition: GEMDetId.h:94
static const int maxRegionId
Definition: ME0DetId.h:87
const VersionInfo & versionInfo() const
Definition: FWGeometry.h:127
static const int maxLayerId
Definition: GEMDetId.h:108
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
static const int minRegionId
Definition: ME0DetId.h:86
bool haveExtraDet(const char *) const
Definition: FWGeometry.cc:529
void showMuonEndcap(bool)
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
TEveElementList * m_muonEndcapElements
static const int minRollId
Definition: GEMDetId.h:110
const FWGeometry * m_geom
static const int maxStationId
Definition: GEMDetId.h:101
static const int minStationId
Definition: GEMDetId.h:100
static const int minLayerId
Definition: GEMDetId.h:107
static const int maxRegionId
Definition: GEMDetId.h:95
void FW3DViewGeometry::showPixelBarrel ( bool  showPixelBarrel)

Definition at line 290 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), FWGeometry::getMatchedIds(), FWGeometry::getTrackerTopology(), triggerObjects_cff::id, kFWPixelBarrelColorIndex, FWViewGeometryList::m_geom, m_pixelBarrelElements, FWGeometry::PixelBarrel, TrackerTopology::print(), AlCaHLTBitMon_QueryRunRegistry::string, runGCPTkAlMap::title, and FWGeometry::Tracker.

Referenced by FW3DViewBase::setContext().

291 {
293  {
294  m_pixelBarrelElements = new TEveElementList( "PixelBarrel" );
295  m_pixelBarrelElements->SetRnrState( showPixelBarrel );
296  std::vector<unsigned int> ids = m_geom->getMatchedIds( FWGeometry::Tracker, FWGeometry::PixelBarrel );
297  for( std::vector<unsigned int>::const_iterator id = ids.begin();
298  id != ids.end(); ++id )
299  {
300  TEveGeoShape* shape = m_geom->getEveShape( *id );
301 
302  uint32_t rawId = *id;
303  DetId did = DetId(rawId);
305  shape->SetTitle( title.c_str());
306 
308  m_pixelBarrelElements->AddElement( shape );
309  }
310  AddElement( m_pixelBarrelElements );
311  }
312 
314  {
315  m_pixelBarrelElements->SetRnrState( showPixelBarrel );
316  gEve->Redraw3D();
317  }
318 }
TEveElementList * m_pixelBarrelElements
std::string print(DetId detid) const
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
const FWGeometry * m_geom
Definition: DetId.h:18
void showPixelBarrel(bool)
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
const TrackerTopology * getTrackerTopology() const
Definition: FWGeometry.h:133
void FW3DViewGeometry::showPixelEndcap ( bool  showPixelEndcap)

Definition at line 322 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), FWGeometry::getMatchedIds(), FWGeometry::getTrackerTopology(), triggerObjects_cff::id, kFWPixelEndcapColorIndex, FWViewGeometryList::m_geom, m_pixelEndcapElements, FWGeometry::PixelEndcap, TrackerTopology::print(), AlCaHLTBitMon_QueryRunRegistry::string, runGCPTkAlMap::title, and FWGeometry::Tracker.

Referenced by FW3DViewBase::setContext().

323 {
325  {
326  m_pixelEndcapElements = new TEveElementList( "PixelEndcap" );
327  std::vector<unsigned int> ids = m_geom->getMatchedIds( FWGeometry::Tracker, FWGeometry::PixelEndcap );
328  for( std::vector<unsigned int>::const_iterator id = ids.begin();
329  id != ids.end(); ++id )
330  {
331  TEveGeoShape* shape = m_geom->getEveShape( *id );
332  uint32_t rawId = *id;
333  DetId did = DetId(rawId);
335  shape->SetTitle( title.c_str());
337  m_pixelEndcapElements->AddElement( shape );
338  }
339  AddElement( m_pixelEndcapElements );
340  }
341 
343  {
344  m_pixelEndcapElements->SetRnrState( showPixelEndcap );
345  gEve->Redraw3D();
346  }
347 }
std::string print(DetId detid) const
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveElementList * m_pixelEndcapElements
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
const FWGeometry * m_geom
Definition: DetId.h:18
void showPixelEndcap(bool)
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
const TrackerTopology * getTrackerTopology() const
Definition: FWGeometry.h:133
void FW3DViewGeometry::showTrackerBarrel ( bool  showTrackerBarrel)

Definition at line 351 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), FWGeometry::getMatchedIds(), triggerObjects_cff::id, kFWTrackerBarrelColorIndex, FWViewGeometryList::m_geom, m_trackerBarrelElements, FWGeometry::TIB, FWGeometry::TOB, and FWGeometry::Tracker.

Referenced by FW3DViewBase::setContext().

352 {
354  {
355  m_trackerBarrelElements = new TEveElementList( "TrackerBarrel" );
357  std::vector<unsigned int> ids = m_geom->getMatchedIds( FWGeometry::Tracker, FWGeometry::TIB );
358  for( std::vector<unsigned int>::const_iterator id = ids.begin();
359  id != ids.end(); ++id )
360  {
361  TEveGeoShape* shape = m_geom->getEveShape( *id );
363  m_trackerBarrelElements->AddElement( shape );
364  }
366  for( std::vector<unsigned int>::const_iterator id = ids.begin();
367  id != ids.end(); ++id )
368  {
369  TEveGeoShape* shape = m_geom->getEveShape( *id );
370  shape->SetTitle(Form("TrackerBarrel %d",*id));
372  m_trackerBarrelElements->AddElement( shape );
373  }
374  AddElement( m_trackerBarrelElements );
375  }
376 
378  {
380  gEve->Redraw3D();
381  }
382 }
void showTrackerBarrel(bool)
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
const FWGeometry * m_geom
TEveElementList * m_trackerBarrelElements
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214
void FW3DViewGeometry::showTrackerEndcap ( bool  showTrackerEndcap)

Definition at line 386 of file FW3DViewGeometry.cc.

References FWViewGeometryList::addToCompound(), FWGeometry::getEveShape(), FWGeometry::getMatchedIds(), triggerObjects_cff::id, kFWTrackerEndcapColorIndex, FWViewGeometryList::m_geom, m_trackerEndcapElements, FWGeometry::TEC, FWGeometry::TID, and FWGeometry::Tracker.

Referenced by FW3DViewBase::setContext().

387 {
389  {
390  m_trackerEndcapElements = new TEveElementList( "TrackerEndcap" );
391  std::vector<unsigned int> ids = m_geom->getMatchedIds( FWGeometry::Tracker, FWGeometry::TID );
392  for( std::vector<unsigned int>::const_iterator id = ids.begin();
393  id != ids.end(); ++id )
394  {
395  TEveGeoShape* shape = m_geom->getEveShape( *id );
397  m_trackerEndcapElements->AddElement( shape );
398  }
400  for( std::vector<unsigned int>::const_iterator id = ids.begin();
401  id != ids.end(); ++id )
402  {
403  TEveGeoShape* shape = m_geom->getEveShape( *id );
404 
405  shape->SetTitle(Form("TrackerEndcap %d",*id));
407  m_trackerEndcapElements->AddElement( shape );
408  }
409  AddElement( m_trackerEndcapElements );
410  }
411 
413  {
415  gEve->Redraw3D();
416  }
417 }
void showTrackerEndcap(bool)
void addToCompound(TEveElement *el, FWGeomColorIndex idx, bool applyTransp=true) const
TEveGeoShape * getEveShape(unsigned int id) const
Definition: FWGeometry.cc:298
const FWGeometry * m_geom
TEveElementList * m_trackerEndcapElements
std::vector< unsigned int > getMatchedIds(Detector det, SubDetector subdet) const
Definition: FWGeometry.cc:214

Member Data Documentation

TEveElementList* FW3DViewGeometry::m_HGCalEEElements
private

Definition at line 72 of file FW3DViewGeometry.h.

Referenced by showHGCalEE().

TEveElementList* FW3DViewGeometry::m_HGCalHScElements
private

Definition at line 74 of file FW3DViewGeometry.h.

Referenced by showHGCalHSc().

TEveElementList* FW3DViewGeometry::m_HGCalHSiElements
private

Definition at line 73 of file FW3DViewGeometry.h.

Referenced by showHGCalHSi().

TEveElementList* FW3DViewGeometry::m_muonBarrelElements
private

Definition at line 64 of file FW3DViewGeometry.h.

Referenced by showMuonBarrel().

TEveElementList* FW3DViewGeometry::m_muonBarrelFullElements
private

Definition at line 65 of file FW3DViewGeometry.h.

Referenced by showMuonBarrelFull().

TEveElementList* FW3DViewGeometry::m_muonEndcapElements
private

Definition at line 66 of file FW3DViewGeometry.h.

Referenced by showMuonEndcap().

TEveElementList* FW3DViewGeometry::m_muonEndcapFullElements
private

Definition at line 67 of file FW3DViewGeometry.h.

TEveElementList* FW3DViewGeometry::m_pixelBarrelElements
private

Definition at line 68 of file FW3DViewGeometry.h.

Referenced by showPixelBarrel().

TEveElementList* FW3DViewGeometry::m_pixelEndcapElements
private

Definition at line 69 of file FW3DViewGeometry.h.

Referenced by showPixelEndcap().

TEveElementList* FW3DViewGeometry::m_trackerBarrelElements
private

Definition at line 70 of file FW3DViewGeometry.h.

Referenced by showTrackerBarrel().

TEveElementList* FW3DViewGeometry::m_trackerEndcapElements
private

Definition at line 71 of file FW3DViewGeometry.h.

Referenced by showTrackerEndcap().