ATLAS Offline Software
Classes | Public Types | Public Slots | Signals | Public Member Functions | Static Public Member Functions | Protected Slots | Protected Member Functions | Protected Attributes | Private Slots | Private Member Functions | Static Private Attributes | List of all members
VP1GeometrySystem Class Reference

#include <VP1GeometrySystem.h>

Inheritance diagram for VP1GeometrySystem:
Collaboration diagram for VP1GeometrySystem:

Classes

class  Imp
 

Public Types

typedef std::set< SoCamera * > CamList
 
typedef CamList::iterator CamListItr
 
enum  State { CONSTRUCTED =0, REFRESHED, ERASED, UNCREATED }
 
enum  ActiveState { ON =0, OFF }
 

Public Slots

void reiconizeToShowSpecificMuonChambers (const std::set< GeoPVConstLink > &)
 
void orientViewToMuonChamber (const GeoPVConstLink &chamberPV)
 
void setCurvedSurfaceRealism (int)
 
void muonChamberT0sChanged (const std::map< GeoPVConstLink, float > &, int)
 The map is the dt0 per chamber, plus a label identifier, which by convention (!) is 0=Moore, 1=Muonboy. More...
 

Signals

void appropriateMDTProjectionsChanged (int)
 
void plotSpectrum (QStack< QString > &, int copyNumber=-1)
 
void itemFromSystemSelected ()
 
void sysmessage (QString) const
 
void inactiveSystemTurnedActive ()
 
void needErase ()
 

Public Member Functions

 VP1GeometrySystem (const VP1GeoFlags::SubSystemFlags &SubSystemsTurnedOn=VP1GeoFlags::None, const QString &name="Geo")
 
virtual ~VP1GeometrySystem ()
 
void setGeometrySelectable (bool)
 
void setZoomToVolumeOnClick (bool)
 
void setOrientViewToMuonChambersOnClick (bool)
 
void setAutoAdaptMuonChambersToEventData (bool)
 
QWidget * buildController ()
 
void systemcreate (StoreGateSvc *detstore)
 
void buildPermanentSceneGraph (StoreGateSvc *detstore, SoSeparator *root)
 
void buildEventSceneGraph (StoreGateSvc *, SoSeparator *)
 
void userPickedNode (SoNode *pickedNode, SoPath *pickedPath)
 
void systemuncreate ()
 
QByteArray saveState ()
 
void restoreFromState (QByteArray)
 
void enableMuonChamberLabels (bool, bool)
 first is t0s, 2nd is hits More...
 
void ensureBuildController ()
 
void updateGUI ()
 
virtual void systemerase ()
 
void warnOnDisabledNotifications () const
 
void registerCamera (SoCamera *camera)
 
void registerViewer (SoQtViewer *viewer)
 
void registerSelectionNode (SoCooperativeSelection *)
 
void unregisterSelectionNode (SoCooperativeSelection *)
 
void setUserSelectionNotificationsEnabled (SoCooperativeSelection *sel, bool enabled)
 
virtual void userSelectedSingleNode (SoCooperativeSelection *, SoNode *, SoPath *)
 
virtual void userDeselectedSingleNode (SoCooperativeSelection *, SoNode *, SoPath *)
 
virtual void userChangedSelection (SoCooperativeSelection *, QSet< SoNode * >, QSet< SoPath * >)
 
virtual void userClickedOnBgd ()
 
virtual void deselectAll (SoCooperativeSelection *exception_sel=0)
 
CamList getCameraList ()
 
virtual QWidget * buildExtraDisplayWidget ()
 
const QString & name () const
 
const QString & information () const
 
const QString & contact_info () const
 
QWidget * controllerWidget ()
 
void message (const QString &) const
 
void message (const QStringList &, const QString &addtoend="") const
 
void message (const QString &addtostart, const QStringList &, const QString &addtoend="") const
 
void messageDebug (const QString &) const
 
void messageDebug (const QStringList &, const QString &addtoend="") const
 
void messageDebug (const QString &addtostart, const QStringList &, const QString &addtoend="") const
 
void messageVerbose (const QString &) const
 
void messageVerbose (const QStringList &, const QString &addtoend="") const
 
void messageVerbose (const QString &addtostart, const QStringList &, const QString &addtoend="") const
 
StoreGateSvcstoreGate () const
 
StoreGateSvceventStore () const
 
StoreGateSvcdetectorStore () const
 
ISvcLocator * serviceLocator () const
 
IToolSvc * toolSvc () const
 
State state () const
 
ActiveState activeState () const
 

Static Public Member Functions

static bool verbose ()
 
static QString str (const QString &s)
 
static QString str (const char *c)
 
static QString str (const bool b)
 
static QString str (const QColor &)
 
static QString str (const SbColor &)
 
static QString str (const VP1Interval &)
 
static QString str (const SbVec2d &)
 
static QString str (const SbVec2f &)
 
static QString str (const SbVec2s &)
 
static QString str (const SbVec3d &)
 
static QString str (const SbVec3f &)
 
static QString str (const SbVec3s &)
 
static QString str (const SbVec4d &)
 
static QString str (const SbVec4f &)
 
static QString str (short int n)
 
static QString str (unsigned short int n)
 
static QString str (long n)
 
static QString str (ulong n)
 
static QString str (int n)
 
static QString str (uint n)
 
static QString str (qlonglong n)
 
static QString str (qulonglong n)
 
static QString str (const double &d)
 
static QString str (const float &f)
 
static QString str (const void *)
 
template<class T >
static QString str (const T *t)
 
template<class T >
static QString str (const QFlags< T > &f)
 
template<class T >
static QString str (const HepGeom::BasicVector3D< T > &t)
 
static QString str (const Amg::Vector3D &t)
 
template<class T >
static QString str (const QList< T > &t)
 

Protected Slots

void checkboxChanged ()
 
void updateTransparency ()
 
void adaptMuonChambersToEventData ()
 
void adaptMuonChambersStyleChanged ()
 
void emit_appropriateMDTProjectionsChanged ()
 
void autoAdaptPixelsOrSCT (bool, bool, bool, bool, bool, bool)
 
void autoAdaptMuonNSW (bool reset, bool stgc, bool mm, bool passiveSpacer, bool passiveStructure, bool passiveAPlate)
 
void resetSubSystems (VP1GeoFlags::SubSystemFlags)
 
void autoExpandByVolumeOrMaterialName (bool, const QString &)
 
void autoIconifyByVolumeOrMaterialName (bool, const QString &)
 
void actionOnAllNonStandardVolumes (bool)
 
void volumeStateChangeRequested (VolumeHandle *, VP1GeoFlags::VOLSTATE)
 
void volumeResetRequested (VolumeHandle *)
 
void setShowVolumeOutLines (bool)
 
void saveMaterialsToFile (const QString &, bool)
 
void loadMaterialsFromFile (const QString &)
 
void setLabels (int)
 
void setLabelPosOffsets (const QList< int > &)
 

Protected Member Functions

void registerController (QWidget *)
 

Protected Attributes

Impm_d
 

Private Slots

void activateClickedOutside ()
 

Private Member Functions

SoSeparator * getSceneGraph () const
 
void create (StoreGateSvc *detstore)
 
void refresh (StoreGateSvc *storegate)
 
void erase ()
 
void uncreate ()
 
void disallowUpdateGUI ()
 
void allowUpdateGUI ()
 
void setChannel (IVP1ChannelWidget *)
 
IVP1ChannelWidgetchannel () const
 
void deleteController ()
 
void setState (const State &)
 
void setActiveState (const ActiveState &, const bool &donttriggererase=true)
 
bool isRefreshing ()
 
void setRefreshing (const bool &)
 
void setCanRegisterController (const bool &)
 

Static Private Attributes

static const bool s_vp1verbose = VP1QtUtils::environmentVariableIsOn("VP1_VERBOSE_OUTPUT")
 

Detailed Description

Definition at line 33 of file VP1GeometrySystem.h.

Member Typedef Documentation

◆ CamList

typedef std::set<SoCamera*> IVP13DSystem::CamList
inherited

Definition at line 90 of file IVP13DSystem.h.

◆ CamListItr

typedef CamList::iterator IVP13DSystem::CamListItr
inherited

Definition at line 91 of file IVP13DSystem.h.

Member Enumeration Documentation

◆ ActiveState

enum IVP1System::ActiveState
inherited
Enumerator
ON 
OFF 

Definition at line 144 of file IVP1System.h.

144 { ON=0, OFF };//Whether it is part of the erase/refresh cycle.

◆ State

enum IVP1System::State
inherited
Enumerator
CONSTRUCTED 
REFRESHED 
ERASED 
UNCREATED 

Definition at line 143 of file IVP1System.h.

Constructor & Destructor Documentation

◆ VP1GeometrySystem()

VP1GeometrySystem::VP1GeometrySystem ( const VP1GeoFlags::SubSystemFlags &  SubSystemsTurnedOn = VP1GeoFlags::None,
const QString &  name = "Geo" 
)

Definition at line 303 of file VP1GeometrySystem.cxx.

305  "This system displays the geometry as defined in the GeoModel tree.",
306  "Riccardo.Maria.Bianchi@cern.ch"),
307  m_d(new Imp(this,SubSystemsTurnedOn))
308 {
309 }

◆ ~VP1GeometrySystem()

VP1GeometrySystem::~VP1GeometrySystem ( )
virtual

Definition at line 328 of file VP1GeometrySystem.cxx.

329 {
330  delete m_d;
331  m_d = 0;
332 }

Member Function Documentation

◆ actionOnAllNonStandardVolumes

void VP1GeometrySystem::actionOnAllNonStandardVolumes ( bool  zap)
protectedslot

Definition at line 2027 of file VP1GeometrySystem.cxx.

2028 {
2030  messageVerbose("Action on volumes with non-standard VRML representations. Target state is "+VP1GeoFlags::toString(target));
2031 
2032  std::vector<std::pair<VolumeHandle::VolumeHandleListItr,VolumeHandle::VolumeHandleListItr> > roothandles;
2033  m_d->volumetreemodel->getRootHandles(roothandles);
2035 
2036  bool save = m_d->sceneroot->enableNotify(false);
2038 
2039  deselectAll();
2040 
2041  for (unsigned i = 0; i<roothandles.size();++i) {
2042  it = roothandles.at(i).first;
2043  itE = roothandles.at(i).second;
2044  for(;it!=itE;++it) {
2046  }
2047  }
2048 
2051  if (save) {
2052  m_d->sceneroot->enableNotify(true);
2053  m_d->sceneroot->touch();
2054  }
2055 }

◆ activateClickedOutside

void IVP13DSystem::activateClickedOutside ( )
privateslotinherited

Definition at line 85 of file IVP13DSystem.cxx.

86 {
88  return;
91 }

◆ activeState()

IVP1System::ActiveState IVP1System::activeState ( ) const
inherited

Definition at line 135 of file IVP1System.cxx.

136 {
137  return m_d->activeState;
138 }

◆ adaptMuonChambersStyleChanged

void VP1GeometrySystem::adaptMuonChambersStyleChanged ( )
protectedslot

Definition at line 1577 of file VP1GeometrySystem.cxx.

1578 {
1579  //Make all chamber representations dirty:
1581  for (it=m_d->muonchambers_pv2handles.begin();it!=itE;++it)
1582  it->second->setMuonChamberDirty(true);
1583 
1584  //Adapt immediately if necessary:
1588 }

◆ adaptMuonChambersToEventData

void VP1GeometrySystem::adaptMuonChambersToEventData ( )
protectedslot

Definition at line 1539 of file VP1GeometrySystem.cxx.

1540 {
1541  if (m_d->muonchambers_pv2handles.empty())
1542  return;
1543 
1544  std::set<GeoPVConstLink> allchambers;
1545  if (!m_d->sender2ChamberList.empty()) {
1546  allchambers = (m_d->sender2ChamberList.begin())->second;
1547  std::map<QObject*,std::set<GeoPVConstLink> >::iterator itLists,itListsE(m_d->sender2ChamberList.end());
1548  for (itLists = m_d->sender2ChamberList.begin(),++itLists;itLists != itListsE;++itLists) {
1549  allchambers.insert(itLists->second.begin(),itLists->second.end());
1550  }
1551  }
1552 
1553  //Idea: Maybe just iconise them all and then selectively deiconise the few? Then we can avoid most searches!
1554  bool save = m_d->sceneroot->enableNotify(false);
1556 
1557  deselectAll();
1559  std::set<GeoPVConstLink>::iterator itchambersE = allchambers.end();
1560  for (it=m_d->muonchambers_pv2handles.begin();it!=itE;++it) {
1561  if (allchambers.find(it->first)==itchambersE)
1562  it->second->setState(VP1GeoFlags::ZAPPED);
1563  else {
1564  if (it->second->muonChamberDirty())
1565  m_d->updateTouchedMuonChamber(it->second);
1566  }
1567  }
1570  if (save) {
1571  m_d->sceneroot->enableNotify(true);
1572  m_d->sceneroot->touch();
1573  }
1574 }

◆ allowUpdateGUI()

void IVP1System::allowUpdateGUI ( )
privateinherited

Definition at line 256 of file IVP1System.cxx.

257 {
258  m_d->allowupdategui=true;
259 }

◆ appropriateMDTProjectionsChanged

void VP1GeometrySystem::appropriateMDTProjectionsChanged ( int  )
signal

◆ autoAdaptMuonNSW

void VP1GeometrySystem::autoAdaptMuonNSW ( bool  reset,
bool  stgc,
bool  mm,
bool  passiveSpacer,
bool  passiveStructure,
bool  passiveAPlate 
)
protectedslot

Definition at line 2354 of file VP1GeometrySystem.cxx.

2355 {
2356  VP1Msg::messageDebug("VP1GeometrySystem::autoAdaptMuonNSW()");
2357 
2358  #ifndef BUILDVP1LIGHT
2359  // return if Muon and MuonNSW are not configured/present/ON
2361  return;
2362  #endif
2363 
2364  if( reset )
2365  VP1Msg::messageDebug("resetting to full NSW...");
2366 
2368 
2370  //Find subsystem:
2371  Imp::SubSystemInfo* subsys(0);
2372  for (Imp::SubSystemInfo*si : m_d->subsysInfoList) {
2373  if (si->flag == subSysFlag) {
2374  subsys = si;
2375  break;
2376  }
2377  }
2378  if (!subsys) {
2379  message("autoAdaptMuonNSW Error: Could not find subsystem");
2380  return;
2381  }
2382 
2383 
2385  //Abort if corresponding subsystem is not built:
2386  if (!subsys->isbuilt) {
2387  VP1Msg::messageDebug("autoAdaptMuonNSW: Aborting since subsystem geometry not built yet");
2388  return;//Disabling now due to phi-sector problems if "click some phi sectors"->"adapt pixel"->"turn on pixel"
2389  }
2390  bool save = m_d->sceneroot->enableNotify(false);
2392 
2393  VolumeHandle::VolumeHandleListItr it(subsys->vollist.begin()),itE(subsys->vollist.end());
2394 
2395  // loop over first level children (i.e., 'NewSmallWheel')
2396  for (;it!=itE;++it) {
2397 
2398  (*it)->initialiseChildren();
2399  (*it)->setState(VP1GeoFlags::CONTRACTED);
2400  VolumeHandle::VolumeHandleListItr itChl((*it)->childrenBegin()),itChlE((*it)->childrenEnd());
2401 
2402  // loop over second level children (i.e., 'NSW_sTGC', 'NSW_MM')
2403  for (;itChl!=itChlE;++itChl) {
2404 
2405  bool unzap( reset? true : false );
2406 
2407  if ( !reset ) {
2408  (*itChl)->setState(VP1GeoFlags::ZAPPED);
2409  if ( (stgc) && (*itChl)->hasName("NSW_sTGC") ) {
2410  unzap = true;
2411  //m_d->showPixelModules(*itChl);
2412  } else if ( (mm) && (*itChl)->hasName("NSW_MM") ) {
2413  unzap = true;
2414  //m_d->showPixelModules(*itChl);
2415  } else if ( (passiveSpacer) && (*itChl)->hasName("NSW_Spacer") ) {
2416  unzap = true;
2417  } else if ( (passiveStructure) && (*itChl)->hasName("NSW_Aluminum_Structure_and_HUB") ) {
2418  unzap = true;
2419  } else if ( (passiveAPlate) && (*itChl)->hasName("A_Plate") ) {
2420  unzap = true;
2421  }
2422  }
2423  if (unzap) {
2424  (*itChl)->setState(VP1GeoFlags::EXPANDED);
2425  }
2426  }
2427  (*it)->setState(VP1GeoFlags::EXPANDED);
2428  }
2429 
2432 
2433  if (save) {
2434  m_d->sceneroot->enableNotify(true);
2435  m_d->sceneroot->touch();
2436  }
2437 }

◆ autoAdaptPixelsOrSCT

void VP1GeometrySystem::autoAdaptPixelsOrSCT ( bool  pixel,
bool  brl,
bool  ecA,
bool  ecC,
bool  bcmA,
bool  bcmC 
)
protectedslot

Definition at line 2247 of file VP1GeometrySystem.cxx.

