#include <VisFramework/VisEventSetup/interface/VisRPCGeometryTwig.h>
Public Member Functions | |
virtual void | onNewEvent (const edm::Event &event, const edm::EventSetup &eventSetup) |
virtual void | update (IgRZRep *rep) |
virtual void | update (IgRPhiRep *rep) |
virtual void | update (Ig3DRep *rep) |
virtual void | update (IgTextRep *rep) |
VisRPCGeometryTwig (IgState *state, IgTwig *parent, const std::string &name="", const int region=10, const int wheel=10, const int sector=30, const int station=30) | |
virtual | ~VisRPCGeometryTwig (void) |
Clean the scene graph. | |
Private Member Functions | |
void | invalidate (void) |
Private Attributes | |
SoSeparator * | m_3dDet |
bool | m_3Ddone |
VisAnnotateGeometry | m_annotate |
const int | m_region |
SoSeparator * | m_rphiDet |
bool | m_rphidone |
SoSeparator * | m_rzDet |
bool | m_rzdone |
const int | m_sector |
const int | m_station |
const int | m_wheel |
Definition at line 25 of file VisRPCGeometryTwig.h.
VisRPCGeometryTwig::VisRPCGeometryTwig | ( | IgState * | state, | |
IgTwig * | parent, | |||
const std::string & | name = "" , |
|||
const int | region = 10 , |
|||
const int | wheel = 10 , |
|||
const int | sector = 30 , |
|||
const int | station = 30 | |||
) |
Definition at line 23 of file VisRPCGeometryTwig.cc.
00029 : VisQueuedTwig (state, parent, name), 00030 m_region (region), 00031 m_wheel (wheel), 00032 m_sector (sector), 00033 m_station (station), 00034 m_3dDet (NULL), 00035 m_rzDet (NULL), 00036 m_rphiDet (NULL), 00037 m_3Ddone (false), 00038 m_rzdone (false), 00039 m_rphidone (false), 00040 m_annotate (state, lat::CreateCallback (this, &VisRPCGeometryTwig::invalidate)) 00041 {}
VisRPCGeometryTwig::~VisRPCGeometryTwig | ( | void | ) | [virtual] |
Definition at line 52 of file VisRPCGeometryTwig.cc.
References m_3dDet, m_3Ddone, m_rphiDet, m_rphidone, m_rzDet, m_rzdone, NULL, and VisQueuedTwig::onBaseInvalidate().
Referenced by onNewEvent().
00053 { 00054 if (m_3dDet != NULL) m_3dDet->unref (); 00055 if (m_rzDet != NULL) m_rzDet->unref (); 00056 if (m_rphiDet != NULL) m_rphiDet->unref (); 00057 m_3Ddone = false; 00058 m_rzdone = false; 00059 m_rphidone = false; 00060 00061 VisQueuedTwig::onBaseInvalidate (); 00062 }
void VisRPCGeometryTwig::onNewEvent | ( | const edm::Event & | event, | |
const edm::EventSetup & | eventSetup | |||
) | [virtual] |
Reimplemented from VisQueuedTwig.
Definition at line 65 of file VisRPCGeometryTwig.cc.
References ASSERT, DBSPlugin::get(), invalidate(), VisEventSetupService::muonGeomChanged(), VisQueuedTwig::onNewEvent(), and VisQueuedTwig::state().
00067 { 00068 // Get debugging dump. 00069 VisQueuedTwig::onNewEvent (event, eventSetup); 00070 00071 VisEventSetupService *esService = VisEventSetupService::get (state ()); 00072 ASSERT (esService); 00073 00074 if (esService->muonGeomChanged ()) 00075 invalidate (); 00076 }
Reimplemented from VisQueuedTwig.
Definition at line 167 of file VisRPCGeometryTwig.cc.
References VisEventSetupService::annotateRPCChambers(), ASSERT, VisEventSetupService::buildRPCChambers(), Ig3DBaseRep::clear(), DBSPlugin::get(), m_annotate, m_region, m_rzDet, m_rzdone, m_sector, m_station, m_wheel, Ig3DBaseRep::node(), NULL, VisEventSetupService::RZDet, VisQueuedTwig::state(), VisQueuedTwig::update(), and VisActiveConfigurable< T >::value().
00168 { 00169 // Get debugging dump. 00170 VisQueuedTwig::update (rep); 00171 00172 IgQtLock (); 00173 rep->clear (); 00174 00175 if (! m_rzdone) 00176 { 00177 VisEventSetupService *esService = VisEventSetupService::get (state ()); 00178 ASSERT (esService); 00179 00180 m_rzdone = esService->buildRPCChambers (VisEventSetupService::RZDet, m_region, m_wheel, m_sector, m_station); 00181 00182 if (m_rzDet == NULL) return; 00183 00184 if (m_annotate.value ()) 00185 { 00186 SoSeparator *sep = esService->annotateRPCChambers (VisEventSetupService::RZDet, m_region, m_wheel, m_sector, m_station); 00187 if (sep != NULL) m_rzDet->addChild (sep); 00188 } 00189 00190 m_rzDet->ref (); 00191 m_rzdone = true; 00192 } 00193 rep->node ()->addChild (m_rzDet); 00194 }
Reimplemented from VisQueuedTwig.
Definition at line 137 of file VisRPCGeometryTwig.cc.
References VisEventSetupService::annotateRPCChambers(), ASSERT, VisEventSetupService::buildRPCChambers(), Ig3DBaseRep::clear(), DBSPlugin::get(), m_annotate, m_region, m_rphiDet, m_rphidone, m_sector, m_station, m_wheel, Ig3DBaseRep::node(), NULL, VisEventSetupService::RPhiDet, VisQueuedTwig::state(), VisQueuedTwig::update(), and VisActiveConfigurable< T >::value().
00138 { 00139 // Get debugging dump. 00140 VisQueuedTwig::update (rep); 00141 00142 IgQtLock (); 00143 rep->clear (); 00144 00145 if (! m_rphidone) 00146 { 00147 VisEventSetupService *esService = VisEventSetupService::get (state ()); 00148 ASSERT (esService); 00149 00150 m_rphiDet = esService->buildRPCChambers (VisEventSetupService::RPhiDet, m_region, m_wheel, m_sector, m_station); 00151 00152 if (m_rphiDet == NULL) return; 00153 00154 if (m_annotate.value ()) 00155 { 00156 SoSeparator *sep = esService->annotateRPCChambers (VisEventSetupService::RPhiDet, m_region, m_wheel, m_sector, m_station); 00157 if (sep != NULL) m_rphiDet->addChild (sep); 00158 } 00159 00160 m_rphiDet->ref (); 00161 m_rphidone = true; 00162 } 00163 rep->node ()->addChild (m_rphiDet); 00164 }
Reimplemented from VisQueuedTwig.
Definition at line 107 of file VisRPCGeometryTwig.cc.
References VisEventSetupService::annotateRPCChambers(), ASSERT, VisEventSetupService::buildRPCChambers(), Ig3DBaseRep::clear(), VisEventSetupService::FullDet, DBSPlugin::get(), m_3dDet, m_3Ddone, m_annotate, m_region, m_sector, m_station, m_wheel, Ig3DBaseRep::node(), NULL, VisQueuedTwig::state(), VisQueuedTwig::update(), and VisActiveConfigurable< T >::value().
00108 { 00109 // Get debugging dump. 00110 VisQueuedTwig::update (rep); 00111 00112 IgQtLock (); 00113 rep->clear (); 00114 00115 if (! m_3Ddone) 00116 { 00117 VisEventSetupService *esService = VisEventSetupService::get (state ()); 00118 ASSERT (esService); 00119 00120 m_3dDet = esService->buildRPCChambers (VisEventSetupService::FullDet, m_region, m_wheel, m_sector, m_station); 00121 00122 if (m_3dDet == NULL) return; 00123 00124 if (m_annotate.value ()) 00125 { 00126 SoSeparator *sep = esService->annotateRPCChambers (VisEventSetupService::FullDet, m_region, m_wheel, m_sector, m_station); 00127 if (sep != NULL) m_3dDet->addChild (sep); 00128 } 00129 00130 m_3dDet->ref (); 00131 m_3Ddone = true; 00132 } 00133 rep->node ()->addChild (m_3dDet); 00134 }
Reimplemented from VisQueuedTwig.
Definition at line 79 of file VisRPCGeometryTwig.cc.
References ASSERT, DBSPlugin::get(), m_region, m_sector, m_station, m_wheel, IgSimpleTwig::name(), VisEventSetupService::rpcTextRep(), IgTextRep::setText(), VisQueuedTwig::state(), and VisQueuedTwig::update().
00080 { 00081 // Get debugging dump. 00082 VisQueuedTwig::update (rep); 00083 00084 // Prepare property description. 00085 std::ostringstream text; 00086 text << "CMS RPC Muon Geometry: "; 00087 text << this->name () << "<br>"; 00088 00089 text << "<table width='100%' border=1>" 00090 << "<TR align = center>" 00091 << "<TH>#</TH>" 00092 << "<TH>Barrel/Wheel/Sector/Station</TH>" 00093 << "<TH>Position</TH>" 00094 << "</TR>"; 00095 00096 VisEventSetupService *esService = VisEventSetupService::get (state ()); 00097 ASSERT (esService); 00098 00099 text << esService->rpcTextRep (m_region, m_wheel, m_station, m_sector); 00100 text << "</table>"; 00101 00102 IgQtLock (); 00103 rep->setText (text.str ()); 00104 }
SoSeparator* VisRPCGeometryTwig::m_3dDet [private] |
Definition at line 56 of file VisRPCGeometryTwig.h.
Referenced by invalidate(), update(), and ~VisRPCGeometryTwig().
bool VisRPCGeometryTwig::m_3Ddone [private] |
const int VisRPCGeometryTwig::m_region [private] |
SoSeparator* VisRPCGeometryTwig::m_rphiDet [private] |
Definition at line 58 of file VisRPCGeometryTwig.h.
Referenced by invalidate(), update(), and ~VisRPCGeometryTwig().
bool VisRPCGeometryTwig::m_rphidone [private] |
SoSeparator* VisRPCGeometryTwig::m_rzDet [private] |
Definition at line 57 of file VisRPCGeometryTwig.h.
Referenced by invalidate(), update(), and ~VisRPCGeometryTwig().
bool VisRPCGeometryTwig::m_rzdone [private] |
const int VisRPCGeometryTwig::m_sector [private] |
const int VisRPCGeometryTwig::m_station [private] |
const int VisRPCGeometryTwig::m_wheel [private] |