#include <FWEveOverlap.h>
Public Member Functions | |
virtual FWGeometryTableViewBase * | browser () |
FWEveOverlap (FWOverlapTableView *v) | |
virtual TString | GetHighlightTooltip () |
virtual void | Paint (Option_t *option="") |
virtual void | popupMenu (int x, int y, TGLViewer *v) |
virtual FWGeometryTableManagerBase * | tableManager () |
virtual | ~FWEveOverlap () |
Private Member Functions | |
ClassDef (FWEveOverlap, 0) | |
bool | paintChildNodesRecurse (FWGeometryTableManagerBase::Entries_i pIt, Int_t idx, const TGeoHMatrix &mtx) |
Private Attributes | |
FWOverlapTableView * | m_browser |
Definition at line 10 of file FWEveOverlap.h.
FWEveOverlap::FWEveOverlap | ( | FWOverlapTableView * | v | ) |
Definition at line 11 of file FWEveOverlap.cc.
: m_browser(v) { }
virtual FWEveOverlap::~FWEveOverlap | ( | ) | [inline, virtual] |
Definition at line 14 of file FWEveOverlap.h.
{}
FWGeometryTableViewBase * FWEveOverlap::browser | ( | ) | [virtual] |
Reimplemented from FWGeoTopNode.
Definition at line 20 of file FWEveOverlap.cc.
References m_browser.
{ return m_browser; }
FWEveOverlap::ClassDef | ( | FWEveOverlap | , |
0 | |||
) | [private] |
TString FWEveOverlap::GetHighlightTooltip | ( | ) | [virtual] |
Definition at line 110 of file FWEveOverlap.cc.
References AlCaHLTBitMon_QueryRunRegistry::data, FWGeoTopNode::fHted, FWOverlapTableView::getTableManager(), UserOptions_cff::idx, FWOverlapTableManager::kOverlap, m_browser, FWGeometryTableManagerBase::NodeInfo::name(), mergeVDriftHistosByStation::name, FWGeometryTableManagerBase::refEntries(), FWGeoTopNode::tableIdx(), and FWGeometryTableManagerBase::NodeInfo::testBit().
{ // printf("highlight tooltio \n"); std::set<TGLPhysicalShape*>::iterator it = fHted.begin(); int idx = tableIdx(*it); if ( idx < 0) { return Form("TopNode "); } FWGeometryTableManagerBase::NodeInfo& data = m_browser->getTableManager()->refEntries().at(idx); TString name = data.name(); if (data.testBit(FWOverlapTableManager::kOverlap)) { ((FWOverlapTableManager*)m_browser->getTableManager())->getOverlapTitles(idx, name); return name; } return data.name(); }
void FWEveOverlap::Paint | ( | Option_t * | option = "" | ) | [virtual] |
Reimplemented from FWGeoTopNode.
Definition at line 26 of file FWEveOverlap.cc.
References FWGeometryTableViewManager::getGeoMangeur(), FWGeometryTableManagerBase::getNodeMatrix(), FWOverlapTableView::getTableManager(), FWGeometryTableViewBase::getTopNodeIdx(), FWGeometryTableManagerBase::kVisNodeChld, FWGeometryTableManagerBase::kVisNodeSelf, m_browser, paintChildNodesRecurse(), FWGeoTopNode::paintShape(), and FWGeometryTableManagerBase::refEntries().
{ if (m_browser->getTableManager()->refEntries().empty()) return; FWGeoTopNode::Paint(); TEveGeoManagerHolder gmgr( FWGeometryTableViewManager::getGeoMangeur()); int topNodeIdx = m_browser->getTopNodeIdx(); FWGeometryTableManagerBase::Entries_i sit = m_browser->getTableManager()->refEntries().begin(); std::advance(sit,topNodeIdx ); TGeoHMatrix mtx; m_browser->getTableManager()->getNodeMatrix(*sit, mtx); bool drawsChildren = false; if ( (*sit).testBit(FWGeometryTableManagerBase::kVisNodeChld)) drawsChildren = paintChildNodesRecurse( sit, topNodeIdx, mtx); if (sit->testBit(FWGeometryTableManagerBase::kVisNodeSelf)) paintShape(topNodeIdx,mtx, false, drawsChildren); }
bool FWEveOverlap::paintChildNodesRecurse | ( | FWGeometryTableManagerBase::Entries_i | pIt, |
Int_t | idx, | ||
const TGeoHMatrix & | mtx | ||
) | [private] |
Definition at line 54 of file FWEveOverlap.cc.
References FWGeometryTableManagerBase::getNNodesTotal(), FWOverlapTableManager::kOverlap, FWOverlapTableManager::kOverlapChild, FWGeometryTableManagerBase::kVisNodeChld, FWGeometryTableManagerBase::kVisNodeSelf, m_browser, FWOverlapTableView::m_rnrExtrusion, FWOverlapTableView::m_rnrOverlap, n, FWGeoTopNode::paintShape(), and FWGenericParameter< T >::value().
Referenced by Paint().
{ TGeoNode* parentNode = pIt->m_node; int nD = parentNode->GetNdaughters(); int dOff=0; pIt++; int pcnt = cnt+1; bool drawsChildren = false; FWGeometryTableManagerBase::Entries_i it; for (int n = 0; n != nD; ++n) { it = pIt; std::advance(it,n + dOff); cnt = pcnt + n+dOff; TGeoHMatrix nm = parentMtx; nm.Multiply(it->m_node->GetMatrix()); bool drawsChildrenSecondGen = false; if ( it->testBit(FWGeometryTableManagerBase::kVisNodeChld) && it->testBit(FWOverlapTableManager::kOverlapChild)) drawsChildrenSecondGen = paintChildNodesRecurse(it,cnt , nm); if (it->testBit(FWGeometryTableManagerBase::kVisNodeSelf)) { if (it->testBit(FWOverlapTableManager::kOverlap)) { int nno;it->m_node->GetOverlaps(nno); if ( (m_browser->m_rnrOverlap.value() && ((nno & BIT(1)) == BIT(1)) ) || (m_browser->m_rnrExtrusion.value() && ((nno & BIT(2)) == BIT(2)) )) { paintShape(cnt , nm, false, drawsChildrenSecondGen); drawsChildren = true; } } else { paintShape(cnt , nm, false, drawsChildrenSecondGen); drawsChildren = true; } } drawsChildren |= drawsChildrenSecondGen; FWGeometryTableManagerBase::getNNodesTotal(parentNode->GetDaughter(n), dOff); } return drawsChildren; }
void FWEveOverlap::popupMenu | ( | int | x, |
int | y, | ||
TGLViewer * | v | ||
) | [virtual] |
Reimplemented from FWGeoTopNode.
Definition at line 134 of file FWEveOverlap.cc.
References m_browser, and FWGeoTopNode::setPopupMenu().
{ FWPopupMenu* nodePopup = setPopupMenu(x, y,v, true); if (nodePopup) nodePopup->Connect("Activated(Int_t)", "FWOverlapTableView", m_browser, "chosenItem(Int_t)"); }
FWGeometryTableManagerBase * FWEveOverlap::tableManager | ( | ) | [virtual] |
Reimplemented from FWGeoTopNode.
Definition at line 15 of file FWEveOverlap.cc.
References FWOverlapTableView::getTableManager(), and m_browser.
{ return m_browser->getTableManager(); }
FWOverlapTableView* FWEveOverlap::m_browser [private] |
Definition at line 23 of file FWEveOverlap.h.
Referenced by browser(), GetHighlightTooltip(), Paint(), paintChildNodesRecurse(), popupMenu(), and tableManager().