2248 {
2249  #ifndef BUILDVP1LIGHT
2251  return;
2252  #endif
2254 
2255  bool bcm(bcmA||bcmC);
2256  bool ec(ecA||ecC);
2257 
2259  //Find subsystem:
2260  Imp::SubSystemInfo* subsys(0);
2261  for (Imp::SubSystemInfo*si : m_d->subsysInfoList) {
2262  if (si->flag == subSysFlag) {
2263  subsys = si;
2264  break;
2265  }
2266  }
2267  if (!subsys) {
2268  message("AutoAdaptPixelsOrSCT Error: Could not find subsystem");
2269  return;
2270  }
2271 
2272 
2274  //Abort if corresponding subsystem is not built:
2275  if (!subsys->isbuilt) {
2276  VP1Msg::messageDebug("AutoAdaptPixelsOrSCT: Aborting since subsystem geometry not built yet");
2277  return;//Disabling now due to phi-sector problems if "click some phi sectors"->"adapt pixel"->"turn on pixel"
2278  }
2279  bool save = m_d->sceneroot->enableNotify(false);
2281  VolumeHandle::VolumeHandleListItr it(subsys->vollist.begin()),itE(subsys->vollist.end());
2282 
2283  if (pixel) {
2284  // --> Pixel
2285  for (;it!=itE;++it) {
2286  (*it)->initialiseChildren();
2287  (*it)->setState(VP1GeoFlags::CONTRACTED);
2288  VolumeHandle::VolumeHandleListItr itChl((*it)->childrenBegin()),itChlE((*it)->childrenEnd());
2289  for (;itChl!=itChlE;++itChl) {
2290  bool unzap(false);
2291  (*itChl)->setState(VP1GeoFlags::ZAPPED);
2293  if (brl&&(*itChl)->hasName("barrelLog")) {
2294  unzap = true;
2295  m_d->showPixelModules(*itChl);
2296  } else if ((ec)&&(*itChl)->hasName("EndCapLog")) {
2297  if (((*itChl)->isPositiveZ()?ecA:ecC)) {
2298  m_d->showPixelModules(*itChl);
2299  unzap = true;
2300  }
2301  } else if (bcm&&(*itChl)->hasName("bcmModLog")) {
2302  if (((*itChl)->isPositiveZ()?bcmA:bcmC)) {
2303  (*itChl)->reset();
2304  (*itChl)->setState(VP1GeoFlags::EXPANDED);
2305  }
2306  }
2307  } else {
2308  if ((*itChl)->hasName("ITkPixelDetector")) {
2309  m_d->showITkPixelModules(*itChl, brl, ecA, ecC);
2310  unzap = true;
2311  }
2312  }
2313  if (unzap)
2314  (*itChl)->setState(VP1GeoFlags::EXPANDED);
2315  }
2316  (*it)->setState(VP1GeoFlags::EXPANDED);
2317  }
2318  } else {
2319  // --> SCT
2320  for (;it!=itE;++it) {
2321  (*it)->initialiseChildren();
2322  (*it)->setState(VP1GeoFlags::CONTRACTED);
2323  bool unzap(false);
2324  (*it)->setState(VP1GeoFlags::ZAPPED);
2326  if (brl&&(*it)->hasName("SCT_Barrel")) {
2327  unzap = true;
2329  } else if (ecA&&(*it)->hasName("SCT_ForwardA")) {
2330  unzap = true;
2332  } else if (ecC&&(*it)->hasName("SCT_ForwardC")) {
2333  unzap = true;
2335  }
2336  } else {
2337  m_d->showITkStripModules(*it, brl, ecA, ecC);
2338  unzap=true;
2339  }
2340  if (unzap)
2341  (*it)->setState(VP1GeoFlags::EXPANDED);
2342  }
2343  }
2346  if (save) {
2347  m_d->sceneroot->enableNotify(true);
2348  m_d->sceneroot->touch();
2349  }
2350 }

◆ autoExpandByVolumeOrMaterialName

void VP1GeometrySystem::autoExpandByVolumeOrMaterialName ( bool  bymatname,
const QString &  targetname 
)
protectedslot

Definition at line 2058 of file VP1GeometrySystem.cxx.

2059 {
2060  if (targetname.isEmpty()) {
2061  VP1Msg::messageDebug("targetname is empty.");
2062  return;
2063  }
2064 
2065  messageVerbose("Auto expansions of visible volumes requested. Target all volumes with "
2066  +str(bymatname?"material name":"name")+" matching "+targetname);
2067 
2068  QRegExp selregexp(targetname,Qt::CaseSensitive,QRegExp::Wildcard);
2069 
2070  std::vector<std::pair<VolumeHandle::VolumeHandleListItr,VolumeHandle::VolumeHandleListItr> > roothandles;
2071  m_d->volumetreemodel->getRootHandles(roothandles);
2073 
2074  bool save = m_d->sceneroot->enableNotify(false);
2076 
2077  deselectAll();
2078 
2079  for (unsigned i = 0; i<roothandles.size();++i) {
2080  it = roothandles.at(i).first;
2081  itE = roothandles.at(i).second;
2082  for(;it!=itE;++it)
2083  m_d->expandVisibleVolumesRecursively(*it,selregexp,bymatname);
2084  }
2085 
2088  if (save) {
2089  m_d->sceneroot->enableNotify(true);
2090  m_d->sceneroot->touch();
2091  }
2092 }

◆ autoIconifyByVolumeOrMaterialName

void VP1GeometrySystem::autoIconifyByVolumeOrMaterialName ( bool  bymatname,
const QString &  targetname 
)
protectedslot

Definition at line 2138 of file VP1GeometrySystem.cxx.

2139 {
2140  if (targetname.isEmpty()) {
2141  VP1Msg::messageDebug("targetname is empty.");
2142  return;
2143  }
2144 
2145  messageVerbose("Auto iconification/zapping of visible volumes requested. Target all volumes with "
2146  +str(bymatname?"material name":"name")+" matching "+targetname);
2147 
2148  QRegExp selregexp(targetname,Qt::CaseSensitive,QRegExp::Wildcard);
2149 
2150  std::vector<std::pair<VolumeHandle::VolumeHandleListItr,VolumeHandle::VolumeHandleListItr> > roothandles;
2151  m_d->volumetreemodel->getRootHandles(roothandles);
2153 
2154  bool save = m_d->sceneroot->enableNotify(false);
2156 
2157  deselectAll();
2158 
2159  for (unsigned i = 0; i<roothandles.size();++i) {
2160  it = roothandles.at(i).first;
2161  itE = roothandles.at(i).second;
2162  for(;it!=itE;++it)
2163  m_d->iconifyVisibleVolumesRecursively(*it,selregexp,bymatname);
2164  }
2165 
2168  if (save) {
2169  m_d->sceneroot->enableNotify(true);
2170  m_d->sceneroot->touch();
2171  }
2172 }

◆ buildController()

QWidget * VP1GeometrySystem::buildController ( )
virtual

Reimplemented from IVP13DSystemSimple.

Definition at line 384 of file VP1GeometrySystem.cxx.

385 {
386  message("VP1GeometrySystem::buildController");
387 
388  m_d->controller = new GeoSysController(this);
389 
391 
392 
393  connect(m_d->controller,SIGNAL(showVolumeOutLinesChanged(bool)),this,SLOT(setShowVolumeOutLines(bool)));
395  connect(m_d->controller,SIGNAL(saveMaterialsToFile(QString,bool)),this,SLOT(saveMaterialsToFile(QString,bool)));
396  connect(m_d->controller,SIGNAL(loadMaterialsFromFile(QString)),this,SLOT(loadMaterialsFromFile(QString)));
397 
398  connect(m_d->controller,SIGNAL(transparencyChanged(float)),this,SLOT(updateTransparency()));
402  this,SLOT(volumeResetRequested(VolumeHandle*)));
404  connect(m_d->controller,SIGNAL(muonChamberAdaptionStyleChanged(VP1GeoFlags::MuonChamberAdaptionStyleFlags)),
405  this,SLOT(adaptMuonChambersStyleChanged()));
406  connect(m_d->controller,SIGNAL(autoExpandByVolumeOrMaterialName(bool,QString)),this,SLOT(autoExpandByVolumeOrMaterialName(bool,QString)));
407  connect(m_d->controller,SIGNAL(autoIconifyByVolumeOrMaterialName(bool,QString)),this,SLOT(autoIconifyByVolumeOrMaterialName(bool,QString)));
409  connect(m_d->controller,SIGNAL(autoAdaptPixelsOrSCT(bool,bool,bool,bool,bool,bool)),this,SLOT(autoAdaptPixelsOrSCT(bool,bool,bool,bool,bool,bool)));
410  connect(m_d->controller,SIGNAL(autoAdaptMuonNSW(bool,bool,bool,bool,bool,bool)),this,SLOT(autoAdaptMuonNSW(bool, bool,bool,bool,bool,bool)));
411  connect(m_d->controller,SIGNAL(resetSubSystems(VP1GeoFlags::SubSystemFlags)),this,SLOT(resetSubSystems(VP1GeoFlags::SubSystemFlags)));
412 
413  connect(m_d->controller,SIGNAL(labelsChanged(int)),this,SLOT(setLabels(int)));
414  connect(m_d->controller,SIGNAL(labelPosOffsetChanged(QList<int>)),this,SLOT(setLabelPosOffsets(QList<int>)));
416 
417 
418  /* This is where we define the available different subsystems and their location in the geomodel tree.
419  *
420  * if the reg expr does not match any volume, the corresponding subsystem checkbox in the Geo GUI gets disabled.
421  *
422  * syntax: addSubSystem(VP1GeoFlags::SubSystemFlag&, // the associated system flag
423  QString& treetopregexp, // the regular expr for the top/root name of the main sub-detector system
424  QString& childrenregexp="", // the reg expr for the children of the main sub-detector
425  std::string& matname="", // a name we choose for displaying in VP1
426  bool negatetreetopregexp = false, // if we want to negate the top reg expr
427  bool negatechildrenregexp = false); // if we want to negate the children reg expr
428  const QString& grandchildrenregexp="", // the regex for granchildren of the main sub-detector
429  bool negategrandchildrenregexp = false // wheter we want to negate teh granchildren regex
430  */
431 
433  m_d->addSubSystem( VP1GeoFlags::Pixel,"ITkPixel", "", "ITkPixel");
434  m_d->addSubSystem( VP1GeoFlags::SCT,"ITkStrip", "", "ITkStrip");
435  } else {
438  }
440  m_d->addSubSystem( VP1GeoFlags::InDetServMat,"InDetServMat");
441  m_d->addSubSystem( VP1GeoFlags::LAr, ".*LAr.*");
443  m_d->addSubSystem( VP1GeoFlags::CavernInfra,"CavernInfra");
444  m_d->addSubSystem( VP1GeoFlags::BeamPipe,"BeamPipe");
445  m_d->addSubSystem( VP1GeoFlags::LUCID,".*Lucid.*");
446  m_d->addSubSystem( VP1GeoFlags::ZDC,".*ZDC.*");
447  m_d->addSubSystem( VP1GeoFlags::ALFA,".*ALFA.*");
448  m_d->addSubSystem( VP1GeoFlags::AFP,".*AFP.*");
449  m_d->addSubSystem( VP1GeoFlags::ForwardRegion,".*ForwardRegion.*");
450 
451  //The muon systems require special treatment, since we want to
452  //cherrypick below the treetop (this is the main reason for a lot
453  //of the ugly stuff in this class):
454  m_d->addSubSystem( VP1GeoFlags::MuonEndcapStationCSC,"Muon","CS.*","CSC");
455  m_d->addSubSystem( VP1GeoFlags::MuonEndcapStationTGC,"Muon","T(1|2|3|4).*","TGC");
456  m_d->addSubSystem( VP1GeoFlags::MuonEndcapStationMDT,"Muon","(EI|EM|EO|EE).*","EndcapMdt");
457  m_d->addSubSystem( VP1GeoFlags::MuonEndcapStationNSW,"Muon",".*ANON.*","MuonNSW",false, false, "NewSmallWheel.*");
458 
459  m_d->addSubSystem( VP1GeoFlags::MuonBarrelStationInner,"Muon","(BI|BEE).*","BarrelInner");
460  m_d->addSubSystem( VP1GeoFlags::MuonBarrelStationMiddle,"Muon","BM.*","BarrelMiddle");
461  m_d->addSubSystem( VP1GeoFlags::MuonBarrelStationOuter,"Muon","BO.*","BarrelOuter");
462 
463  //This last one is even more horrible. We want everything from the Muon treetop that is NOT included elsewhere:
464 // m_d->addSubSystem( VP1GeoFlags::MuonToroidsEtc,"Muon","(CS|T1|T2|T3|T4|EI|EM|EO|EE|BI|BEE|BM|BO).*","Muon",false,true);
465 
466  // Toroid
467  m_d->addSubSystem( VP1GeoFlags::BarrelToroid,"Muon",".*ANON.*","BarrelToroid", false, false, "BAR_Toroid.*");
468  m_d->addSubSystem( VP1GeoFlags::ToroidECA,"Muon",".*ANON.*","ToroidECA", false, false, "ECT_Toroids.*");
469 // m_d->addSubSystem( VP1GeoFlags::ToroidECC,"Muon",".*ANON.*","ToroidECC", false, false, "ECT_Toroids");
470 
471  // Muon Feet
472  m_d->addSubSystem( VP1GeoFlags::MuonFeet,"Muon",".*ANON.*","MuonFeet", false, false, "Feet.*");
473 
474  // Muon shielding
475  m_d->addSubSystem( VP1GeoFlags::MuonShielding,"Muon",".*ANON.*","Shielding", false, false, "(JDSH|JTSH|JFSH).*");
476 
477 
478  // All muon stuff --> this will be linked to the "Services" checkbox in the GUI
479  // m_d->addSubSystem( VP1GeoFlags::MuonToroidsEtc,"Muon","(CS|T1|T2|T3|T4|EI|EM|EO|EE|BI|BEE|BM|BO).*","MuonEtc",false,true);
480  m_d->addSubSystem( VP1GeoFlags::MuonToroidsEtc,"Muon",".*(CS|T1|T2|T3|T4|EI|EM|EO|EE|BI|BEE|BM|BO).*","MuonEtc",false,true,"(ECT_Toroids|BAR_Toroid|Feet|NewSmallWheel|JDSH|JTSH|JFSH).*",true);
481 
482  // m_d->addSubSystem( VP1GeoFlags::MuonToroidsEtc,"Muon","*.Feet.*","MuonEtc");
483 
484  //This one MUST be added last. It will get slightly special treatment in various places!
486 
487 
488  //Setup models/views for volume tree browser and zapped volumes list:
490  m_d->controller->volumeTreeBrowser()->header()->hide();
491  m_d->controller->volumeTreeBrowser()->uniformRowHeights();
493 
494  return m_d->controller;
495 }

◆ buildEventSceneGraph()

void VP1GeometrySystem::buildEventSceneGraph ( StoreGateSvc ,
SoSeparator *   
)
inlinevirtual

Implements IVP13DSystemSimple.

Definition at line 55 of file VP1GeometrySystem.h.

55 {}

◆ buildExtraDisplayWidget()

virtual QWidget* IVP13DSystem::buildExtraDisplayWidget ( )
inlinevirtualinherited

Definition at line 106 of file IVP13DSystem.h.

106 { return 0; }

◆ buildPermanentSceneGraph()

void VP1GeometrySystem::buildPermanentSceneGraph ( StoreGateSvc detstore,
SoSeparator *  root 
)
virtual

Reimplemented from IVP13DSystemSimple.

Definition at line 512 of file VP1GeometrySystem.cxx.

513 {
514  m_d->sceneroot = root;
515 
516  #ifndef BUILDVP1LIGHT
518  message("Error: GeoModel not configured properly in job.");
519  return;
520  }
521 
522  //Get the world volume:
523  const GeoModelExperiment * theExpt;
524  if (!VP1SGAccessHelper(this,true).retrieve(theExpt,"ATLAS")) {
525  message("Error: Could not retrieve the ATLAS GeoModelExperiment from detector store");
526  return;
527  }
528  #endif
529 
530  #ifdef BUILDVP1LIGHT
531  GeoModelExperiment* theExpt = m_d->getGeometry();
532  #endif
533  PVConstLink world(theExpt->getPhysVol());
534 
535  if (!m_d->m_textSep) {
536  // FIXME!
537  // std::cout<<"Making new Text sep"<<std::endl;
538  m_d->m_textSep = new SoSeparator;
539  m_d->m_textSep->setName("TextSep");
540  m_d->m_textSep->ref();
541  }
542  m_d->sceneroot->addChild(m_d->m_textSep);
543 
544  // FIXME - what if font is missing?
545  SoFont *myFont = new SoFont;
546  myFont->name.setValue("Arial");
547  myFont->size.setValue(12.0);
548  m_d->m_textSep->addChild(myFont);
549 
550  bool save = root->enableNotify(false);
551 
552  //Catch keyboard events:
553  SoEventCallback *catchEvents = new SoEventCallback();
554  catchEvents->addEventCallback(SoKeyboardEvent::getClassTypeId(),Imp::catchKbdState, m_d);
555  root->addChild(catchEvents);
556 
557  root->addChild(m_d->controller->drawOptions());
558  root->addChild(m_d->controller->pickStyle());
559 
560  if(VP1Msg::debug()){
561  qDebug() << "Configuring the default systems... - subsysInfoList len:" << (m_d->subsysInfoList).length();
562  }
563  // we switch on the systems flagged to be turned on at start
564  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList)
565  {
566  VP1Msg::messageDebug("Switching on this system: " + QString::fromStdString(subsys->matname) + " - " + subsys->flag);
567  bool on(m_d->initialSubSystemsTurnedOn & subsys->flag);
568  subsys->checkbox->setChecked( on );
569  subsys->checkbox->setEnabled(false);
570  subsys->checkbox->setToolTip("This sub-system is not available");
571  connect(subsys->checkbox,SIGNAL(toggled(bool)),this,SLOT(checkboxChanged()));
572  }
573 
574  //Locate geometry info for the various subsystems, and add the info as appropriate:
575 
577 
578  if(VP1Msg::debug()){
579  qDebug() << "Looping on volumes from the input GeoModel...";
580  }
581  GeoVolumeCursor av(world);
582  while (!av.atEnd()) {
583 
584  std::string name = av.getName();
585  if(VP1Msg::debug()){
586  qDebug() << "volume name:" << QString::fromStdString(name);
587  }
588 
589  // DEBUG
590  VP1Msg::messageDebug("DEBUG: Found GeoModel treetop: "+QString(name.c_str()));
591 
592  //Let us see if we recognize this volume:
593  bool found = false;
594  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList) {
595  if (subsys->negatetreetopregexp!=subsys->geomodeltreetopregexp.exactMatch(name.c_str()))
596  {
597  if (subsys->checkbox==checkBoxOther&&found) {
598  continue;//The "other" subsystem has a wildcard which matches everything - but we only want stuff that is nowhere else.
599  }
600 
601  if(VP1Msg::debug()){
602  qDebug() << (subsys->geomodeltreetopregexp).pattern() << subsys->geomodeltreetopregexp.exactMatch(name.c_str()) << subsys->negatetreetopregexp;
603  qDebug() << "setting 'found' to TRUE for pattern:" << (subsys->geomodeltreetopregexp).pattern();
604  }
605  found = true;
606  //We did... now, time to extract info:
607  subsys->treetopinfo.resize(subsys->treetopinfo.size()+1);
608  subsys->treetopinfo.back().pV = av.getVolume();
609  subsys->treetopinfo.back().xf = Amg::EigenTransformToCLHEP(av.getTransform());
610  subsys->treetopinfo.back().volname = av.getName();
611 
612  //Add a switch for this system (turned off for now):
613  SoSwitch * sw = new SoSwitch();
614  //But add a separator on top of it (for caching):
615  subsys->soswitch = sw;
616  if (sw->whichChild.getValue() != SO_SWITCH_NONE)
617  sw->whichChild = SO_SWITCH_NONE;
618  SoSeparator * sep = new SoSeparator;
619  sep->addChild(sw);
620  root->addChild(sep);
621  //Enable the corresponding checkbox:
622  subsys->checkbox->setEnabled(true);
623  subsys->checkbox->setToolTip("Toggle the display of the "+subsys->checkbox->text()+" sub system");
624  //NB: Dont break here - several systems might share same treetop!
625  // break;
626  }
627  }
628  if (!found) {
629  message("Warning: Found unexpected GeoModel treetop: "+QString(name.c_str()));
630  }
631 
632  av.next(); // increment volume cursor.
633  }
634 
635  //Hide other cb if not needed:
636  if (!checkBoxOther->isEnabled())
637  checkBoxOther->setVisible(false);
638 
639  //Build the geometry for those (available) subsystems that starts out being turned on:
640  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList) {
641  if (!subsys->soswitch||!subsys->checkbox->isChecked())
642  continue;
643  m_d->buildSystem(subsys);
644  //Enable in 3D view:
645  if (subsys->soswitch->whichChild.getValue() != SO_SWITCH_ALL)
646  subsys->soswitch->whichChild = SO_SWITCH_ALL;
647  //Enable in tree browser:
648  m_d->volumetreemodel->enableSubSystem(subsys->flag);
649  // new ModelTest(m_d->volumetreemodel, m_d->treeView_volumebrowser);
650  }
651  if (!m_d->restoredTopvolstates.isEmpty()) {
653  m_d->restoredTopvolstates.clear();
654  }
656  root->enableNotify(save);
657  if (save)
658  root->touch();
659 
660 
663 
664  //To ensure we emit it once upon startup:
665  QTimer::singleShot(0, this, SLOT(emit_appropriateMDTProjectionsChanged()));
666 }

◆ channel()

IVP1ChannelWidget * IVP1System::channel ( ) const
privateinherited

Definition at line 275 of file IVP1System.cxx.

276 {
277  if (VP1Msg::verbose()&&!m_d->channel){
278  messageVerbose("WARNING channel() returning NULL");
279  }
280  assert(m_d->channel);
281  return m_d->channel;
282 }

◆ checkboxChanged

void VP1GeometrySystem::checkboxChanged ( )
protectedslot

Definition at line 774 of file VP1GeometrySystem.cxx.

775 {
776  QCheckBox * cb = static_cast<QCheckBox*>(sender());
777  Imp::SubSystemInfo * subsys(0);
778  for (Imp::SubSystemInfo * ss : m_d->subsysInfoList) {
779  if (cb==ss->checkbox) {
780  subsys=ss;
781  break;
782  }
783  }
784  if (!subsys) {
785  message("ERROR: Unknown checkbox");
786  return;
787  }
788 
789  SoSwitch * sw = subsys->soswitch;
790  assert(sw);
791  if (cb->isChecked()) {
792  SbBool save = sw->enableNotify(false);
793  if (sw->getNumChildren()==0) {
794  m_d->buildSystem(subsys);
796  }
797  if (sw->whichChild.getValue() != SO_SWITCH_ALL)
798  sw->whichChild = SO_SWITCH_ALL;
799  sw->enableNotify(save);
800  //Enable in tree browser:
801  m_d->volumetreemodel->enableSubSystem(subsys->flag);
802  // new ModelTest(m_d->volumetreemodel, m_d->treeView_volumebrowser);
803  if (save)
804  sw->touch();
805  } else {
806  if (sw->whichChild.getValue() != SO_SWITCH_NONE)
807  sw->whichChild = SO_SWITCH_NONE;
808  m_d->volumetreemodel->disableSubSystem(subsys->flag);
809  }
810 }

◆ contact_info()

const QString & IVP1System::contact_info ( ) const
inherited

Definition at line 62 of file IVP1System.cxx.

63 {
64  return m_d->contact_info;
65 }

◆ controllerWidget()

QWidget * IVP1System::controllerWidget ( )
inherited

Definition at line 202 of file IVP1System.cxx.

202  {
203  if (VP1Msg::verbose()) {
204  messageVerbose("controllerWidget()");
205  messageVerbose("registerController m_d->state==ERASED = "+QString(m_d->state==ERASED?"true":"false"));
206  messageVerbose("registerController m_d->state==REFRESHED = "+QString(m_d->state==REFRESHED?"true":"false"));
207  }
208  assert(m_d->state==REFRESHED||m_d->state==ERASED);
209  return m_d->controller;
210  }

◆ create()

void IVP13DSystemSimple::create ( StoreGateSvc detstore)
privatevirtualinherited

Implements IVP1System.

Definition at line 133 of file IVP13DSystemSimple.cxx.

134 {
135  if(VP1Msg::verbose()){
136  messageVerbose("IVP13DSystemSimple create");
137  }
138  assert(!m_d->wasrefreshed);
139  assert(!m_d->wascreated);
140  ensureBuildController();//TODO: Move to refresh.
141  m_d->wascreated=true;
142  m_d->wasrefreshed=false;
143 }

◆ deleteController()

void IVP1System::deleteController ( )
privateinherited

Definition at line 213 of file IVP1System.cxx.

214 {
215  if (VP1Msg::verbose()){
216  messageVerbose("deleteController()");
217  }
218  if (m_d->controller)
219  m_d->controller->deleteLater();
220  m_d->controller = 0;
221 }

◆ deselectAll()

void IVP13DSystem::deselectAll ( SoCooperativeSelection exception_sel = 0)
virtualinherited

Reimplemented in VP1PrepRawDataSystem.

Definition at line 331 of file IVP13DSystem.cxx.

332 {
334  for (it = Imp::selection2system.begin(); it!=itE;++it) {
335  if (it->second!=this)
336  continue;
337  if (it->first!=exception_sel) {
338  if (it->first->policy.getValue()!=SoCooperativeSelection::SINGLE) {
339  Imp::start_changeselection(this, it->first);
340  it->first->deselectAll();
341  Imp::finished_changeselection(this, it->first);
342  } else {
343  if (it->first->getList()->getLength()==1) {
344  Imp::start_changeselection(this, it->first);
345  SoPath * path = static_cast<SoPath*>(it->first->getList()->get(0));
346  Imp::made_deselection(it->first,path);
347  it->first->deselectAll();
348  Imp::finished_changeselection(this, it->first);
349  }
350  }
351  }
352  }
353 }

◆ detectorStore()

StoreGateSvc * IVP1System::detectorStore ( ) const
inherited

Definition at line 318 of file IVP1System.cxx.

319 {
321 }

◆ disallowUpdateGUI()

void IVP1System::disallowUpdateGUI ( )
privateinherited

Definition at line 250 of file IVP1System.cxx.

251 {
252  m_d->allowupdategui=false;
253 }

◆ emit_appropriateMDTProjectionsChanged

void VP1GeometrySystem::emit_appropriateMDTProjectionsChanged ( )
protectedslot

Definition at line 1591 of file VP1GeometrySystem.cxx.

1592 {
1593  if (!m_d->controller) {
1594  message("emit_appropriateMDTProjectionsChanged called before controller built.");
1595  return;
1596  }
1597  VP1GeoFlags::MuonChamberAdaptionStyleFlags f(m_d->controller->muonChamberAdaptionStyle());
1598  bool option_openmdtchambers = f & VP1GeoFlags::OpenMDTChambers;
1599  bool option_hidetubes = f & VP1GeoFlags::HideMDTTubes;
1600  int i (option_openmdtchambers?(option_hidetubes?0:1):2);
1601  if ( m_d->last_appropriatemdtprojections != i ) {
1604  }
1605 }

◆ enableMuonChamberLabels()

void VP1GeometrySystem::enableMuonChamberLabels ( bool  t0s,
bool  hits 
)

first is t0s, 2nd is hits

Definition at line 2882 of file VP1GeometrySystem.cxx.

2882  {
2884 }

◆ ensureBuildController()

void IVP13DSystemSimple::ensureBuildController ( )
inherited

Definition at line 90 of file IVP13DSystemSimple.cxx.

91 {
92  if (m_d->controllerBuilt)
93  return;
94  m_d->controllerBuilt=true;
95  if(VP1Msg::verbose()){
96  messageVerbose("IVP13DSystemSimple build controller");
97  }
98  QWidget * controller = buildController();
99  if (controller)
100  registerController(controller);
101  if(VP1Msg::verbose()){
102  messageVerbose("IVP13DSystemSimple controller was = "+str(controller));
103  }
104 }

◆ erase()

void IVP13DSystemSimple::erase ( )
privatevirtualinherited

Implements IVP1System.

Definition at line 173 of file IVP13DSystemSimple.cxx.

174 {
175  if(VP1Msg::verbose()){
176  messageVerbose("IVP13DSystemSimple::erase() start");
177  }
178  assert(m_d->wascreated);
179  assert(m_d->wasrefreshed);
180 
181  bool saveE = m_d->rootE->enableNotify(false);
182 
183  systemerase();
184  if(VP1Msg::verbose()){
185  messageVerbose("IVP13DSystemSimple::erase() Removing all event objects from scene");
187  }
188  m_d->rootE->removeAllChildren();
189 
190  if (saveE) {
191  m_d->rootE->enableNotify(true);
192  m_d->rootE->touch();
193  }
194 
195  m_d->wasrefreshed=false;
196  if(VP1Msg::verbose()){
197  messageVerbose("IVP13DSystemSimple::erase() end");
198  }
199 }

◆ eventStore()

StoreGateSvc * IVP1System::eventStore ( ) const
inherited

Definition at line 312 of file IVP1System.cxx.

313 {
314  return VP1AthenaPtrs::eventStore();
315 }

◆ getCameraList()

std::set< SoCamera * > IVP13DSystem::getCameraList ( )
inherited

Definition at line 395 of file IVP13DSystem.cxx.

396 {
397  std::set<SoCamera*> cameralist = m_d->staticcameras;
398  std::set<SoQtViewer*>::const_iterator it, itE=m_d->viewers.end();
399  for (it=m_d->viewers.begin();it!=itE;++it) {
400  SoCamera*cam = (*it)->getCamera();
401  if (cam)
402  cameralist.insert(cam);
403  }
404 
405  //m_d->camerasfromviewer
406  return cameralist;
407 }

◆ getSceneGraph()

SoSeparator * IVP13DSystemSimple::getSceneGraph ( ) const
privatevirtualinherited

Implements IVP13DSystem.

Definition at line 127 of file IVP13DSystemSimple.cxx.

128 {
129  return static_cast<SoSeparator*>(m_d->root);
130 }

◆ inactiveSystemTurnedActive

void IVP1System::inactiveSystemTurnedActive ( )
signalinherited

◆ information()

const QString & IVP1System::information ( ) const
inherited

Definition at line 56 of file IVP1System.cxx.

57 {
58  return m_d->information;
59 }

◆ isRefreshing()

bool IVP1System::isRefreshing ( )
privateinherited

Definition at line 108 of file IVP1System.cxx.

109 {
110  return m_d->refreshing;
111 }

◆ itemFromSystemSelected

void IVP13DSystem::itemFromSystemSelected ( )
signalinherited

◆ loadMaterialsFromFile

void VP1GeometrySystem::loadMaterialsFromFile ( const QString &  filename)
protectedslot

Definition at line 2808 of file VP1GeometrySystem.cxx.

2809 {
2810  if (filename.isEmpty())
2811  return;
2812  QFileInfo fi(filename);
2813  if (!fi.exists()) {
2814  QMessageBox::critical(0, "Error - file does not exists: "+filename,
2815  "File does not exists: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2816  return;
2817  }
2818  if (!fi.isReadable()) {
2819  QMessageBox::critical(0, "Error - file is not readable: "+filename,
2820  "File is not readable: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2821  return;
2822  }
2823  //open file
2824  QFile file(filename);
2825  if (!file.open(QIODevice::ReadOnly)) {
2826  QMessageBox::critical(0, "Error - problems opening file "+filename,
2827  "Problems opening file: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2828  return;
2829  }
2830  QByteArray byteArray64;
2831  QDataStream infile(&file);
2832  infile >> byteArray64;
2833  QByteArray byteArray = qUncompress(QByteArray::fromBase64(byteArray64));
2834 
2835  VP1Deserialise s(byteArray,this);
2836  if (s.version()!=0) {
2837  QMessageBox::critical(0, "Error - File in wrong format "+filename,
2838  "File in wrong format: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2839  return;
2840  }
2841  QString txtbegin, txtend;
2842  QByteArray baDet, baMat, baVol;
2843  txtbegin = s.restoreString();
2844  baDet = s.restoreByteArray();
2845  baMat = s.restoreByteArray();
2846  baVol = s.restoreByteArray();
2847  txtend = s.restoreString();
2848  s.disableUnrestoredChecks();
2849  if (txtbegin!="VP1GeoMaterialsBegin"||txtend!="VP1GeoMaterialsEnd") {
2850  QMessageBox::critical(0, "Error - File in wrong format "+filename,
2851  "File in wrong format: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2852  return;
2853  }
2854 
2856  m_d->detVisAttributes->applyState(baDet);
2857  m_d->matVisAttributes->applyState(baMat);
2858  m_d->volVisAttributes->applyState(baVol);
2859 
2863 }

◆ message() [1/3]

void IVP1System::message ( const QString &  str) const
inherited

Definition at line 336 of file IVP1System.cxx.

337 {
338  if (receivers(SIGNAL(sysmessage(QString))) > 0){
339  sysmessage(str);
340  }
341  else{
342  std::cout<<VP1Msg::prefix_msg()<<" ["<<m_d->name.toStdString()<<"]: "<<str.toStdString()<<std::endl;
343  }
344 }

◆ message() [2/3]

void IVP1System::message ( const QString &  addtostart,
const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 400 of file IVP1System.cxx.

401 {
402  if (addtostart.isEmpty()) {
403  message(l,addtoend);
404  return;
405  }
406  if (addtoend.isEmpty()) {
407  for (QString s : l)
408  message(addtostart+s);
409  } else {
410  for (QString s : l)
411  message(addtostart+s+addtoend);
412  }
413 }

◆ message() [3/3]

void IVP1System::message ( const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 362 of file IVP1System.cxx.

363 {
364  if (addtoend.isEmpty()) {
365  for (QString s : l)
366  message(s);
367  } else {
368  for (QString s : l)
369  message(s+addtoend);
370  }
371 }

◆ messageDebug() [1/3]

void IVP1System::messageDebug ( const QString &  str) const
inherited

Definition at line 347 of file IVP1System.cxx.

348 {
349  if (VP1Msg::debug())
350  std::cout<<VP1Msg::prefix_debug()<<" ["<<m_d->name.toStdString()<<"]: "<<str.toStdString()<<std::endl;
351 }

◆ messageDebug() [2/3]

void IVP1System::messageDebug ( const QString &  addtostart,
const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 416 of file IVP1System.cxx.

417 {
418  if (addtostart.isEmpty()) {
419  messageDebug(l,addtoend);
420  return;
421  }
422  if (addtoend.isEmpty()) {
423  for (QString s : l)
424  messageDebug(addtostart+s);
425  } else {
426  for (QString s : l)
427  messageDebug(addtostart+s+addtoend);
428  }
429 }

◆ messageDebug() [3/3]

void IVP1System::messageDebug ( const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 374 of file IVP1System.cxx.

375 {
376  if (addtoend.isEmpty()) {
377  for (QString s : l)
378  messageDebug(s);
379  } else {
380  for (QString s : l)
381  messageDebug(s+addtoend);
382  }
383 }

◆ messageVerbose() [1/3]

void IVP1System::messageVerbose ( const QString &  str) const
inherited

Definition at line 354 of file IVP1System.cxx.

355 {
356  if (VP1Msg::verbose())
357  std::cout<<VP1Msg::prefix_verbose()<<" ["<<m_d->name.toStdString()<<"]: "<<str.toStdString()<<std::endl;
358 }

◆ messageVerbose() [2/3]

void IVP1System::messageVerbose ( const QString &  addtostart,
const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 432 of file IVP1System.cxx.

433 {
434  if (!VP1Msg::verbose())
435  return;
436  if (addtostart.isEmpty()) {
437  messageVerbose(l,addtoend);
438  return;
439  }
440  if (addtoend.isEmpty()) {
441  for (QString s : l)
442  messageVerbose(addtostart+s);
443  } else {
444  for (QString s : l)
445  messageVerbose(addtostart+s+addtoend);
446  }
447 }

◆ messageVerbose() [3/3]

void IVP1System::messageVerbose ( const QStringList &  l,
const QString &  addtoend = "" 
) const
inherited

Definition at line 386 of file IVP1System.cxx.

387 {
388  if (!VP1Msg::verbose())
389  return;
390  if (addtoend.isEmpty()) {
391  for (QString s : l)
392  messageVerbose(s);
393  } else {
394  for (QString s : l)
395  messageVerbose(s+addtoend);
396  }
397 }

◆ muonChamberT0sChanged

void VP1GeometrySystem::muonChamberT0sChanged ( const std::map< GeoPVConstLink, float > &  t0s,
int  index 
)
slot

The map is the dt0 per chamber, plus a label identifier, which by convention (!) is 0=Moore, 1=Muonboy.

Definition at line 2886 of file VP1GeometrySystem.cxx.

2886  {
2887  messageVerbose("muonChamberT0sChanged for this many chambers:"+str(t0s.size()));
2888  if (index>=m_d->chamberT0s.size())
2889  message("ERROR: chamber t0 index out of bounds!");
2890  else
2891  m_d->chamberT0s[index]=&t0s;
2892 }

◆ name()

const QString & IVP1System::name ( ) const
inherited

Definition at line 50 of file IVP1System.cxx.

51 {
52  return m_d->name;
53 }

◆ needErase

void IVP1System::needErase ( )
signalinherited

◆ orientViewToMuonChamber

void VP1GeometrySystem::orientViewToMuonChamber ( const GeoPVConstLink &  chamberPV)
slot

Definition at line 1767 of file VP1GeometrySystem.cxx.

1768 {
1769  if (!m_d->sceneroot)
1770  return;
1771 
1772  //Find relevant muon subsystem info:
1773  Imp::SubSystemInfo * subsys = m_d->chamberPVToMuonSubSystemInfo(chamberPV);
1774  if (!subsys) {
1775  message("Error: Asked to orient view to chamber volume '"
1776  +QString(chamberPV->getLogVol()->getName().c_str())
1777  +"', which doesn't fit the known format of any chamber!");
1778  return;
1779  }
1780 
1781  //Subsystem must be available:
1782  if (!subsys->soswitch) {//NB: Could as well look at checkbox enabled state instead of whether sw pointer is null.
1783  message("Warning: Asked to orient view to muon chamber volume which is not available. Perhaps muon geometry was not built?");
1784  return;
1785  }
1786 
1787  //Find handle for the muon chamber (possibly ensure that relevant muon subsystem is build):
1789  if (itChamber==m_d->muonchambers_pv2handles.end()) {
1790  //Probably the muon relevant muon system was not initialised. Build and try again:
1791  m_d->buildSystem(subsys);
1792  itChamber = m_d->muonchambers_pv2handles.find(chamberPV);
1793  if (itChamber==m_d->muonchambers_pv2handles.end()) {
1794  message("Error: Asked to orient view to chamber volume '"
1795  +QString(chamberPV->getLogVol()->getName().c_str())
1796  +"', but could not find chamber handle!");
1797  return;
1798  }
1799  }
1800  VolumeHandle * chamberHandle = itChamber->second;
1801 
1802  //Figure out if we are MDT, CSC or TGC (if not we print warning and abort);
1803 
1804  std::string name = chamberHandle->getNameStdString();
1805 
1806  bool isCSCOrTGC = name.size()>=2 && ( (name[0]=='C' && name[1]=='S') || (name[0]=='T') );
1807  if (!isCSCOrTGC&&!(name.size()>=1&&(name[0]=='E'||name[0]=='B'))) {
1808  //Neither CSC, TGC or MDT:
1809  message("orientViewToMuonChamber Warning: Not CSC, TGC or MDT station!");
1810  return;
1811  }
1812 
1813  bool save = subsys->soswitch->enableNotify(false);//Disable notifications to avoid chamber flickering in for a moment.
1814 
1815  //If subsystem soswitch is turned off, we turn it on temporarily
1816  int32_t soswitch_val = subsys->soswitch->whichChild.getValue();
1817  if (soswitch_val!=SO_SWITCH_ALL)
1818  subsys->soswitch->whichChild = SO_SWITCH_ALL;
1819 
1820  VP1GeoFlags::VOLSTATE oldChamberState = chamberHandle->state();
1821  chamberHandle->setState(VP1GeoFlags::CONTRACTED);
1822 
1823  SoSeparator * chambersep = chamberHandle->nodeSoSeparator();
1824  if (chambersep) {
1825  std::set<SoCamera*> cameras = getCameraList();
1826  std::set<SoCamera*>::iterator it,itE = cameras.end();
1827  for (it=cameras.begin();it!=itE;++it) {
1828  //Find desired camera orientation (must be parallel to tubes - and
1829  //we choose the one of the possible orientations which is closest to
1830  //current camera orientation - i.e. loop over tubes and try both
1831  //positive and negative directions of each tube.
1832 
1833  SbRotation camrot = (*it)->orientation.getValue();
1834  SbVec3f cameraDir(0, 0, -1); // init to default view direction vector
1835  camrot.multVec(cameraDir, cameraDir);
1836  SbVec3f cameraUpVec(0, 1, 0); // init to default up vector
1837  camrot.multVec(cameraUpVec, cameraUpVec);
1838 
1839  std::pair<SbVec3f,SbVec3f> chamberdirections;
1840  if (isCSCOrTGC) {
1841  //CSC/TGC chamber - look at top TRD shape for directions
1842  chamberdirections = m_d->getClosestCSCOrTGCEdgeDirections(cameraDir,chamberHandle);
1843  } else {
1844  //MDT chamber - look at tubes for direction
1845  chamberdirections = m_d->getClosestMuonDriftTubeDirections(cameraDir,cameraUpVec,chamberHandle);
1846  }
1847  SbVec3f newdirection = - chamberdirections.first;
1848  SbVec3f newup(cameraUpVec);
1849  const float epsilon(0.00001f);
1850  if (m_d->previousAlignedChamberHandle==chamberHandle&&cameraDir.equals(newdirection,epsilon)) {
1851  //If we already zoomed in the direction of the chamber,
1852  //subsequent requests aligns the upvector along the other chamber
1853  //axes.
1854  SbRotation rot(cameraDir,0.5*M_PI);
1855  SbVec3f chambdir1 = chamberdirections.second;
1856  SbVec3f chambdir2,chambdir3,chambdir4;
1857  rot.multVec(chambdir1,chambdir2);
1858  rot.multVec(chambdir2,chambdir3);
1859  rot.multVec(chambdir3,chambdir4);
1860  if (cameraUpVec.equals(chambdir1,epsilon)) {
1861  newup = chambdir2;
1862  } else if (cameraUpVec.equals(chambdir2,epsilon)) {
1863  newup = chambdir3;
1864  } else if (cameraUpVec.equals(chambdir3,epsilon)) {
1865  newup = chambdir4;
1866  } else if (cameraUpVec.equals(chambdir4,epsilon)) {
1867  newup = chambdir1;
1868  } else {
1869  //Take the closest one...
1870  float cos1 = chambdir1.dot(cameraUpVec);
1871  float cos2 = chambdir2.dot(cameraUpVec);
1872  float cos3 = chambdir3.dot(cameraUpVec);
1873  float cos4 = chambdir4.dot(cameraUpVec);
1874  float maxcos = std::max(std::max(cos1,cos2),std::max(cos3,cos4));
1875  if (cos1==maxcos)
1876  newup = chambdir1;
1877  else if (cos2==maxcos)
1878  newup = chambdir2;
1879  else if (cos3==maxcos)
1880  newup = chambdir3;
1881  else
1882  newup = chambdir4;
1883  }
1884  }
1885 
1886  //Zoom to chamber with given orientation - and we make sure the
1887  //chamber is attached while we initiate the zoom (so the camera
1888  //helper can use a boundaryboxaction to find the bounding box):
1889  VP1CameraHelper::animatedZoomToSubTree(*it,m_d->sceneroot,chambersep,1.0, 100.0, 100.0, 1.0,newdirection,newup);
1890  }
1891  }
1892 
1893  chamberHandle->setState(oldChamberState);
1894  if (soswitch_val!=SO_SWITCH_ALL)
1895  subsys->soswitch->whichChild.setValue(soswitch_val);
1896  if (save) {
1897  subsys->soswitch->enableNotify(true);
1898  subsys->soswitch->touch();
1899  }
1900  m_d->previousAlignedChamberHandle=chamberHandle;
1901 
1902 }

◆ plotSpectrum

void VP1GeometrySystem::plotSpectrum ( QStack< QString > &  ,
int  copyNumber = -1 
)
signal

◆ refresh()

void IVP13DSystemSimple::refresh ( StoreGateSvc storegate)
privatevirtualinherited

Implements IVP1System.

Definition at line 146 of file IVP13DSystemSimple.cxx.

147 {
148  assert(m_d->wascreated);
149  assert(!m_d->wasrefreshed);
150 
151  if (m_d->first) {
152  if(VP1Msg::verbose()){
153  messageVerbose("IVP13DSystemSimple first refresh - so calling create methods (i.e. delayed create).");
154  }
156  m_d->first = false;
157  m_d->root->removeChild(m_d->rootR);
159  m_d->root->addChild(m_d->rootR);
160  }
161 
162  m_d->root->removeChild(m_d->rootE);
163  updateGUI();
165  updateGUI();
166  m_d->root->addChild(m_d->rootE);
167 
168  m_d->wasrefreshed=true;
169 
170 }

◆ registerCamera()

void IVP13DSystem::registerCamera ( SoCamera *  camera)
inherited

Definition at line 410 of file IVP13DSystem.cxx.

410  {
411  if (!cam)
412  return;
413  m_d->staticcameras.insert(cam);
414  cam->ref();
415 }

◆ registerController()

void IVP1System::registerController ( QWidget *  w)
protectedinherited

Definition at line 224 of file IVP1System.cxx.

225 {
226  if (VP1Msg::verbose()) {
227  messageVerbose("registerController ");
228  messageVerbose("registerController m_d->canregistercontroller = "+QString(m_d->canregistercontroller?"true":"false"));
229  messageVerbose("registerController m_d->state==CONSTRUCTED = "+QString(m_d->state==CONSTRUCTED?"true":"false"));
230  messageVerbose("registerController m_d->controller==0 = "+QString(m_d->controller==0?"true":"false"));
231  messageVerbose("registerController w!=0 = "+QString(w!=0?"true":"false"));
232  }
234  message("ERROR: Please don't register controllers after create().");
235  if (m_d->state!=CONSTRUCTED)
236  message("ERROR: Please only register controllers in CONSTRUCTED state.");
237  if (!w) {
238  message("ERROR: Attempt to register null controller.");
239  return;
240  }
241  if (m_d->controller) {
242  message("ERROR: Attempt to register controller twice.");
243  return;
244  }
245  m_d->controller = w;
246  w->setParent(0);
247 }

◆ registerSelectionNode()

void IVP13DSystem::registerSelectionNode ( SoCooperativeSelection selection)
inherited

Definition at line 257 of file IVP13DSystem.cxx.

258 {
259  if (!selection) {
260  message("registerSelectionNode Error: NULL selection pointer!");
261  return;
262  }
264  message("registerSelectionNode Error: Trying to register selection node more than once!");
265  return;
266  }
267 
268  selection->addSelectionCallback( Imp::made_selection, selection );
269  selection->addDeselectionCallback( Imp::made_deselection, selection );
270  selection->addStartCallback( Imp::start_changeselection, this );
271  selection->addFinishCallback( Imp::finished_changeselection, this );
272  selection->addClickOutsideCallback( Imp::clickedoutside, this );
273 
275  selection->ref();
276 
277  messageVerbose("selection node registered");
278 }

◆ registerViewer()

void IVP13DSystem::registerViewer ( SoQtViewer *  viewer)
inherited

Definition at line 418 of file IVP13DSystem.cxx.

419 {
420  if (!viewer)
421  return;
422  m_d->viewers.insert(viewer);
423 }

◆ reiconizeToShowSpecificMuonChambers

void VP1GeometrySystem::reiconizeToShowSpecificMuonChambers ( const std::set< GeoPVConstLink > &  chambers)
slot

Definition at line 1608 of file VP1GeometrySystem.cxx.

1609 {
1610  //Update map of touched chamber lists:
1611  bool listChanged(m_d->sender2ChamberList.find(sender())!=m_d->sender2ChamberList.end()?
1612  (chambers != m_d->sender2ChamberList[sender()]):true);
1613  m_d->sender2ChamberList[sender()] = chambers;
1614 
1615  //Trigger update if list changed and in auto mode:
1616  if ( listChanged && m_d->controller->autoAdaptMuonChambersToEventData() )
1618 }

◆ resetSubSystems

void VP1GeometrySystem::resetSubSystems ( VP1GeoFlags::SubSystemFlags  f)
protectedslot

Definition at line 1517 of file VP1GeometrySystem.cxx.

1518 {
1519  if (!f) {
1520  return;
1521  }
1522 
1523  deselectAll();
1524  for (Imp::SubSystemInfo*si : m_d->subsysInfoList) {
1525  if (si->flag & f) {
1526  if (!si->isbuilt) {
1527  continue;
1528  }
1529  VolumeHandle::VolumeHandleListItr it(si->vollist.begin()),itE(si->vollist.end());
1530  for (;it!=itE;++it) {
1531  messageDebug("resetting volume --> " + (*it)->getName() );
1532  (*it)->reset();
1533  }
1534  }
1535  }
1536 }

◆ restoreFromState()

void VP1GeometrySystem::restoreFromState ( QByteArray  ba)
virtual

Reimplemented from IVP1System.

Definition at line 1336 of file VP1GeometrySystem.cxx.

1336  {
1337  VP1Deserialise state(ba,this);
1338  if (state.version()<0||state.version()>7) {
1339  message("Warning: State data in .vp1 file is in wrong format - ignoring!");
1340  return;
1341  }
1342  if (state.version()<=5) {
1343  message("Warning: State data in .vp1 file is in obsolete format - ignoring!");
1344  return;
1345  }
1346 
1348  IVP13DSystemSimple::restoreFromState(state.restoreByteArray());
1349 
1350  //Controller:
1351  m_d->controller->restoreSettings(state.restoreByteArray());
1352 
1353  //Subsystem checkboxes:
1354  VP1GeoFlags::SubSystemFlags flags;
1355  QMap<QString,bool> subsysstate = state.restore<QMap<QString,bool> >();
1356  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList) {
1357  state.widgetHandled(subsys->checkbox);
1358  if (subsysstate.contains(subsys->checkbox->text())&&subsysstate[subsys->checkbox->text()])
1359  flags |= subsys->flag;
1360  }
1362 
1363  //Volume states:
1364  QMap<quint32,QByteArray> topvolstates;
1365  topvolstates = state.restore<QMap<quint32,QByteArray> >();
1366  if (m_d->sceneroot)//(for some reason) we already have been in buildPermanentScenegraph
1367  m_d->applyTopVolStates(topvolstates,true);
1368  else
1369  m_d->restoredTopvolstates = topvolstates;//save until buildPermanentScenegraph
1370 
1371  if (state.version()>=7) {
1373  m_d->detVisAttributes->applyState(state.restoreByteArray());
1374  m_d->matVisAttributes->applyState(state.restoreByteArray());
1375  m_d->volVisAttributes->applyState(state.restoreByteArray());
1376  }
1377 
1378  state.disableUnrestoredChecks();//We do the testing in the controller
1379 
1380  //Special:
1383 }

◆ saveMaterialsToFile

void VP1GeometrySystem::saveMaterialsToFile ( const QString &  filename,
bool  onlyChangedMaterials 
)
protectedslot

Definition at line 2769 of file VP1GeometrySystem.cxx.

2770 {
2771  if (filename.isEmpty())
2772  return;
2773 
2774  //If file exists, ask to overwrite.
2775  QFileInfo fi(filename);
2776  if (fi.exists()) {
2777  if (!fi.isWritable()) {
2778  QMessageBox::critical(0, "Error - could not save to file "+filename,
2779  "Could not save to file: <i>"+filename+"</i>"
2780  +"<br/><br/>Reason: File exists already and is write protected",QMessageBox::Ok,QMessageBox::Ok);
2781  return;
2782  }
2783  }
2784 
2785  QFile file(filename);
2786  if (!file.open(QIODevice::WriteOnly)) {
2787  QMessageBox::critical(0, "Error - problems writing to file "+filename,
2788  "Problems writing to file: <i>"+filename+"</i>",QMessageBox::Ok,QMessageBox::Ok);
2789  return;
2790  }
2791 
2793  VP1Serialise s(0/*version*/,this);
2794  //Save some file ID info!!
2795  s.save(QString("VP1GeoMaterialsBegin"));
2796  s.save(m_d->detVisAttributes->getState(onlyChangedMaterials));
2797  s.save(m_d->matVisAttributes->getState(onlyChangedMaterials));
2798  s.save(m_d->volVisAttributes->getState(onlyChangedMaterials));
2799  s.save(QString("VP1GeoMaterialsEnd"));
2800  s.disableUnsavedChecks();
2801 
2802  QDataStream outfile(&file);
2803  outfile<<qCompress(s.result()).toBase64();
2804 
2805 }

◆ saveState()

QByteArray VP1GeometrySystem::saveState ( )
virtual

Reimplemented from IVP1System.

Definition at line 1297 of file VP1GeometrySystem.cxx.

1297  {
1298 
1300 
1301  VP1Serialise serialise(7/*version*/,this);
1303 
1304  //Controller:
1306 
1307  //Subsystem checkboxes:
1308  QMap<QString,bool> subsysstate;
1309  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList) {
1310  serialise.widgetHandled(subsys->checkbox);
1311  subsysstate.insert(subsys->checkbox->text(),subsys->checkbox->isChecked());
1312  }
1313  serialise.save(subsysstate);
1314 
1315  //Volume states:
1316  QMap<quint32,QByteArray> topvolstates;
1317  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList) {
1318  if (m_d->controller->autoAdaptMuonChambersToEventData()&&subsys->hasMuonChambers())
1319  continue;//No need to store muon chamber data which will anyway be auto-adapted away.
1320  VolumeHandle::VolumeHandleListItr it(subsys->vollist.begin()),itE(subsys->vollist.end());
1321  for (;it!=itE;++it)
1322  topvolstates.insert((*it)->hashID(),(*it)->getPersistifiableState());
1323  }
1324  serialise.save(topvolstates);
1325 
1327  serialise.save(m_d->detVisAttributes->getState());//version 7+
1328  serialise.save(m_d->matVisAttributes->getState());//version 7+
1329  serialise.save(m_d->volVisAttributes->getState());//version 7+
1330 
1331  serialise.disableUnsavedChecks();//We do the testing in the controller
1332  return serialise.result();
1333 }

◆ serviceLocator()

ISvcLocator * IVP1System::serviceLocator ( ) const
inherited

Definition at line 324 of file IVP1System.cxx.

325 {
327 }

◆ setActiveState()

void IVP1System::setActiveState ( const ActiveState s,
const bool &  donttriggererase = true 
)
privateinherited

Definition at line 162 of file IVP1System.cxx.

163 {
164  //First handle case where we dont actually change state. Only
165  //special consideration is OFF->OFF where we have to do something if
166  //we need to erase:
167  if (m_d->activeState==OFF&&s==OFF&&(m_d->state==REFRESHED||m_d->refreshing)&&!donttriggererase) {
168  needErase();
170  return;
171  } else if (m_d->activeState==s) {
173  return;
174  }
175 
176  //Ok, we know that we are either ON->OFF or OFF->ON.
177  m_d->activeState = s;
178 
179  if (s==ON) {
180  //OFF->ON: We might need a refresh, so send out a signal for the scheduler:
182  } else {
183  //ON->OFF: We might need an erase signal:
184  if ((m_d->state==REFRESHED||m_d->refreshing)&&!donttriggererase) {
185  needErase();
186  }
187  }
189 }

◆ setAutoAdaptMuonChambersToEventData()

void VP1GeometrySystem::setAutoAdaptMuonChambersToEventData ( bool  b)

Definition at line 354 of file VP1GeometrySystem.cxx.

◆ setCanRegisterController()

void IVP1System::setCanRegisterController ( const bool &  c)
privateinherited

Definition at line 285 of file IVP1System.cxx.

286 {
287  if (VP1Msg::verbose()){
288  messageVerbose("setCanRegisterController called with"+QString(c?"true":"false"));
289  }
291 }

◆ setChannel()

void IVP1System::setChannel ( IVP1ChannelWidget cw)
privateinherited

Definition at line 94 of file IVP1System.cxx.

95 {
96  if (VP1Msg::verbose()) {
97  messageVerbose("setChannel ");
98  messageVerbose("setChannel m_d->state==CONSTRUCTED = "+QString(m_d->state==CONSTRUCTED?"true":"false"));
99  messageVerbose("setChannel cw!=0 = "+QString(cw!=0?"true":"false"));
100  }
101  assert(!m_d->channel);
102  assert(cw);
103  assert(m_d->state==CONSTRUCTED);
104  m_d->channel = cw;
105 }

◆ setCurvedSurfaceRealism

void VP1GeometrySystem::setCurvedSurfaceRealism ( int  val)
slot

Definition at line 1488 of file VP1GeometrySystem.cxx.

1489 {
1491  if (val<0||val>100) {
1492  message("setCurvedSurfaceRealism Error: Value "+str(val)+"out of range!");
1493  return;
1494  }
1495  m_d->controller->setComplexity(val==100?1.0:(val==0?0.0:val/100.0));
1496 }

◆ setGeometrySelectable()

void VP1GeometrySystem::setGeometrySelectable ( bool  b)

Definition at line 335 of file VP1GeometrySystem.cxx.

335  {
338 }

◆ setLabelPosOffsets

void VP1GeometrySystem::setLabelPosOffsets ( const QList< int > &  )
protectedslot

Definition at line 2866 of file VP1GeometrySystem.cxx.

2867 {
2868  messageVerbose("setLabelPosOffsets called");
2870 }

◆ setLabels

void VP1GeometrySystem::setLabels ( int  i)
protectedslot

Definition at line 2872 of file VP1GeometrySystem.cxx.

2872  {
2873  messageVerbose("setLabels "+str(i)+" for this many chambers:"+str(m_d->muonchambers_pv2handles.size()));
2874  // loop over all contained volumes (all visible volumes?) and update labels.
2875  // Just muons to start with
2876  std::map<PVConstLink,VolumeHandle*>::const_iterator it = m_d->muonchambers_pv2handles.begin(), itEnd = m_d->muonchambers_pv2handles.end();
2877  for (; it!=itEnd ; ++it){
2878  if (it->second->isInMuonChamber()) it->second->updateLabels(); // currently only do labels for Muon volumes
2879  }
2880 }

◆ setOrientViewToMuonChambersOnClick()

void VP1GeometrySystem::setOrientViewToMuonChambersOnClick ( bool  b)

Definition at line 347 of file VP1GeometrySystem.cxx.

◆ setRefreshing()

void IVP1System::setRefreshing ( const bool &  b)
privateinherited

Definition at line 114 of file IVP1System.cxx.

115 {
116  if (VP1Msg::verbose()){
117  messageVerbose("setRefreshing() called with b="+QString(b?"true":"false"));
118  }
119  if (b) {
120  assert(m_d->state==ERASED);
121  } else {
122  assert(m_d->state==REFRESHED);
123  }
124  m_d->refreshing = b;
125 }

◆ setShowVolumeOutLines

void VP1GeometrySystem::setShowVolumeOutLines ( bool  b)
protectedslot

Definition at line 2760 of file VP1GeometrySystem.cxx.

◆ setState()

void IVP1System::setState ( const State s)
privateinherited

Definition at line 141 of file IVP1System.cxx.

142 {
143 #ifndef NDEBUG
144  assert (m_d->state != s);
145  assert(s!=CONSTRUCTED);
146  if (s==REFRESHED) {
147  assert(m_d->state==ERASED);
148  }
149  if (s==ERASED) {
150  assert(m_d->state==REFRESHED||m_d->state==CONSTRUCTED);
151  }
152  if (s==UNCREATED) {
153  assert(m_d->state==ERASED);
154  }
155 #endif
156  m_d->state = s;
157  if (s==REFRESHED||s==ERASED)
159 }

◆ setUserSelectionNotificationsEnabled()

void IVP13DSystem::setUserSelectionNotificationsEnabled ( SoCooperativeSelection sel,
bool  enabled 
)
inherited

Definition at line 310 of file IVP13DSystem.cxx.

311 {
312  if (!selection) {
313  message("setUserSelectionNotificationsEnabled Error: NULL selection pointer!");
314  return;
315  }
317  message("setUserSelectionNotificationsEnabled Error: Called for selection which was never registered!");
318  return;
319  }
320  if (enabled != m_d->selectionsWithDisabledNotifications.contains(selection))
321  return;
322 
323  if (enabled)
325  else
327 
328 }

◆ setZoomToVolumeOnClick()

void VP1GeometrySystem::setZoomToVolumeOnClick ( bool  b)

Definition at line 341 of file VP1GeometrySystem.cxx.

341  {
344 }

◆ state()

IVP1System::State IVP1System::state ( ) const
inherited

Definition at line 129 of file IVP1System.cxx.

130 {
131  return m_d->state;
132 }

◆ storeGate()

StoreGateSvc* IVP1System::storeGate ( ) const
inlineinherited

Definition at line 119 of file IVP1System.h.

119 { return eventStore(); }//OBSOLETE NAME. Use eventStore() instead.

◆ str() [1/30]

static QString VP1String::str ( const Amg::Vector3D t)
inlinestaticinherited

Definition at line 98 of file VP1String.h.

98 { return "("+str(t.x())+", "+str(t.y())+", "+str(t.z())+")"; }

◆ str() [2/30]

static QString VP1String::str ( const bool  b)
inlinestaticinherited

Definition at line 53 of file VP1String.h.

53 { return b?"True":"False"; }

◆ str() [3/30]

static QString VP1String::str ( const char *  c)
inlinestaticinherited

Definition at line 50 of file VP1String.h.

50 { return c; }

◆ str() [4/30]

static QString VP1String::str ( const double &  d)
inlinestaticinherited

Definition at line 81 of file VP1String.h.

81 { return QString::number(d); }

◆ str() [5/30]

static QString VP1String::str ( const float &  f)
inlinestaticinherited

Definition at line 82 of file VP1String.h.

82 { return QString::number(f); }

◆ str() [6/30]

template<class T >
static QString VP1String::str ( const HepGeom::BasicVector3D< T > &  t)
inlinestaticinherited

Definition at line 95 of file VP1String.h.

95 { return "("+str(t.x())+", "+str(t.y())+", "+str(t.z())+")"; }

◆ str() [7/30]

QString VP1String::str ( const QColor &  c)
staticinherited

Definition at line 30 of file VP1String.cxx.

31 {
32  return c.isValid() ? c.name() : "Invalid";
33 }

◆ str() [8/30]

template<class T >
static QString VP1String::str ( const QFlags< T > &  f)
inlinestaticinherited

Definition at line 91 of file VP1String.h.

91 { return "0x"+QString::number(f, 16).toUpper().rightJustified(8,'0'); }

◆ str() [9/30]

template<class T >
static QString VP1String::str ( const QList< T > &  t)
inlinestaticinherited

Definition at line 102 of file VP1String.h.

102 { return "QList of size"+QString::number(t.size()); }

◆ str() [10/30]

static QString VP1String::str ( const QString &  s)
inlinestaticinherited

Definition at line 49 of file VP1String.h.

49 { return s; }

◆ str() [11/30]

QString VP1String::str ( const SbColor &  c)
staticinherited

Definition at line 36 of file VP1String.cxx.

37 {
39 }

◆ str() [12/30]

QString VP1String::str ( const SbVec2d &  v)
staticinherited

Definition at line 61 of file VP1String.cxx.

61 { double x,y; v.getValue(x,y); return "("+str(x)+", "+str(y)+")"; }

◆ str() [13/30]

QString VP1String::str ( const SbVec2f &  v)
staticinherited

Definition at line 62 of file VP1String.cxx.

62 { float x,y; v.getValue(x,y); return "("+str(x)+", "+str(y)+")"; }

◆ str() [14/30]

QString VP1String::str ( const SbVec2s &  v)
staticinherited

Definition at line 63 of file VP1String.cxx.

63 { short x,y; v.getValue(x,y); return "("+str(x)+", "+str(y)+")"; }

◆ str() [15/30]

QString VP1String::str ( const SbVec3d &  v)
staticinherited

Definition at line 64 of file VP1String.cxx.

64 { double x,y,z; v.getValue(x,y,z); return "("+str(x)+", "+str(y)+", "+str(z)+")"; }

◆ str() [16/30]

QString VP1String::str ( const SbVec3f &  v)
staticinherited

Definition at line 65 of file VP1String.cxx.

65 { float x,y,z; v.getValue(x,y,z); return "("+str(x)+", "+str(y)+", "+str(z)+")"; }

◆ str() [17/30]

QString VP1String::str ( const SbVec3s &  v)
staticinherited

Definition at line 66 of file VP1String.cxx.

66 { short x,y,z; v.getValue(x,y,z); return "("+str(x)+", "+str(y)+", "+str(z)+")"; }

◆ str() [18/30]

QString VP1String::str ( const SbVec4d &  v)
staticinherited

Definition at line 67 of file VP1String.cxx.

67 { double x,y,z,t; v.getValue(x,y,z,t); return "("+str(x)+", "+str(y)+", "+str(z)+", "+str(t)+")"; }

◆ str() [19/30]

QString VP1String::str ( const SbVec4f &  v)
staticinherited

Definition at line 68 of file VP1String.cxx.

68 { float x,y,z,t; v.getValue(x,y,z,t); return "("+str(x)+", "+str(y)+", "+str(z)+", "+str(t)+")"; }

◆ str() [20/30]

template<class T >
static QString VP1String::str ( const T *  t)
inlinestaticinherited

Definition at line 87 of file VP1String.h.

87 { return str(static_cast<const void* >(t)); }

◆ str() [21/30]

QString VP1String::str ( const void *  p)
staticinherited

Definition at line 48 of file VP1String.cxx.

49 {
50  if (p) {
51  std::ostringstream s;
52  s << p;
53  // Explicitly naming QString here avoids a cppcheck warning.
54  return QString (s.str().c_str());
55  } else {
56  return "NULL";
57  }
58 }

◆ str() [22/30]

QString VP1String::str ( const VP1Interval i)
staticinherited

Definition at line 42 of file VP1String.cxx.

43 {
44  return i.toString();
45 }

◆ str() [23/30]

static QString VP1String::str ( int  n)
inlinestaticinherited

Definition at line 77 of file VP1String.h.

77 { return QString::number(n); }

◆ str() [24/30]

static QString VP1String::str ( long  n)
inlinestaticinherited

Definition at line 75 of file VP1String.h.

75 { return QString::number(n); }

◆ str() [25/30]

static QString VP1String::str ( qlonglong  n)
inlinestaticinherited

Definition at line 79 of file VP1String.h.

79 { return QString::number(n); }

◆ str() [26/30]

static QString VP1String::str ( qulonglong  n)
inlinestaticinherited

Definition at line 80 of file VP1String.h.

80 { return QString::number(n); }

◆ str() [27/30]

static QString VP1String::str ( short int  n)
inlinestaticinherited

Definition at line 73 of file VP1String.h.

73 { return QString::number(n); }

◆ str() [28/30]

static QString VP1String::str ( uint  n)
inlinestaticinherited

Definition at line 78 of file VP1String.h.

78 { return QString::number(n); }

◆ str() [29/30]

static QString VP1String::str ( ulong  n)
inlinestaticinherited

Definition at line 76 of file VP1String.h.

76 { return QString::number(n); }

◆ str() [30/30]

static QString VP1String::str ( unsigned short int  n)
inlinestaticinherited

Definition at line 74 of file VP1String.h.

74 { return QString::number(n); }

◆ sysmessage

void IVP1System::sysmessage ( QString  ) const
signalinherited

◆ systemcreate()

void VP1GeometrySystem::systemcreate ( StoreGateSvc detstore)
virtual

Reimplemented from IVP13DSystemSimple.

Definition at line 499 of file VP1GeometrySystem.cxx.

500 {
502 }

◆ systemerase()

void IVP13DSystemSimple::systemerase ( )
virtualinherited

Reimplemented in VP1TrackSystem, VP1AODSystem, VP1PrepRawDataSystem, VP1RawDataSystem, VP1CaloClusterSystem, VP1MissingEtSystem, VP1CaloHitLegoSystem, VP1CaloLegoSystem, VP1VertexSystem, and VP1CaloCellSystem.

Definition at line 28 of file IVP13DSystemSimple.cxx.

29 {
30  // messageVerbose("WARNING: Did not reimplement systemerase!");
31 }

◆ systemuncreate()

void VP1GeometrySystem::systemuncreate ( )
virtual

Reimplemented from IVP13DSystemSimple.

Definition at line 313 of file VP1GeometrySystem.cxx.

314 {
315 
320 
321  for (Imp::SubSystemInfo * subsys : m_d->subsysInfoList)
322  delete subsys;
323  m_d->subsysInfoList.clear();
324 
325 }

◆ toolSvc()

IToolSvc * IVP1System::toolSvc ( ) const
inherited

Definition at line 330 of file IVP1System.cxx.

331 {
332  return VP1AthenaPtrs::toolSvc();
333 }

◆ uncreate()

void IVP13DSystemSimple::uncreate ( )
privatevirtualinherited

Reimplemented from IVP1System.

Definition at line 202 of file IVP13DSystemSimple.cxx.

203 {
204 
205  if(VP1Msg::verbose()){
206  messageDebug("uncreate()...");
207  }
208 
209  assert(m_d->wascreated);
210  assert(!m_d->wasrefreshed);
211  m_d->rootE->enableNotify(false);
212  m_d->rootR->enableNotify(false);
213  systemuncreate();
214  m_d->root->removeAllChildren();
215  m_d->rootE->removeAllChildren();
216  m_d->rootR->removeAllChildren();
217  m_d->wascreated=false;
218 }

◆ unregisterSelectionNode()

void IVP13DSystem::unregisterSelectionNode ( SoCooperativeSelection selection)
inherited

Definition at line 281 of file IVP13DSystem.cxx.

282 {
283  if (!selection) {
284  message("unregisterSelectionNode Error: NULL selection pointer!");
285  return;
286  }
288  message("registerSelectionNode Error: Trying to unregister unknown selection node!");
289  return;
290  }
291 
292  selection->removeSelectionCallback( Imp::made_selection, selection );
293  selection->removeDeselectionCallback( Imp::made_deselection, selection );
294  selection->removeStartCallback( Imp::start_changeselection, this );
295  selection->removeFinishCallback( Imp::finished_changeselection, this );
296  selection->removeClickOutsideCallback( Imp::clickedoutside, this );
297 
301  selection->unref();
302 
303  messageVerbose("selection node unregistered");
304 
305 }

◆ updateGUI()

void IVP13DSystemSimple::updateGUI ( )
inlineinherited

Definition at line 89 of file IVP13DSystemSimple.h.

◆ updateTransparency

void VP1GeometrySystem::updateTransparency ( )
protectedslot

Definition at line 1501 of file VP1GeometrySystem.cxx.

1502 {
1504 
1505  float transparency = m_d->controller->transparency();
1506 
1507  VolumeHandle* lastSelVol = m_d->controller->lastSelectedVolume();
1513  m_d->controller->setLastSelectedVolume(lastSelVol);
1514 }

◆ userChangedSelection()

void IVP13DSystem::userChangedSelection ( SoCooperativeSelection ,
QSet< SoNode * >  ,
QSet< SoPath * >   
)
virtualinherited

◆ userClickedOnBgd()

void IVP13DSystem::userClickedOnBgd ( )
virtualinherited

Reimplemented in VP1AODSystem, VP1TrackSystem, VP1PrepRawDataSystem, and VP1CaloReadoutSystem.

Definition at line 62 of file IVP13DSystem.cxx.

62 {}

◆ userDeselectedSingleNode()

void IVP13DSystem::userDeselectedSingleNode ( SoCooperativeSelection ,
SoNode *  ,
SoPath *   
)
virtualinherited

Reimplemented in VP1AODSystem, VP1TrackSystem, and VP1PrepRawDataSystem.

Definition at line 60 of file IVP13DSystem.cxx.

60 {}

◆ userPickedNode()

void VP1GeometrySystem::userPickedNode ( SoNode *  pickedNode,
SoPath *  pickedPath 
)
virtual

Reimplemented from IVP13DSystemSimple.

Definition at line 813 of file VP1GeometrySystem.cxx.

814 {
815 
817  // We want to find the volumehandle for the volume. To do so, we look //
818  // for the SoSeparator identifying the actual picked shape node, and //
819  // use it to look up the handle: //
821 
822  //Looking for the identifying "nodesep", there are three scenarios
823  //for the type signatures of the final part of the path:
824  //
825  // 1) Most shapes:
826  // nodesep -> pickedNode (but we must pop to a group node in case of SoCylinders)
827  //
828  // 2) Volumes Around Z (all phi sectors enabled):
829  // nodesep -> switch -> pickedNode
830  //
831  // 3) Volumes Around Z (only some phi sectors enabled):
832  // nodesep -> switch -> sep -> pickedNode
833  //
834  // In the third scenario we also have to pop the path, in order for
835  // all phi-slices of the part gets highlighted (since more than one
836  // soshape node represents the volume).
837 
838 
839  VP1Msg::messageDebug("VP1GeometrySystem::userPickedNode()");
840 
841  if (pickedPath->getNodeFromTail(0)->getTypeId()==SoCylinder::getClassTypeId())
842  pickedPath->pop();
843 
844  if (pickedPath->getLength()<5) {
845  message("Path too short");
846  return;
847  }
848 
849  SoSeparator * nodesep(0);
850 
851  if (pickedPath->getNodeFromTail(1)->getTypeId()==SoSeparator::getClassTypeId()
852  && pickedPath->getNodeFromTail(2)->getTypeId()==SoSwitch::getClassTypeId()
853  && pickedPath->getNodeFromTail(3)->getTypeId()==SoSeparator::getClassTypeId())
854  {
855  //Scenario 3:
856  nodesep = static_cast<SoSeparator*>(pickedPath->getNodeFromTail(3));
857  pickedPath->pop();//To get highlighting of siblings also.
858  }
859  else if (pickedPath->getNodeFromTail(1)->getTypeId()==SoSwitch::getClassTypeId()
860  && pickedPath->getNodeFromTail(2)->getTypeId()==SoSeparator::getClassTypeId())
861  {
862  //Scenario 2:
863  nodesep = static_cast<SoSeparator*>(pickedPath->getNodeFromTail(2));
864  }
865  else if (pickedPath->getNodeFromTail(1)->getTypeId()==SoSeparator::getClassTypeId()) {
866  //Scenario 1 (normal):
867  nodesep = static_cast<SoSeparator*>(pickedPath->getNodeFromTail(1));
868  }
869  if (!nodesep) {
870  message("Unexpected picked path");
871  return;
872  }
873  if ( (!(nodesep)) || (m_d->sonodesep2volhandle.find(nodesep) == m_d->sonodesep2volhandle.end()) ) {
874  message("Problems finding volume handle");
875  return;
876  }
877  VolumeHandle * volhandle = m_d->sonodesep2volhandle[nodesep];
878  if (!volhandle) {
879  message("Found NULL volume handle");
880  return;
881  }
882 
884  // Next thing to do is to check whether volume was clicked on with a //
885  // modifier of SHIFT/CTRL/Z. If so, we have to change the state on //
886  // the volume handle. Otherwise, we need to print some information: //
888 
889  //For focus reason, and since Qt doesn't allow standard keys such as
890  //'z' as modifiers, we check for keypress states using a combination
891  //of the inventor and Qt way
892 
893  bool shift_isdown = (Qt::ShiftModifier & QApplication::keyboardModifiers());
894 // || ( m_d->kbEvent && (SO_KEY_PRESS_EVENT(m_d->kbEvent, SoKeyboardEvent::LEFT_SHIFT)||
895 // SO_KEY_PRESS_EVENT(m_d->kbEvent, SoKeyboardEvent::RIGHT_SHIFT)) ) );
896 
897  if (shift_isdown) {
898  //Parent of volume should be put in CONTRACTED state.
899  deselectAll();
900  if (volhandle->parent())
901  volhandle->parent()->setState(VP1GeoFlags::CONTRACTED);
903  return;
904  }
905 
906  bool ctrl_isdown = (Qt::ControlModifier & QApplication::keyboardModifiers());
907 // || ( m_d->kbEvent && (SO_KEY_PRESS_EVENT(m_d->kbEvent, SoKeyboardEvent::LEFT_CONTROL)||
908 // SO_KEY_PRESS_EVENT(m_d->kbEvent, SoKeyboardEvent::RIGHT_CONTROL)) ) );
909 
910  if (ctrl_isdown) {
911  //Volume should be put in EXPANDED state if it has children.
912  deselectAll();
913  if (volhandle->nChildren()>0) {
914  volhandle->setState(VP1GeoFlags::EXPANDED);
915  }
917  return;
918  }
919 
920  bool z_isdown = m_d->kbEvent && SO_KEY_PRESS_EVENT(m_d->kbEvent,SoKeyboardEvent::Z);
921  if (z_isdown) {
922  //Volume should be put in ZAPPED state.
923  deselectAll();
924  volhandle->setState(VP1GeoFlags::ZAPPED);
925  message("===> Zapping Node: "+volhandle->getName());
926  // std::cout<<"Zapped VH="<<volhandle<<std::endl;
927  return;
928  }
929 
931  // Depending on settings, we are to realign the camera if the //
932  // clicked volume is (daughter of) a muon chamber //
934 
935  bool orientedView(false);
937  //Volume is an, or is daughter of an, MDT, CSC or TGC chamber
939  orientedView = true;
940  //Now we must fix the tail of the pickedPath to ensure we
941  //select the correct node corresponding to the clicked volume
942  //again (it might have become attached/detached by the call to
943  //orientViewToMuonChamber):
944  if (!VP1QtInventorUtils::changePathTail(pickedPath,m_d->sceneroot,volhandle->nodeSoSeparator())) {
945  message("Warning: Failed to relocate picked node.");
946  deselectAll();
947  }
948  }
949 
951  // Zoom to volume //
953 
954  //Nb: We don't do this if we already oriented to the muon chamber above.
955  if (!orientedView&&m_d->controller->zoomToVolumeOnClick()) {
956  if (m_d->sceneroot&&volhandle->nodeSoSeparator()) {
957  std::set<SoCamera*> cameras = getCameraList();
958  std::set<SoCamera*>::iterator it,itE = cameras.end();
959  for (it=cameras.begin();it!=itE;++it) {
961  }
962  }
963  }
964 
965 
967  // Update last-select controls //
969 
970  m_d->controller->setLastSelectedVolume(volhandle);
971 
973  // OK, time to print some information for the volume //
975 
976  message("===> Selected Node: "+volhandle->getName());
977  // std::cout<<"VolHandle = "<<volhandle<<std::endl;
979  for (const QString& str : DumpShape::shapeToStringList(volhandle->geoPVConstLink()->getLogVol()->getShape()))
980  message(str);
981  }
982 
984  message("===> Material:");
985  for (const QString& line : VP1GeomUtils::geoMaterialToStringList(volhandle->geoMaterial()))
986  message(" "+line);
987  }
988 
990  int cn = volhandle->copyNumber();
991  message("===> CopyNo : "+(cn>=0?QString::number(cn):QString(cn==-1?"Invalid":"Error reconstructing copynumber")));
992  }
993 
995 
996  float translation_x, translation_y, translation_z, rotaxis_x, rotaxis_y, rotaxis_z, rotangle_radians;
998  translation_x, translation_y, translation_z,
999  rotaxis_x, rotaxis_y, rotaxis_z, rotangle_radians );
1000  message("===> Local Translation:");
1001  message(" x = "+QString::number(translation_x/CLHEP::mm)+" mm");
1002  message(" y = "+QString::number(translation_y/CLHEP::mm)+" mm");
1003  message(" z = "+QString::number(translation_z/CLHEP::mm)+" mm");
1004  message("===> Local Rotation:");
1005  message(" axis x = "+QString::number(rotaxis_x));
1006  message(" axis y = "+QString::number(rotaxis_y));
1007  message(" axis z = "+QString::number(rotaxis_z));
1008  message(" angle = "+QString::number(rotangle_radians*180.0/M_PI)+" deg");
1010  translation_x, translation_y, translation_z,
1011  rotaxis_x, rotaxis_y, rotaxis_z, rotangle_radians );
1012  message("===> Global Translation:");
1013  message(" x = "+QString::number(translation_x/CLHEP::mm)+" mm");
1014  message(" y = "+QString::number(translation_y/CLHEP::mm)+" mm");
1015  message(" z = "+QString::number(translation_z/CLHEP::mm)+" mm");
1016  message("===> Global Rotation:");
1017  message(" axis x = "+QString::number(rotaxis_x));
1018  message(" axis y = "+QString::number(rotaxis_y));
1019  message(" axis z = "+QString::number(rotaxis_z));
1020  message(" angle = "+QString::number(rotangle_radians*180.0/M_PI)+" deg");
1021  }
1022 
1024  std::ostringstream str;
1025  GeoPrintGraphAction pg(str);
1026  volhandle->geoPVConstLink()->exec(&pg);
1027  message("===> Tree:");
1028  for (const QString& line : QString(str.str().c_str()).split("\n"))
1029  message(" "+line);
1030  }
1031 
1033  //FIXME: Move the mass calculations to the volume handles, and let
1034  //the common data cache some of the volume information by
1035  //logVolume).
1036  message("===> Total Mass &lt;===");
1037  message("Inclusive "+QString::number(Imp::inclusiveMass(volhandle->geoPVConstLink())/CLHEP::kilogram)+" kg");
1038  message("Exclusive "+QString::number(Imp::exclusiveMass(volhandle->geoPVConstLink())/CLHEP::kilogram)+" kg");
1039  }
1040 
1042  PVConstLink pvlink = volhandle->topLevelParent()->geoPVConstLink();
1043  std::map<PVConstLink,VolumeHandle*>::const_iterator itChamber = m_d->muonchambers_pv2handles.find(pvlink);
1044  #ifndef BUILDVP1LIGHT
1045  if (itChamber!=m_d->muonchambers_pv2handles.end()) {
1047  std::map<GeoPVConstLink,const MuonGM::MuonStation*>::const_iterator itStation(m_d->pv2MuonStation.find(pvlink));
1048  if (itStation!=m_d->pv2MuonStation.end()) {
1049  message("===> Muon station &lt;===");
1050  message(" ",m_d->stationInfo(itStation->second));
1051  }
1052  }
1053  #endif
1054  }
1055 
1057  // Emit a signal for the VP1UtilitySystems::PartSpect system //
1059  QStack<QString> partspectPath, extras;
1060  QString detFactoryName;
1061 
1062  VolumeHandle *parentVH(volhandle), *childVH(volhandle);
1063  m_d->createPathExtras(volhandle,detFactoryName,extras);
1064 
1065  do {
1066  parentVH = parentVH->parent();
1067  PVConstLink parentPVLink = parentVH ? parentVH->geoPVConstLink() : childVH->geoPVConstLink()->getParent();
1068  if (parentPVLink) {
1069  int indexOfChild = parentVH ? childVH->childNumber() : (int)parentPVLink->indexOf(childVH->geoPVConstLink());
1070 
1071  std::string childPVName = parentPVLink->getNameOfChildVol(indexOfChild);
1072  QString pathEntry = childPVName=="ANON" ? detFactoryName+childVH->getName() : QString(childPVName.c_str());
1073 
1074  Query<int> childCopyNo = parentPVLink->getIdOfChildVol(indexOfChild);
1075  if(childCopyNo.isValid()) {
1076  QString strCopyNo;
1077  strCopyNo.setNum(childCopyNo);
1078  pathEntry += ("::"+strCopyNo);
1079  }
1080  partspectPath.push(pathEntry);
1081  childVH = parentVH;
1082  }
1083  }while(parentVH);
1084 
1085  while(!extras.isEmpty())
1086  partspectPath.push(extras.pop());
1087 
1088  partspectPath.push("Atlas::Atlas");
1089 
1090  // Emit the signal
1091  //volhandle cannot be NULL here (coverity 16287)
1092  //int cn=(!volhandle) ? -1 : volhandle->copyNumber();
1093  int cn=volhandle->copyNumber();
1094  plotSpectrum(partspectPath,cn);
1095 }

◆ userSelectedSingleNode()

void IVP13DSystem::userSelectedSingleNode ( SoCooperativeSelection ,
SoNode *  ,
SoPath *   
)
virtualinherited

Reimplemented in VP1AODSystem, VP1TrackSystem, and VP1PrepRawDataSystem.

Definition at line 59 of file IVP13DSystem.cxx.

59 {}

◆ verbose()

static bool IVP1System::verbose ( )
inlinestaticinherited

Definition at line 86 of file IVP1System.h.

86 { return s_vp1verbose; }// Returns true if env var VP1_VERBOSE_OUTPUT=1

◆ volumeResetRequested

void VP1GeometrySystem::volumeResetRequested ( VolumeHandle vh)
protectedslot

Definition at line 2750 of file VP1GeometrySystem.cxx.

2751 {
2752  if (!vh)
2753  return;
2754  deselectAll();
2755  vh->reset();
2757 }

◆ volumeStateChangeRequested

void VP1GeometrySystem::volumeStateChangeRequested ( VolumeHandle vh,
VP1GeoFlags::VOLSTATE  state 
)
protectedslot

Definition at line 2739 of file VP1GeometrySystem.cxx.

2740 {
2741  //might not use this slot presently...
2742  if (!vh)
2743  return;
2744  deselectAll();
2745  vh->setState(state);
2747 }

◆ warnOnDisabledNotifications()

void IVP13DSystemSimple::warnOnDisabledNotifications ( ) const
inherited

Definition at line 221 of file IVP13DSystemSimple.cxx.

222 {
223  QList<SoNode*> nodesR;
224  QList<SoNode*> nodesE;
227  if (!nodesR.isEmpty()) {
228  message("WARNING: Found "+str(nodesR.count())+" node"+QString(nodesR.count()>1?"s":0)+" with disabled notifications in permanent scenegraph:");
229  for (SoNode * node : nodesR)
230  message(" => Node ("+str(node)+") of type "+QString(node->getTypeId().getName().getString())+", named "+QString(node->getName().getString()));
231  }
232  if (!nodesE.isEmpty()) {
233  message("WARNING: Found "+str(nodesE.count())+" node"+QString(nodesE.count()>1?"s":0)+" with disabled notifications in event scenegraph:");
234  for (SoNode * node : nodesE)
235  message(" => Node ("+str(node)+") of type "+QString(node->getTypeId().getName().getString())+", named "+QString(node->getName().getString()));
236  }
237 }

Member Data Documentation

◆ m_d

Imp* VP1GeometrySystem::m_d
protected

Definition at line 104 of file VP1GeometrySystem.h.

◆ s_vp1verbose

const bool IVP1System::s_vp1verbose = VP1QtUtils::environmentVariableIsOn("VP1_VERBOSE_OUTPUT")
staticprivateinherited

Definition at line 158 of file IVP1System.h.


The documentation for this class was generated from the following files:
VP1GeometrySystem::emit_appropriateMDTProjectionsChanged
void emit_appropriateMDTProjectionsChanged()
Definition: VP1GeometrySystem.cxx:1591
GeoSysController::setLabelsEnabled
void setLabelsEnabled(bool t0s, bool hits)
controls whether the checkboxes are enabled or not.
Definition: GeoSysController.cxx:498
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
IVP13DSystemSimple::systemuncreate
virtual void systemuncreate()
Definition: IVP13DSystemSimple.cxx:27
VP1GeoFlags::MuonBarrelStationInner
@ MuonBarrelStationInner
Definition: VP1GeoFlags.h:42
mergePhysValFiles.pattern
pattern
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:26
VP1GeometrySystem::Imp::getClosestCSCOrTGCEdgeDirections
std::pair< SbVec3f, SbVec3f > getClosestCSCOrTGCEdgeDirections(const SbVec3f &cameraDirection, VolumeHandle *chamberhandle)
Definition: VP1GeometrySystem.cxx:1957
VP1GeometrySystem::appropriateMDTProjectionsChanged
void appropriateMDTProjectionsChanged(int)
VP1GeometrySystem::Imp::initialSubSystemsTurnedOn
VP1GeoFlags::SubSystemFlags initialSubSystemsTurnedOn
Definition: VP1GeometrySystem.cxx:242
GeoModelExperiment::getPhysVol
GeoPhysVol * getPhysVol()
Destructor.
Definition: GeoModelExperiment.cxx:21
python.SystemOfUnits.second
int second
Definition: SystemOfUnits.py:120
IVP1System::Imp::contact_info
const QString contact_info
Definition: IVP1System.cxx:39
python.CaloRecoConfig.f
f
Definition: CaloRecoConfig.py:127
IVP13DSystem::Imp::selection2system
static std::map< SoCooperativeSelection *, IVP13DSystem * > selection2system
Definition: IVP13DSystem.cxx:46
VP1GeometrySystem::Imp::sceneroot
SoSeparator * sceneroot
Definition: VP1GeometrySystem.cxx:112
VP1GeometrySystem::Imp::applyTopVolStates
void applyTopVolStates(const QMap< quint32, QByteArray > &, bool disablenotif=false)
Definition: VP1GeometrySystem.cxx:1386
checkFileSG.line
line
Definition: checkFileSG.py:75
VolumeHandle::isInMuonChamber
bool isInMuonChamber() const
Definition: VolumeHandle.h:153
VP1GeoFlags::ToroidECA
@ ToroidECA
Definition: VP1GeoFlags.h:58
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
VolumeHandle::reset
void reset()
Definition: VolumeHandle.h:158
VP1GeometrySystem::Imp::chamberT0s
QList< const std::map< GeoPVConstLink, float > * > chamberT0s
Definition: VP1GeometrySystem.cxx:299
VP1GeometrySystem::Imp::chamberPVToMuonSubSystemInfo
SubSystemInfo * chamberPVToMuonSubSystemInfo(const GeoPVConstLink &chamberPV)
Definition: VP1GeometrySystem.cxx:1746
GeoSysController::printInfoOnClick_Material
bool printInfoOnClick_Material() const
Definition: GeoSysController.cxx:406
VP1Serialise
Definition: VP1Serialise.h:45
GeoSysController::orientViewToMuonChambersOnClick
bool orientViewToMuonChambersOnClick() const
Definition: GeoSysController.cxx:394
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
athena.path
path
python interpreter configuration --------------------------------------—
Definition: athena.py:126
max
#define max(a, b)
Definition: cfImp.cxx:41
VP1GeometrySystem::Imp::muonchambers_pv2handles
std::map< PVConstLink, VolumeHandle * > muonchambers_pv2handles
Definition: VP1GeometrySystem.cxx:258
PowhegControl_ttHplus_NLO.ss
ss
Definition: PowhegControl_ttHplus_NLO.py:83
run.infile
string infile
Definition: run.py:13
IVP13DSystem::Imp::made_selection
static void made_selection(void *userdata, SoPath *path)
Definition: IVP13DSystem.cxx:192
DumpShape::shapeToStringList
static QStringList shapeToStringList(const GeoShape *shape)
Definition: DumpShape.cxx:34
VP1GeoFlags::MuonShielding
@ MuonShielding
Definition: VP1GeoFlags.h:62
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
IVP13DSystemSimple::IVP13DSystemSimple
IVP13DSystemSimple(const QString &name, const QString &information, const QString &contact_info)
Definition: IVP13DSystemSimple.cxx:50
IVP13DSystem::Imp::viewers
std::set< SoQtViewer * > viewers
Definition: IVP13DSystem.cxx:37
IVP13DSystemSimple::buildController
virtual QWidget * buildController()
Definition: IVP13DSystemSimple.cxx:24
VP1GeoFlags::ALFA
@ ALFA
Definition: VP1GeoFlags.h:57
RoiUtil::serialise
void serialise(const std::vector< const IRoiDescriptor * > &rois, roiserial_type &s)
serialise an entire vector of IRoiDescriptors
Definition: RoiSerialise.cxx:45
VP1GeometrySystem::Imp::controller
GeoSysController * controller
Definition: VP1GeometrySystem.cxx:244
VP1GeometrySystem::Imp::sender2ChamberList
std::map< QObject *, std::set< GeoPVConstLink > > sender2ChamberList
Definition: VP1GeometrySystem.cxx:260
GeoSysController::setZoomToVolumeOnClick
void setZoomToVolumeOnClick(bool)
Definition: GeoSysController.cxx:266
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
GeoSysController::setAutoAdaptMuonChambersToEventData
void setAutoAdaptMuonChambersToEventData(bool)
Definition: GeoSysController.cxx:278
VP1GeoFlags::EXPANDED
@ EXPANDED
Definition: VP1GeoFlags.h:88
IVP1System::CONSTRUCTED
@ CONSTRUCTED
Definition: IVP1System.h:143
index
Definition: index.py:1
PhiSectorManager::largeChangesBegin
void largeChangesBegin()
Definition: PhiSectorManager.cxx:492
AthenaPoolTestRead.flags
flags
Definition: AthenaPoolTestRead.py:8
Monitored::Z
@ Z
Definition: HistogramFillerUtils.h:24
hist_file_dump.d
d
Definition: hist_file_dump.py:137
VP1GeometrySystem::Imp::m_textSep
SoSeparator * m_textSep
Separator used to hold all visible labels.
Definition: VP1GeometrySystem.cxx:274
VolumeHandle::setState
void setState(const VP1GeoFlags::VOLSTATE &state)
Definition: VolumeHandle.cxx:350
GeoSysController::drawOptions
SoGroup * drawOptions() const
Definition: GeoSysController.cxx:358
VP1GeomUtils::geoMaterialToStringList
static QStringList geoMaterialToStringList(const GeoMaterial *)
Definition: VP1GeomUtils.cxx:10
VP1GeoFlags::InDetServMat
@ InDetServMat
Definition: VP1GeoFlags.h:37
GeoSysController
Definition: GeoSysController.h:29
VolumeHandle::geoMaterial
const GeoMaterial * geoMaterial() const
Definition: VolumeHandle.cxx:507
VP1GeoFlags::Pixel
@ Pixel
Definition: VP1GeoFlags.h:34
fillPileUpNoiseLumi.connect
string connect
Definition: fillPileUpNoiseLumi.py:70
VP1GeometrySystem::Imp::inclusiveMass
static double inclusiveMass(const PVConstLink &pv)
Definition: VP1GeometrySystem.cxx:1278
VP1GeometrySystem::Imp::phisectormanager
PhiSectorManager * phisectormanager
Definition: VP1GeometrySystem.cxx:245
VolumeHandle::topLevelParent
VolumeHandle * topLevelParent()
Definition: VolumeHandle.h:145
IVP13DSystemSimple::Imp::rootR
SoSeparator * rootR
Definition: IVP13DSystemSimple.cxx:37
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
skel.it
it
Definition: skel.GENtoEVGEN.py:423
VP1GeoFlags::BeamPipe
@ BeamPipe
Definition: VP1GeoFlags.h:52
VP1GeometrySystem::autoIconifyByVolumeOrMaterialName
void autoIconifyByVolumeOrMaterialName(bool, const QString &)
Definition: VP1GeometrySystem.cxx:2138
GeoModelExperiment
Definition: GeoModelExperiment.h:32
IVP1System::m_d
Imp * m_d
Definition: IVP1System.h:130
M_PI
#define M_PI
Definition: ActiveFraction.h:11
IVP13DSystemSimple::Imp::rootE
SoSeparator * rootE
Definition: IVP13DSystemSimple.cxx:38
VolumeHandle::geoPVConstLink
GeoPVConstLink geoPVConstLink() const
Definition: VolumeHandle.cxx:163
IVP1System::inactiveSystemTurnedActive
void inactiveSystemTurnedActive()
VP1Msg::debug
static bool debug()
Definition: VP1Msg.h:32
VP1GeometrySystem::Imp::buildSystem
void buildSystem(SubSystemInfo *)
Definition: VP1GeometrySystem.cxx:1098
VP1GeometrySystem::actionOnAllNonStandardVolumes
void actionOnAllNonStandardVolumes(bool)
Definition: VP1GeometrySystem.cxx:2027
UploadAMITag.l
list l
Definition: UploadAMITag.larcaf.py:158
VP1GeometrySystem::Imp::iconifyVisibleVolumesRecursively
void iconifyVisibleVolumesRecursively(VolumeHandle *, const QRegExp &, bool bymatname)
Definition: VP1GeometrySystem.cxx:2116
IVP1System::Imp::refreshing
bool refreshing
Definition: IVP1System.cxx:45
IVP13DSystem::Imp::clickedoutside
static void clickedoutside(void *userdata, SoCooperativeSelection *sel)
Definition: IVP13DSystem.cxx:65
VP1GeometrySystem::Imp::showITkPixelModules
void showITkPixelModules(VolumeHandle *, bool brl, bool ecA, bool ecC)
Definition: VP1GeometrySystem.cxx:2591
VP1LinAlgUtils::decodeTransformation
static void decodeTransformation(const SbMatrix &, float &translation_x, float &translation_y, float &translation_z, float &rotaxis_x, float &rotaxis_y, float &rotaxis_z, float &rotangle_radians)
Definition: VP1LinAlgUtils.cxx:162
sendEI_SPB.root
root
Definition: sendEI_SPB.py:34
VP1GeometrySystem::adaptMuonChambersStyleChanged
void adaptMuonChambersStyleChanged()
Definition: VP1GeometrySystem.cxx:1577
VP1GeometrySystem::Imp::detVisAttributes
DetVisAttributes * detVisAttributes
Definition: VP1GeometrySystem.cxx:233
IVP1ChannelWidget::emitRefreshInfoChanged
void emitRefreshInfoChanged()
Definition: IVP1ChannelWidget.cxx:268
GeoSysController::zoomToVolumeOnClick
bool zoomToVolumeOnClick() const
Definition: GeoSysController.cxx:388
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
VolumeTreeModel::disableSubSystem
void disableSubSystem(VP1GeoFlags::SubSystemFlag flag)
Definition: VolumeTreeModel.cxx:292
VP1GeometrySystem::volumeResetRequested
void volumeResetRequested(VolumeHandle *)
Definition: VP1GeometrySystem.cxx:2750
VolumeHandle::parent
VolumeHandle * parent()
Definition: VolumeHandle.h:144
PhiSectorManager::largeChangesEnd
void largeChangesEnd()
Definition: PhiSectorManager.cxx:510
x
#define x
VP1String::str
static QString str(const QString &s)
Definition: VP1String.h:49
VP1Controller::saveSettings
QByteArray saveSettings() const
Definition: VP1Controller.cxx:405
IVP13DSystemSimple::buildPermanentSceneGraph
virtual void buildPermanentSceneGraph(StoreGateSvc *detstore, SoSeparator *root)
Definition: IVP13DSystemSimple.cxx:25
VP1GeoFlags::MuonFeet
@ MuonFeet
Definition: VP1GeoFlags.h:61
VolumeHandle::getNameStdString
std::string getNameStdString() const
Definition: VolumeHandle.cxx:175
IVP1System::s_vp1verbose
static const bool s_vp1verbose
Definition: IVP1System.h:158
VP1GeometrySystem::autoAdaptMuonNSW
void autoAdaptMuonNSW(bool reset, bool stgc, bool mm, bool passiveSpacer, bool passiveStructure, bool passiveAPlate)
Definition: VP1GeometrySystem.cxx:2354
TruthTest.itE
itE
Definition: TruthTest.py:25
VP1GeoFlags::MuonToroidsEtc
@ MuonToroidsEtc
Definition: VP1GeoFlags.h:63
VP1GeometrySystem::Imp::volVisAttributes
VolVisAttributes * volVisAttributes
Definition: VP1GeometrySystem.cxx:235
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
VolumeTreeModel::getRootHandles
void getRootHandles(std::vector< std::pair< VolumeHandle::VolumeHandleListItr, VolumeHandle::VolumeHandleListItr > > &) const
Definition: VolumeTreeModel.cxx:341
VP1GeoFlags::MuonEndcapStationNSW
@ MuonEndcapStationNSW
Definition: VP1GeoFlags.h:65
GeoSysController::phiSectionWidget
PhiSectionWidget * phiSectionWidget() const
Definition: GeoSysController.cxx:376
IVP1System::state
State state() const
Definition: IVP1System.cxx:129
GeoSysController::subSystemCheckBox
QCheckBox * subSystemCheckBox(VP1GeoFlags::SubSystemFlag) const
Definition: GeoSysController.cxx:351
GeoSysController::autoAdaptMuonChambersToEventData
bool autoAdaptMuonChambersToEventData() const
Definition: GeoSysController.cxx:442
IVP1System::saveState
virtual QByteArray saveState()
Definition: IVP1System.cxx:294
IVP13DSystemSimple::Imp::root
SoCooperativeSelection * root
Definition: IVP13DSystemSimple.cxx:36
VP1GeoFlags::MuonEndcapStationCSC
@ MuonEndcapStationCSC
Definition: VP1GeoFlags.h:46
GeoSysController::pickStyle
SoPickStyle * pickStyle() const
Definition: GeoSysController.cxx:364
VP1GeometrySystem::orientViewToMuonChamber
void orientViewToMuonChamber(const GeoPVConstLink &chamberPV)
Definition: VP1GeometrySystem.cxx:1767
VP1GeoFlags::ForwardRegion
@ ForwardRegion
Definition: VP1GeoFlags.h:66
IVP13DSystemSimple::buildEventSceneGraph
virtual void buildEventSceneGraph(StoreGateSvc *sg, SoSeparator *root)=0
IVP1System::needErase
void needErase()
VolumeHandle::nodeSoSeparator
SoSeparator * nodeSoSeparator() const
Definition: VolumeHandle.cxx:232
checkTP.save
def save(self, fileName="./columbo.out")
Definition: checkTP.py:178
GeoSysController::transparency
float transparency() const
Definition: GeoSysController.cxx:455
GeoSysController::showVolumeOutLines
bool showVolumeOutLines() const
Definition: GeoSysController.cxx:462
GeoSysController::muonChamberAdaptionStyle
VP1GeoFlags::MuonChamberAdaptionStyleFlags muonChamberAdaptionStyle() const
Definition: GeoSysController.cxx:468
VP1GeometrySystem::Imp::previousAlignedChamberHandle
VolumeHandle * previousAlignedChamberHandle
Definition: VP1GeometrySystem.cxx:265
VP1Msg::prefix_msg
static const char * prefix_msg()
Definition: VP1Msg.h:56
VP1GeometrySystem::Imp::changeStateOfVisibleNonStandardVolumesRecursively
void changeStateOfVisibleNonStandardVolumesRecursively(VolumeHandle *, VP1GeoFlags::VOLSTATE)
Definition: VP1GeometrySystem.cxx:2005
VP1Controller::restoreSettings
void restoreSettings(QByteArray)
Definition: VP1Controller.cxx:387
IVP1System::Imp::information
const QString information
Definition: IVP1System.cxx:38
IVP13DSystem::Imp::start_changeselection
static void start_changeselection(void *userdata, SoSelection *sel)
Definition: IVP13DSystem.cxx:94
lumiFormat.i
int i
Definition: lumiFormat.py:92
z
#define z
VolumeTreeModel::enableSubSystem
void enableSubSystem(VP1GeoFlags::SubSystemFlag flag)
Definition: VolumeTreeModel.cxx:245
VP1GeoFlags::MuonEndcapStationMDT
@ MuonEndcapStationMDT
Definition: VP1GeoFlags.h:49
beamspotman.n
n
Definition: beamspotman.py:731
VP1GeometrySystem::m_d
Imp * m_d
Definition: VP1GeometrySystem.h:103
IVP13DSystemSimple::systemerase
virtual void systemerase()
Definition: IVP13DSystemSimple.cxx:28
LArG4ShowerLibProcessing.hits
hits
Definition: LArG4ShowerLibProcessing.py:136
VP1GeometrySystem::autoAdaptPixelsOrSCT
void autoAdaptPixelsOrSCT(bool, bool, bool, bool, bool, bool)
Definition: VP1GeometrySystem.cxx:2247
VisAttributes::applyState
void applyState(QByteArray)
Definition: VisAttributes.cxx:61
VP1JobConfigInfo::hasSCTGeometry
static bool hasSCTGeometry()
Definition: VP1JobConfigInfo.cxx:128
VP1GeometrySystem::Imp::sonodesep2volhandle
std::map< SoSeparator *, VolumeHandle * > sonodesep2volhandle
Definition: VP1GeometrySystem.cxx:114
VolumeHandle::copyNumber
int copyNumber() const
Definition: VolumeHandle.cxx:455
file
TFile * file
Definition: tile_monitor.h:29
VP1GeoFlags::LAr
@ LAr
Definition: VP1GeoFlags.h:39
VP1GeoFlags::MuonEndcapStationTGC
@ MuonEndcapStationTGC
Definition: VP1GeoFlags.h:47
VP1GeoFlags::VOLSTATE
VOLSTATE
Definition: VP1GeoFlags.h:87
IVP1System::name
const QString & name() const
Definition: IVP1System.cxx:50
IVP1System::REFRESHED
@ REFRESHED
Definition: IVP1System.h:143
VP1GeometrySystem::Imp::showPixelModules
void showPixelModules(VolumeHandle *)
Definition: VP1GeometrySystem.cxx:2443
IVP1System::Imp::activeState
ActiveState activeState
Definition: IVP1System.cxx:43
VP1GeometrySystem::setLabelPosOffsets
void setLabelPosOffsets(const QList< int > &)
Definition: VP1GeometrySystem.cxx:2866
VP1GeoFlags::OpenMDTChambers
@ OpenMDTChambers
Definition: VP1GeoFlags.h:78
VP1GeometrySystem::Imp::subsysInfoList
QList< SubSystemInfo * > subsysInfoList
Definition: VP1GeometrySystem.cxx:225
VP1GeometrySystem::Imp::expandVisibleVolumesRecursively
void expandVisibleVolumesRecursively(VolumeHandle *, const QRegExp &, bool bymatname)
Definition: VP1GeometrySystem.cxx:2095
VolumeHandle::nChildren
unsigned nChildren() const
Definition: VolumeHandle.h:149
IVP13DSystemSimple::systemcreate
virtual void systemcreate(StoreGateSvc *detstore)
Definition: IVP13DSystemSimple.cxx:23
IVP13DSystemSimple::ensureBuildController
void ensureBuildController()
Definition: IVP13DSystemSimple.cxx:90
GeoSysController::setComplexity
void setComplexity(double)
Definition: GeoSysController.cxx:260
VP1GeoFlags::AllUnrecognisedVolumes
@ AllUnrecognisedVolumes
Definition: VP1GeoFlags.h:73
IVP1System::Imp::allowupdategui
bool allowupdategui
Definition: IVP1System.cxx:41
VP1GeometrySystem::checkboxChanged
void checkboxChanged()
Definition: VP1GeometrySystem.cxx:774
VP1Deserialise
Definition: VP1Deserialise.h:44
selection
std::string selection
Definition: fbtTestBasics.cxx:73
IVP1System::UNCREATED
@ UNCREATED
Definition: IVP1System.h:143
IVP1System::eventStore
StoreGateSvc * eventStore() const
Definition: IVP1System.cxx:312
GeoSysController::printInfoOnClick_Tree
bool printInfoOnClick_Tree() const
Definition: GeoSysController.cxx:424
VP1GeometrySystem::resetSubSystems
void resetSubSystems(VP1GeoFlags::SubSystemFlags)
Definition: VP1GeometrySystem.cxx:1517
VP1GeometrySystem::setShowVolumeOutLines
void setShowVolumeOutLines(bool)
Definition: VP1GeometrySystem.cxx:2760
VolumeHandle
Definition: VolumeHandle.h:21
IVP1System::sysmessage
void sysmessage(QString) const
VP1GeometrySystem::Imp::catchKbdState
static void catchKbdState(void *userData, SoEventCallback *CB)
Definition: VP1GeometrySystem.cxx:505
VolumeTreeModel
Definition: VolumeTreeModel.h:14
VP1AthenaPtrs::serviceLocator
static ISvcLocator * serviceLocator()
Definition: VP1AthenaPtrs.h:29
IVP1System::ON
@ ON
Definition: IVP1System.h:144
IVP13DSystemSimple::Imp::first
bool first
Definition: IVP13DSystemSimple.cxx:43
VP1AthenaPtrs::eventStore
static StoreGateSvc * eventStore()
Definition: VP1AthenaPtrs.h:27
VP1GeometrySystem::Imp::showSCTBarrelModules
void showSCTBarrelModules(VolumeHandle *)
Definition: VP1GeometrySystem.cxx:2624
VP1QtInventorUtils::sbcol2qcol
static QColor sbcol2qcol(const SbColor &)
Definition: VP1QtInventorUtils.cxx:1140
GeoSysController::setOrientViewToMuonChambersOnClick
void setOrientViewToMuonChambersOnClick(bool)
Definition: GeoSysController.cxx:272
grepfile.sep
sep
Definition: grepfile.py:38
VP1GeometrySystem::adaptMuonChambersToEventData
void adaptMuonChambersToEventData()
Definition: VP1GeometrySystem.cxx:1539
VisAttributes::getState
QByteArray getState(bool onlyChangedMaterials=true)
Definition: VisAttributes.cxx:32
IVP13DSystem::Imp::staticcameras
std::set< SoCamera * > staticcameras
Definition: IVP13DSystem.cxx:36
VP1GeometrySystem::Imp::volumetreemodel
VolumeTreeModel * volumetreemodel
Definition: VP1GeometrySystem.cxx:246
VolumeTreeModel::cleanup
void cleanup()
Definition: VolumeTreeModel.cxx:153
ParticleGun_EoverP_Config.pg
pg
Definition: ParticleGun_EoverP_Config.py:61
IVP1System::messageDebug
void messageDebug(const QString &) const
Definition: IVP1System.cxx:347
python.selection.number
number
Definition: selection.py:20
IVP1System::detectorStore
StoreGateSvc * detectorStore() const
Definition: IVP1System.cxx:318
IVP13DSystemSimple::Imp::controllerBuilt
bool controllerBuilt
Definition: IVP13DSystemSimple.cxx:42
VP1AthenaPtrs::toolSvc
static IToolSvc * toolSvc()
Definition: VP1AthenaPtrs.h:30
VP1GeometrySystem::Imp::restoredTopvolstates
QMap< quint32, QByteArray > restoredTopvolstates
Definition: VP1GeometrySystem.cxx:291
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
VP1GeometrySystem::setLabels
void setLabels(int)
Definition: VP1GeometrySystem.cxx:2872
GeoSysController::printInfoOnClick_Mass
bool printInfoOnClick_Mass() const
Definition: GeoSysController.cxx:430
VP1GeometrySystem::Imp::kbEvent
const SoKeyboardEvent * kbEvent
Definition: VP1GeometrySystem.cxx:255
IVP13DSystemSimple::Imp::getNodesWithDisabledNotifications
void getNodesWithDisabledNotifications(SoGroup *, QList< SoNode * > &) const
Definition: IVP13DSystemSimple.cxx:240
IVP1System::Imp::controller
QWidget * controller
Definition: IVP1System.cxx:44
VP1Msg::prefix_debug
static const char * prefix_debug()
Definition: VP1Msg.h:57
VP1GeometrySystem::Imp::stationInfo
QStringList stationInfo(const MuonGM::MuonStation *)
Definition: VP1GeometrySystem.cxx:2233
VolumeHandle::getName
QString getName() const
Definition: VolumeHandle.cxx:169
GeoSysController::volumeTreeBrowser
VP1GeoTreeView * volumeTreeBrowser() const
Definition: GeoSysController.cxx:370
IVP1System::registerController
void registerController(QWidget *)
Definition: IVP1System.cxx:224
VP1GeometrySystem::saveMaterialsToFile
void saveMaterialsToFile(const QString &, bool)
Definition: VP1GeometrySystem.cxx:2769
VP1GeoFlags::LUCID
@ LUCID
Definition: VP1GeoFlags.h:55
python.SystemOfUnits.mm
int mm
Definition: SystemOfUnits.py:83
VP1GeoFlags::ZAPPED
@ ZAPPED
Definition: VP1GeoFlags.h:89
VolumeHandleSharedData::setShowVolumeOutlines
static void setShowVolumeOutlines(SoGroup *nodesep, bool showvol)
Definition: VolumeHandleSharedData.cxx:137
python.PyAthena.v
v
Definition: PyAthena.py:157
GeoSysController::lastSelectedVolume
VolumeHandle * lastSelectedVolume() const
Definition: GeoSysController.cxx:300
VP1GeoFlags::toString
static QString toString(const VOLSTATE &)
Definition: VP1GeoFlags.cxx:18
VP1GeometrySystem::Imp::showITkStripModules
void showITkStripModules(VolumeHandle *, bool brl, bool ecA, bool ecC)
Definition: VP1GeometrySystem.cxx:2603
VP1GeoFlags::MuonBarrelStationMiddle
@ MuonBarrelStationMiddle
Definition: VP1GeoFlags.h:44
VP1GeometrySystem::Imp::pv2MuonStation
std::map< GeoPVConstLink, const MuonGM::MuonStation * > pv2MuonStation
Definition: VP1GeometrySystem.cxx:277
DeMoScan.index
string index
Definition: DeMoScan.py:362
VP1Msg::prefix_verbose
static const char * prefix_verbose()
Definition: VP1Msg.h:59
IVP13DSystemSimple::updateGUI
void updateGUI()
Definition: IVP13DSystemSimple.h:89
IVP13DSystem::getCameraList
CamList getCameraList()
Definition: IVP13DSystem.cxx:395
VP1Msg::messageDebug
static void messageDebug(const QString &)
Definition: VP1Msg.cxx:39
y
#define y
IVP13DSystem::Imp::made_deselection
static void made_deselection(void *userdata, SoPath *path)
Definition: IVP13DSystem.cxx:227
CondAlgsOpts.found
int found
Definition: CondAlgsOpts.py:101
VP1GeometrySystem::Imp::exclusiveMass
static double exclusiveMass(const PVConstLink &pv)
Definition: VP1GeometrySystem.cxx:1261
IVP1System::updateGUI
void updateGUI()
Definition: IVP1System.cxx:262
IVP1System::Imp::channel
IVP1ChannelWidget * channel
Definition: IVP1System.cxx:40
VisAttributes::overrideTransparencies
void overrideTransparencies(float transpfact)
Definition: VisAttributes.cxx:137
Pythia8_RapidityOrderMPI.val
val
Definition: Pythia8_RapidityOrderMPI.py:14
IVP13DSystemSimple::warnOnDisabledNotifications
void warnOnDisabledNotifications() const
Definition: IVP13DSystemSimple.cxx:221
VP1GeometrySystem::autoExpandByVolumeOrMaterialName
void autoExpandByVolumeOrMaterialName(bool, const QString &)
Definition: VP1GeometrySystem.cxx:2058
IVP13DSystem::Imp::selectionsWithDisabledNotifications
QSet< SoCooperativeSelection * > selectionsWithDisabledNotifications
Definition: IVP13DSystem.cxx:50
CxxUtils::reset
constexpr std::enable_if_t< is_bitmask_v< E >, E & > reset(E &lhs, E rhs)
Convenience function to clear bits in a class enum bitmask.
Definition: bitmask.h:243
Amg::EigenTransformToCLHEP
HepGeom::Transform3D EigenTransformToCLHEP(const Amg::Transform3D &eigenTransf)
Converts an Eigen-based Amg::Transform3D into a CLHEP-based HepGeom::Transform3D.
Definition: CLHEPtoEigenConverter.h:120
IVP13DSystemSimple::m_d
Imp * m_d
Definition: IVP13DSystemSimple.h:79
VolumeHandle::VolumeHandleListItr
VolumeHandleList::iterator VolumeHandleListItr
Definition: VolumeHandle.h:65
VolumeHandle::state
VP1GeoFlags::VOLSTATE state() const
Definition: VolumeHandle.h:152
VP1GeoFlags::HideMDTTubes
@ HideMDTTubes
Definition: VP1GeoFlags.h:81
CaloCellTimeCorrFiller.filename
filename
Definition: CaloCellTimeCorrFiller.py:24
GeoSysController::printInfoOnClick_Transform
bool printInfoOnClick_Transform() const
Definition: GeoSysController.cxx:418
VP1GeoFlags::MuonBarrelStationOuter
@ MuonBarrelStationOuter
Definition: VP1GeoFlags.h:45
VP1GeometrySystem::Imp::ensureInitVisAttributes
void ensureInitVisAttributes()
Definition: VP1GeometrySystem.cxx:236
PhiSectorManager::updateRepresentationsOfVolsAroundZAxis
void updateRepresentationsOfVolsAroundZAxis()
Definition: PhiSectorManager.cxx:483
checkFileSG.fi
fi
Definition: checkFileSG.py:65
IVP13DSystem::Imp::finished_changeselection
static void finished_changeselection(void *userdata, SoSelection *sel)
Definition: IVP13DSystem.cxx:121
VP1GeometrySystem::loadMaterialsFromFile
void loadMaterialsFromFile(const QString &)
Definition: VP1GeometrySystem.cxx:2808
GeoSysController::labels
int labels() const
Definition: GeoSysController.cxx:520
PhiSectorManager
Definition: PhiSectorManager.h:30
VolumeHandle::getLocalTransformToVolume
SbMatrix getLocalTransformToVolume() const
Definition: VolumeHandle.cxx:494
VP1JobConfigInfo::hasITkGeometry
static bool hasITkGeometry()
Definition: VP1JobConfigInfo.cxx:126
str
Definition: BTagTrackIpAccessor.cxx:11
python.SystemOfUnits.kilogram
int kilogram
Definition: SystemOfUnits.py:164
IVP13DSystem::userClickedOnBgd
virtual void userClickedOnBgd()
Definition: IVP13DSystem.cxx:62
VP1Msg::verbose
static bool verbose()
Definition: VP1Msg.h:31
VP1GeoFlags::SubSystemFlag
SubSystemFlag
Definition: VP1GeoFlags.h:30
VP1GeometrySystem::plotSpectrum
void plotSpectrum(QStack< QString > &, int copyNumber=-1)
VP1SGAccessHelper
Definition: VP1SGAccessHelper.h:25
VP1GeoFlags::BarrelToroid
@ BarrelToroid
Definition: VP1GeoFlags.h:41
COOLRates.target
target
Definition: COOLRates.py:1106
VP1JobConfigInfo::hasMuonNSWGeometry
static bool hasMuonNSWGeometry()
Definition: VP1JobConfigInfo.cxx:135
VP1JobConfigInfo::hasPixelGeometry
static bool hasPixelGeometry()
Definition: VP1JobConfigInfo.cxx:127
GeoSysController::setLastSelectedVolume
void setLastSelectedVolume(VolumeHandle *)
Definition: GeoSysController.cxx:284
VP1GeometrySystem::Imp::matVisAttributes
MatVisAttributes * matVisAttributes
Definition: VP1GeometrySystem.cxx:234
IVP13DSystem::Imp::clickedoutsideScheduled
bool clickedoutsideScheduled
Definition: IVP13DSystem.cxx:53
VP1GeoFlags::SCT
@ SCT
Definition: VP1GeoFlags.h:35
python.IoTestsLib.w
def w
Definition: IoTestsLib.py:200
IVP1System::Imp::canregistercontroller
bool canregistercontroller
Definition: IVP1System.cxx:46
VP1AthenaPtrs::detectorStore
static StoreGateSvc * detectorStore()
Definition: VP1AthenaPtrs.h:28
IVP13DSystemSimple::Imp::wascreated
bool wascreated
Definition: IVP13DSystemSimple.cxx:41
VP1GeometrySystem::Imp::updateTouchedMuonChamber
void updateTouchedMuonChamber(VolumeHandle *chamberhandle)
Definition: VP1GeometrySystem.cxx:1621
VP1GeometrySystem::updateTransparency
void updateTransparency()
Definition: VP1GeometrySystem.cxx:1501
VP1GeometrySystem::Imp::showSCTEndcapModules
void showSCTEndcapModules(VolumeHandle *)
Definition: VP1GeometrySystem.cxx:2692
VP1JobConfigInfo::hasMuonGeometry
static bool hasMuonGeometry()
Definition: VP1JobConfigInfo.cxx:134
VP1GeometrySystem::volumeStateChangeRequested
void volumeStateChangeRequested(VolumeHandle *, VP1GeoFlags::VOLSTATE)
Definition: VP1GeometrySystem.cxx:2739
PrepareReferenceFile.outfile
outfile
Definition: PrepareReferenceFile.py:42
VP1CameraHelper::animatedZoomToSubTree
static VP1CameraHelper * animatedZoomToSubTree(SoCamera *camera, SoGroup *sceneroot, SoNode *subtreeroot, double duration_in_secs=1.0, double clipVolPercent=100.0, double lastClipVolPercent=100.0, double slack=1.0, const SbVec3f &lookat=SbVec3f(999, 999, 999), const SbVec3f &upvec=SbVec3f(999, 999, 999), bool varySpeed=true, bool forceCircular=false)
Definition: VP1CameraHelper.cxx:413
IVP13DSystem::m_d
Imp * m_d
Definition: IVP13DSystem.h:116
VP1GeometrySystem::Imp::addSubSystem
void addSubSystem(const VP1GeoFlags::SubSystemFlag &, const QString &treetopregexp, const QString &childrenregexp="", const std::string &matname="", bool negatetreetopregexp=false, bool negatechildrenregexp=false, const QString &grandchildrenregexp="", bool negategrandchildrenregexp=false)
Definition: VP1GeometrySystem.cxx:365
python.compressB64.c
def c
Definition: compressB64.py:93
VP1GeometrySystem::Imp::getClosestMuonDriftTubeDirections
std::pair< SbVec3f, SbVec3f > getClosestMuonDriftTubeDirections(const SbVec3f &cameraDirection, const SbVec3f &cameraUpDirection, VolumeHandle *chamberhandle)
Definition: VP1GeometrySystem.cxx:1906
length
double length(const pvec &v)
Definition: FPGATrackSimLLPDoubletHoughTransformTool.cxx:26
GeoSysController::printInfoOnClick_MuonStationInfo
bool printInfoOnClick_MuonStationInfo() const
Definition: GeoSysController.cxx:436
VP1GeoFlags::CavernInfra
@ CavernInfra
Definition: VP1GeoFlags.h:51
GeoSysController::setGeometrySelectable
void setGeometrySelectable(bool)
Definition: GeoSysController.cxx:253
VP1QtInventorUtils::changePathTail
static bool changePathTail(SoPath *path, SoNode *commonBranchPoint, SoNode *newtail)
Definition: VP1QtInventorUtils.cxx:1346
IVP1System::message
void message(const QString &) const
Definition: IVP1System.cxx:336
VolumeHandle::getGlobalTransformToVolume
const SbMatrix & getGlobalTransformToVolume() const
Definition: VolumeHandle.cxx:489
VP1GeoFlags::ZDC
@ ZDC
Definition: VP1GeoFlags.h:56
IVP13DSystem::deselectAll
virtual void deselectAll(SoCooperativeSelection *exception_sel=0)
Definition: IVP13DSystem.cxx:331
IVP1System::OFF
@ OFF
Definition: IVP1System.h:144
SiliconTech::pixel
@ pixel
VP1GeometrySystem::Imp::last_appropriatemdtprojections
int last_appropriatemdtprojections
Definition: VP1GeometrySystem.cxx:268
IVP1System::Imp::state
State state
Definition: IVP1System.cxx:42
IVP1System::messageVerbose
void messageVerbose(const QString &) const
Definition: IVP1System.cxx:354
VP1GeoFlags::TRT
@ TRT
Definition: VP1GeoFlags.h:36
node
Definition: memory_hooks-stdcmalloc.h:74
IVP1System::ERASED
@ ERASED
Definition: IVP1System.h:143
VP1GeoFlags::CONTRACTED
@ CONTRACTED
Definition: VP1GeoFlags.h:87
GeoSysController::printInfoOnClick_Shape
bool printInfoOnClick_Shape() const
Definition: GeoSysController.cxx:400
VP1GeometrySystem::Imp::createPathExtras
void createPathExtras(const VolumeHandle *, QString &, QStack< QString > &)
Definition: VP1GeometrySystem.cxx:1406
VP1JobConfigInfo::hasGeoModelExperiment
static bool hasGeoModelExperiment()
Definition: VP1JobConfigInfo.cxx:125
IVP1System::Imp::name
const QString name
Definition: IVP1System.cxx:37
IVP13DSystemSimple::Imp::wasrefreshed
bool wasrefreshed
Definition: IVP13DSystemSimple.cxx:40
GeoSysController::printInfoOnClick_CopyNumber
bool printInfoOnClick_CopyNumber() const
Definition: GeoSysController.cxx:412
VP1GeometrySystem::Imp::ensureInitPV2MuonStationMap
void ensureInitPV2MuonStationMap()
Definition: VP1GeometrySystem.cxx:2189
VP1GeoFlags::Tile
@ Tile
Definition: VP1GeoFlags.h:40
IVP1System::restoreFromState
virtual void restoreFromState(QByteArray)
Definition: IVP1System.cxx:302
VP1GeoFlags::AFP
@ AFP
Definition: VP1GeoFlags.h:67