ATLAS Offline Software
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
AscObj_TrackState Class Reference

#include <AscObj_TrackState.h>

Inheritance diagram for AscObj_TrackState:
Collaboration diagram for AscObj_TrackState:

Public Types

enum  PICKSTYLE { UNPICKABLE, ALL, COMPONENTS }
 

Public Member Functions

 AscObj_TrackState (TrackHandleBase *, unsigned indexOfPointOnTrack, const typename ActsTrk::TrackStateBackend::ConstTrackStateProxy &state)
 
void setDistToNextPar (const double &)
 
void buildShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
 
QStringList clicked ()
 
void zoomView ()
 Depending on the controller settings, will attempt to zoom the view to this TSOS, for example in click() More...
 
bool isShortMeasurement ()
 Return true if TRT/MDT & shortened mode is on, false otherwise
More...
 
virtual void setVisible (bool)
 
virtual TrackCommonFlags::TSOSPartsFlags parts () const
 
const Acts::Surface & surface () const
 
const ActsTrk::TrackStateBackend::ConstTrackStateProxy trackState () const
 
Amg::Vector3D approxCenter () const
 
virtual bool initiatesOwnZooms () const
 
virtual QTreeWidgetItem * browserTreeItem () const
 
virtual void setBrowserTreeItem (QTreeWidgetItem *obt)
 
virtual unsigned nParts () const
 
bool hasParameters () const
 
bool hasParError () const
 
bool hasError () const
 
bool hasMaterialEffect () const
 
bool hasSurface () const
 
bool hasMeasurement () const
 
TrackSysCommonDatacommon () const
 
void setPickable (PICKSTYLE)
 
PICKSTYLE pickStyle () const
 
bool visible () const
 
void toggleVisible ()
 
TrackHandleBasetrackHandle () const
 
void update3DObjects ()
 
SoSeparator * shapeSimple () const
 
SoSeparator * shapeDetailed () const
 

Static Public Member Functions

static int numberOfInstances ()
 

Protected Member Functions

int regionIndex () const
 
double lodCrossOverValue () const
 

Private Member Functions

virtual ~AscObj_TrackState ()
 
void addTrackParamInfoToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed, bool showPars, bool showParsErrors, bool showSurfaces)
 
void addSurfaceToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
 
void addMaterialToSurfaceShapes (SoNode *&shape_simple, SoNode *&shape_detailed)
 
void addPlaneSurfaceToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed, const Acts::Surface &surface)
 
void addCylindricalSurfaceToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed, const Acts::Surface &surface)
 
void addMaterialEffectsToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
 
void addMeasurementToShapes (SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
 
void registerShapes (SoSeparator *simple, SoSeparator *detailed)
 
void unregisterShapes (SoSeparator *simple, SoSeparator *detailed)
 
AssocObjAttachmentHandlegetAttachmentHandle ()
 

Static Private Member Functions

static void ensureInitSeps (SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
 

Private Attributes

TrackCommonFlags::TSOSPartsFlags m_parts
 
unsigned m_indexOfPointOnTrack
 
double m_distToNextPar
 
QTreeWidgetItem * m_objBrowseTree
 
const ActsTrk::TrackStateBackend::ConstTrackStateProxy m_trackstate
 
Impm_d
 
TrackHandleBasem_trackHandle
 
bool m_visible
 
PICKSTYLE m_pickStyle
 

Detailed Description

Definition at line 29 of file AscObj_TrackState.h.

Member Enumeration Documentation

◆ PICKSTYLE

Enumerator
UNPICKABLE 
ALL 
COMPONENTS 

Definition at line 57 of file AssociatedObjectHandleBase.h.

Constructor & Destructor Documentation

◆ AscObj_TrackState()

AscObj_TrackState::AscObj_TrackState ( TrackHandleBase track,
unsigned  indexOfPointOnTrack,
const typename ActsTrk::TrackStateBackend::ConstTrackStateProxy &  state 
)

Definition at line 55 of file AscObj_TrackState.cxx.

60  m_indexOfPointOnTrack(indexOfPointOnTrack),
61  m_distToNextPar(-1),
62  m_objBrowseTree(nullptr),
63  m_trackstate(trackstate)
64 {
66  if (m_trackstate.hasReferenceSurface()) {
67  if (surface().associatedDetectorElement())
69  else
71  }
72 
73  if (m_trackstate.typeFlags().test(Acts::TrackStateFlag::ParameterFlag ))
75 
76  if (m_trackstate.typeFlags().test(Acts::TrackStateFlag::MeasurementFlag)){
78  if (m_trackstate.typeFlags().test(Acts::TrackStateFlag::OutlierFlag ))
80  else
82  }
83 
84  if (m_trackstate.typeFlags().test(Acts::TrackStateFlag::HoleFlag))
86 
87  if (m_trackstate.typeFlags().test(Acts::TrackStateFlag::MaterialFlag ))
89 }

◆ ~AscObj_TrackState()

virtual AscObj_TrackState::~AscObj_TrackState ( )
inlineprivatevirtual

Definition at line 59 of file AscObj_TrackState.h.

59 {}//Private so it can only be deleted by TrackHandleBase

Member Function Documentation

◆ addCylindricalSurfaceToShapes()

void AscObj_TrackState::addCylindricalSurfaceToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed,
const Acts::Surface &  surface 
)
private

Definition at line 322 of file AscObj_TrackState.cxx.

324  {
325  SoNode * nodeToAddSimple = nullptr;
326  SoNode * nodeToAddDetailed = nullptr;
327  // Check bounds
328  switch (surface.bounds().type()) {
329  case Acts::SurfaceBounds::BoundsType::eLine: {
330  const Acts::LineBounds& lineBounds =
331  dynamic_cast<const Acts::LineBounds&>(surface.bounds());
332  double hlength = lineBounds.get(Acts::LineBounds::eHalfLengthZ);
333 
334  SoVertexProperty * scatVtxProperty = new SoVertexProperty();
335  scatVtxProperty->vertex.set1Value(0, 0.0,0.0,-hlength);
336  scatVtxProperty->vertex.set1Value(1, 0.0,0.0, hlength);
337  SoLineSet * lineSurface = new SoLineSet();
338  lineSurface->numVertices = 2;
339  lineSurface->vertexProperty = scatVtxProperty;
340 
341  nodeToAddSimple = lineSurface;
342 
343  double radius = lineBounds.get(Acts::LineBounds::eR);
344 
345  SoTubs* lineSurfaceDetailed = new SoTubs();
346  (*lineSurfaceDetailed).pRMin = 0.;
347  (*lineSurfaceDetailed).pRMax = radius;
348  (*lineSurfaceDetailed).pDz = hlength;
349 
350  nodeToAddDetailed = lineSurfaceDetailed;
351  break;
352  }
353  default: {
354  VP1Msg::messageVerbose("AscObj_TrackState::addCylindricalSurfaceToShapes(): Unsupported bounds type.");
355  break;
356  }
357  }
358  if (nodeToAddDetailed!=nullptr){
359  addMaterialToSurfaceShapes(nodeToAddSimple, nodeToAddDetailed);
360  shape_simple->addChild(nodeToAddDetailed);
361  shape_detailed->addChild(nodeToAddDetailed);
362  }
363 }

◆ addMaterialEffectsToShapes()

void AscObj_TrackState::addMaterialEffectsToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed 
)
private
Parameters
shape_simpleshape_simple
shape_detailedshape_detailed

Definition at line 366 of file AscObj_TrackState.cxx.

367  {}

◆ addMaterialToSurfaceShapes()

void AscObj_TrackState::addMaterialToSurfaceShapes ( SoNode *&  shape_simple,
SoNode *&  shape_detailed 
)
private
Parameters
shape_simpleshape_simple

Definition at line 254 of file AscObj_TrackState.cxx.

255  {
256  if (trackHandle()->customColouredTSOSParts()&TrackCommonFlags::TSOS_AnySurface) {
257  SoMaterial * mat = common()->controller()->customMatSurfaces();
258  if (shape_detailed->getTypeId().isDerivedFrom(SoSeparator::getClassTypeId())) {
259  // static_cast<SoSeparator*>(theSurfSepSimple)->insertChild(mat,0); TODO
260  static_cast<SoSeparator*>(shape_detailed)->insertChild(mat,0);
261  } else {
262 
263  // SoSeparator * sepSimple = new SoSeparator;
264  // sepSimple->addChild(mat);
265  // sepSimple->addChild(theSurfSepSimple);
266  // nodeToAddSimple = sepSimple;
267  // TODO ^
268  SoSeparator * sep = new SoSeparator;
269  sep->addChild(mat);
270  sep->addChild(shape_detailed);
271  shape_detailed = sep;
272  }
273  }
274 }

◆ addMeasurementToShapes()

void AscObj_TrackState::addMeasurementToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed 
)
private

Definition at line 369 of file AscObj_TrackState.cxx.

370  {
371 
372  auto flag = m_trackstate.typeFlags();
373 
374  // Check if the TrackStateProxy has a measurement
375  if (!m_trackstate.hasReferenceSurface() ||
376  !flag.test(Acts::TrackStateFlag::MeasurementFlag ||
377  !(m_trackstate.hasUncalibratedSourceLink())))
378  return;
379 
380  ensureInitSeps(shape_simple, shape_detailed);
381  TrackCommonFlags::TSOSPartsFlags f(trackHandle()->shownTSOSParts() & m_parts);
382  const bool showMeas(f & TrackCommonFlags::TSOS_AnyMeasurement);
383  // const bool showMeasErrors(f & TrackCommonFlags::TSOS_MeasError);
384  if (showMeas) {
385  if (m_parts & trackHandle()->customColouredTSOSParts() &
387  SoMaterial* mat;
388  if (m_parts & trackHandle()->customColouredTSOSParts() &
391  else
393  shape_simple->addChild(mat);
394  shape_detailed->addChild(mat);
395  }
396 
397  // Handle measurements
398  auto sl = m_trackstate.getUncalibratedSourceLink()
400  assert(sl != nullptr);
401  const xAOD::UncalibratedMeasurement& uncalibMeas =
403 
404  const xAOD::UncalibMeasType measurementType = uncalibMeas.type();
405 
406  switch (measurementType) {
408  // Drift tubes
409  break;
410  }
417  // TODO
418  break;
419  }
421  // TODO
422  break;
423  }
425  default: {
427  "AscObj_TrackState::addMeasurementToShapes: Unable to handle this "
428  "measurement type ");
429  break;
430  }
431  }
432  }
433 }

◆ addPlaneSurfaceToShapes()

void AscObj_TrackState::addPlaneSurfaceToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed,
const Acts::Surface &  surface 
)
private

Definition at line 276 of file AscObj_TrackState.cxx.

278  {
279 
280  SoNode * nodeToAddSimple = nullptr;
281  SoNode * nodeToAddDetailed = nullptr;
282 
283  // Check bounds
284  switch (surface.bounds().type()) {
285  case Acts::SurfaceBounds::BoundsType::eBoundless: {
286  const double halfX = 100.0; // FIXME - make this configurable?
287  const double halfY = 100.0;
288  SoGenericBox* box = new SoGenericBox;
289  box->setParametersForBox(halfX, halfY,
290  0.5 * surfaceThickness);
291  box->drawEdgeLines.setValue(true);
292  nodeToAddDetailed = box;
293  break;
294  }
295  case Acts::SurfaceBounds::BoundsType::eRectangle: {
296 
297  const Acts::RectangleBounds& rectBounds =
298  dynamic_cast<const Acts::RectangleBounds&>(surface.bounds());
299  const double halfX = rectBounds.halfLengthX();
300  const double halfY = rectBounds.halfLengthY();
301  SoGenericBox* box = new SoGenericBox;
302  box->setParametersForBox(halfX, halfY,
303  0.5 * surfaceThickness);
304  box->drawEdgeLines.setValue(true);
305  nodeToAddDetailed = box;
306  // TODO simple
307  break;
308  }
309  default: {
310  VP1Msg::messageVerbose("Cannot currently handle surface bound of type" + QString::number(surface.bounds().type()));
311  break;
312  }
313  }
314 
315  if (nodeToAddDetailed!=nullptr){
316  addMaterialToSurfaceShapes(nodeToAddSimple, nodeToAddDetailed);
317  shape_simple->addChild(nodeToAddDetailed); // FIXME
318  shape_detailed->addChild(nodeToAddDetailed);
319  }
320 }

◆ addSurfaceToShapes()

void AscObj_TrackState::addSurfaceToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed 
)
private

Definition at line 192 of file AscObj_TrackState.cxx.

193  {
194  // VP1Msg::messageVerbose("\tAscObj_TrackState::addSurfaceToShapes() start. Type="+QString::number(surface().type())+" Bounds="+QString::number(surface().bounds().type()));
195  // Check if the TrackStateProxy has a surface
196 
197  if (!m_trackstate.hasReferenceSurface())
198  return;
199 
200  const Acts::Surface& surface = m_trackstate.referenceSurface();
201  if (surface.type()==Acts::Surface::SurfaceType::Straw && common()->controller()->hideTubeSurfaces())
202  return;
203 
204  SoTransform* sotra = VP1LinAlgUtils::toSoTransform(surface.transform(common()->geometryContext().context()));
205  shape_detailed->addChild(sotra);
206 
207  //
208  // enum SurfaceType {
209  // Cone = 0,
210  // Cylinder = 1,
211  // Disc = 2,
212  // Perigee = 3,
213  // Plane = 4,
214  // Straw = 5,
215  // Curvilinear = 6,
216  // Other = 7
217  // };
218 
219  // enum BoundsType : int {
220  // eCone = 0,
221  // eCylinder = 1,
222  // eDiamond = 2,
223  // eDisc = 3,
224  // eEllipse = 4,
225  // eLine = 5,
226  // eRectangle = 6,
227  // eTrapezoid = 7,
228  // eTriangle = 8,
229  // eDiscTrapezoid = 9,
230  // eConvexPolygon = 10,
231  // eAnnulus = 11,
232  // eBoundless = 12,
233  // eOther = 13
234  // };
235 
236 
237 
238  switch (surface.type()) {
240  addPlaneSurfaceToShapes(shape_simple, shape_detailed, surface);
241  break;
242  }
244  addCylindricalSurfaceToShapes(shape_simple, shape_detailed, surface);
245  break;
246  }
247  default:
248  VP1Msg::messageVerbose("Cannot currently handle surface of type" + QString::number(surface.type()));
249  break;
250  }
251  VP1Msg::messageVerbose("AscObj_TrackState::addSurfaceToShapes() end");
252 }

◆ addTrackParamInfoToShapes()

void AscObj_TrackState::addTrackParamInfoToShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed,
bool  showPars,
bool  showParsErrors,
bool  showSurfaces 
)
private
Parameters
showSurfacesshowSurfaces

Definition at line 119 of file AscObj_TrackState.cxx.

123  {
124  ensureInitSeps(shape_simple, shape_detailed);
125 
126  SoSeparator* param_simple = new SoSeparator;
127  SoSeparator* param_detailed = new SoSeparator;
128 
129  if (!m_trackstate.hasReferenceSurface()) {
130  // FIXME - do not know how to handle this yet, since I think I need the
131  // surface to get the position
133  "AscObj_TrackState::addTrackParamInfoToShapes() - no reference "
134  "surface");
135  return;
136  }
137 
138  const Acts::BoundTrackParameters trackparams(
139  m_trackstate.referenceSurface().getSharedPtr(), m_trackstate.parameters(),
141  auto p1 = trackparams.position(common()->geometryContext().context());
142  if (showPars) {
143  auto u = trackparams.direction().unit();
144  double length = 15 * CLHEP::cm;
145  if (m_distToNextPar > 0)
147  Amg::Vector3D p2 = p1 + length * u;
148  // Line:
149  SoLineSet* line = new SoLineSet();
150  SoVertexProperty* vertices = new SoVertexProperty();
151  vertices->vertex.set1Value(0, p1.x(), p1.y(), p1.z());
152  vertices->vertex.set1Value(1, p2.x(), p2.y(), p2.z());
153  line->numVertices.set1Value(0, 2);
154 
155  // Point:
156  SoPointSet* points = new SoPointSet;
157  SoVertexProperty* vertices2 = new SoVertexProperty;
158  vertices2->vertex.set1Value(0, p1.x(), p1.y(), p1.z());
159  points->numPoints = 1;
160  line->vertexProperty = vertices;
161  points->vertexProperty = vertices2;
162  bool isHole = m_parts & TrackCommonFlags::TSOS_Hole;
163 
164  if (trackHandle()->customColouredTSOSParts() &
166  (isHole && (trackHandle()->customColouredTSOSParts() &
168  SoMaterial* mat = isHole
171  SoSeparator* sep = new SoSeparator;
172  sep->addChild(mat);
173  sep->addChild(line);
174  sep->addChild(points);
175  param_simple->addChild(sep);
176  param_detailed->addChild(sep);
177  } else {
178  param_simple->addChild(line);
179  param_simple->addChild(points);
180  param_detailed->addChild(line);
181  param_detailed->addChild(points);
182  }
183  if (showParsErrors) {
184  // TODO
185  }
186  shape_simple->addChild(param_simple);
187  shape_detailed->addChild(param_detailed);
188  }
189 }

◆ approxCenter()

Amg::Vector3D AscObj_TrackState::approxCenter ( ) const

Definition at line 99 of file AscObj_TrackState.cxx.

99  {
100  if (hasSurface())
101  return surface().center( common()->geometryContext().context() );
103  "AscObj_TrackState::approxCenter() WARNING: Failed to determine"
104  " position from either params or surface");
105  return Amg::Vector3D(0, 0, 0);
106 }

◆ browserTreeItem()

virtual QTreeWidgetItem* AscObj_TrackState::browserTreeItem ( ) const
inlinevirtual

Definition at line 51 of file AscObj_TrackState.h.

51 {return m_objBrowseTree;}

◆ buildShapes()

void AscObj_TrackState::buildShapes ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed 
)
virtual

Implements AssociatedObjectHandleBase.

Definition at line 445 of file AscObj_TrackState.cxx.

446  {
447  VP1Msg::messageVerbose("AscObj_TrackState::buildShapes() start");
448 
449  TrackCommonFlags::TSOSPartsFlags f(trackHandle()->shownTSOSParts()&m_parts);
451  VP1Msg::messageVerbose("AscObj_TrackState::buildShapes() - no objects to show with shownTSOSParts="+QString::number(trackHandle()->shownTSOSParts())+" and m_parts="+QString::number(m_parts));
452  return;
453  }
454  // TODO Implement the following
455  const bool showPars(f & TrackCommonFlags::TSOS_TrackPars);
456  // const bool showParsErrors(f & TrackCommonFlags::TSOS_AnyParsErrors);
457  // const bool showMeas(f & TrackCommonFlags::TSOS_AnyMeasRioOnTrack);
458  // const bool showCompetingRioOnTrack(f & TrackCommonFlags::TSOS_AnyMeasCompetingRioOnTrack);
459  const bool showSurfaces(f & TrackCommonFlags::TSOS_AnySurface);
460  // const bool showMaterialEffects(f & TrackCommonFlags::TSOS_AnyMaterialEffects);
461  // const bool showMeasErrors(f & TrackCommonFlags::TSOS_MeasError);
462  ensureInitSeps(shape_simple,shape_detailed);
463 
464  if (showPars)
465  addTrackParamInfoToShapes( shape_simple, shape_detailed, showPars, false, false);
466 
467  if (showSurfaces)
468  addSurfaceToShapes( shape_simple, shape_detailed);
469 
470  // addMeasurementToShapes is crashing at the moment. Need to investigate
471  // if (showMeas)
472  // addMeasurementToShapes( shape_simple, shape_detailed);
473 
474  VP1Msg::messageVerbose("AscObj_TrackState::buildShapes() end");
475 
476 }

◆ clicked()

QStringList AscObj_TrackState::clicked ( )
virtual

Implements AssociatedObjectHandleBase.

Definition at line 479 of file AscObj_TrackState.cxx.

479  {
480  QStringList l;
481  return l;
482 }

◆ common()

TrackSysCommonData * AssociatedObjectHandleBase::common ( ) const
inherited

Definition at line 105 of file AssociatedObjectHandleBase.cxx.

106 {
107  return m_trackHandle->common();
108 }

◆ ensureInitSeps()

void AscObj_TrackState::ensureInitSeps ( SoSeparator *&  shape_simple,
SoSeparator *&  shape_detailed 
)
staticprivate

Definition at line 436 of file AscObj_TrackState.cxx.

437  {
438  if (!shape_simple)
439  shape_simple = new SoSeparator;
440  if (!shape_detailed)
441  shape_detailed = new SoSeparator;
442 }

◆ getAttachmentHandle()

AssocObjAttachmentHandle * AssociatedObjectHandleBase::getAttachmentHandle ( )
privateinherited

Definition at line 155 of file AssociatedObjectHandleBase.cxx.

156 {
158 }

◆ hasError()

bool AssociatedObjectHandleBase::hasError ( ) const
inlineinherited

Definition at line 50 of file AssociatedObjectHandleBase.h.

◆ hasMaterialEffect()

bool AssociatedObjectHandleBase::hasMaterialEffect ( ) const
inlineinherited

Definition at line 51 of file AssociatedObjectHandleBase.h.

◆ hasMeasurement()

bool AssociatedObjectHandleBase::hasMeasurement ( ) const
inlineinherited

Definition at line 53 of file AssociatedObjectHandleBase.h.

◆ hasParameters()

bool AssociatedObjectHandleBase::hasParameters ( ) const
inlineinherited

Definition at line 48 of file AssociatedObjectHandleBase.h.

◆ hasParError()

bool AssociatedObjectHandleBase::hasParError ( ) const
inlineinherited

Definition at line 49 of file AssociatedObjectHandleBase.h.

◆ hasSurface()

bool AssociatedObjectHandleBase::hasSurface ( ) const
inlineinherited

Definition at line 52 of file AssociatedObjectHandleBase.h.

◆ initiatesOwnZooms()

virtual bool AscObj_TrackState::initiatesOwnZooms ( ) const
inlinevirtual

Reimplemented from AssociatedObjectHandleBase.

Definition at line 49 of file AscObj_TrackState.h.

49 { return true; }

◆ isShortMeasurement()

bool AscObj_TrackState::isShortMeasurement ( )

Return true if TRT/MDT & shortened mode is on, false otherwise

◆ lodCrossOverValue()

double AscObj_TrackState::lodCrossOverValue ( ) const
inlineprotectedvirtual

Reimplemented from AssociatedObjectHandleBase.

Definition at line 56 of file AscObj_TrackState.h.

56 {return 1000; }

◆ nParts()

virtual unsigned AssociatedObjectHandleBase::nParts ( ) const
inlinevirtualinherited

Definition at line 47 of file AssociatedObjectHandleBase.h.

47 { return 1; }

◆ numberOfInstances()

int AssociatedObjectHandleBase::numberOfInstances ( )
staticinherited

Definition at line 130 of file AssociatedObjectHandleBase.cxx.

131 {
132  return Imp::nascobjs;
133 }

◆ parts()

virtual TrackCommonFlags::TSOSPartsFlags AscObj_TrackState::parts ( ) const
inlinevirtual

Reimplemented from AssociatedObjectHandleBase.

Definition at line 42 of file AscObj_TrackState.h.

42 { return m_parts; }

◆ pickStyle()

PICKSTYLE AssociatedObjectHandleBase::pickStyle ( ) const
inlineinherited

Definition at line 59 of file AssociatedObjectHandleBase.h.

59 { return m_pickStyle; }

◆ regionIndex()

int AscObj_TrackState::regionIndex ( ) const
protectedvirtual

Reimplemented from AssociatedObjectHandleBase.

Definition at line 109 of file AscObj_TrackState.cxx.

109  {
111  static const double l = 30.0 * CLHEP::cm;
112  return static_cast<int>(c.z() / l) + 1000 * static_cast<int>(c.y() / l) +
113  1000000 * static_cast<int>(c.x() / l);
114 }

◆ registerShapes()

void AssociatedObjectHandleBase::registerShapes ( SoSeparator *  simple,
SoSeparator *  detailed 
)
privateinherited

Definition at line 93 of file AssociatedObjectHandleBase.cxx.

94 {
96 }

◆ setBrowserTreeItem()

virtual void AscObj_TrackState::setBrowserTreeItem ( QTreeWidgetItem *  obt)
inlinevirtual

Definition at line 52 of file AscObj_TrackState.h.

52 {m_objBrowseTree=obt;}

◆ setDistToNextPar()

void AscObj_TrackState::setDistToNextPar ( const double &  d)

Definition at line 92 of file AscObj_TrackState.cxx.

92  {
93  // We assume this is called right after the constructor - so no need
94  // to update 3D objects.
96 }

◆ setPickable()

void AssociatedObjectHandleBase::setPickable ( PICKSTYLE  ps)
inherited

Definition at line 136 of file AssociatedObjectHandleBase.cxx.

137 {
138  if (m_pickStyle==ps)
139  return;
140  m_pickStyle=ps;
141 
142  //Fixme...
143 
144 }

◆ setVisible()

void AscObj_TrackState::setVisible ( bool  vis)
virtual

Reimplemented from AssociatedObjectHandleBase.

Definition at line 484 of file AscObj_TrackState.cxx.

484  {
486 }

◆ shapeDetailed()

SoSeparator * AssociatedObjectHandleBase::shapeDetailed ( ) const
inherited

Definition at line 206 of file AssociatedObjectHandleBase.cxx.

207 {
208  return m_d->sep_detailed;
209 }

◆ shapeSimple()

SoSeparator * AssociatedObjectHandleBase::shapeSimple ( ) const
inherited

Definition at line 200 of file AssociatedObjectHandleBase.cxx.

201 {
202  return m_d->sep_simple;
203 }

◆ surface()

const Acts::Surface& AscObj_TrackState::surface ( ) const
inline

Definition at line 44 of file AscObj_TrackState.h.

44 { return m_trackstate.referenceSurface(); }

◆ toggleVisible()

void AssociatedObjectHandleBase::toggleVisible ( )
inlineinherited

Definition at line 62 of file AssociatedObjectHandleBase.h.

62 { setVisible(!m_visible); }

◆ trackHandle()

TrackHandleBase* AssociatedObjectHandleBase::trackHandle ( ) const
inlineinherited

Definition at line 64 of file AssociatedObjectHandleBase.h.

64 { return m_trackHandle; }

◆ trackState()

const ActsTrk::TrackStateBackend::ConstTrackStateProxy AscObj_TrackState::trackState ( ) const
inline

Definition at line 46 of file AscObj_TrackState.h.

46 { return m_trackstate; }

◆ unregisterShapes()

void AssociatedObjectHandleBase::unregisterShapes ( SoSeparator *  simple,
SoSeparator *  detailed 
)
privateinherited

Definition at line 99 of file AssociatedObjectHandleBase.cxx.

100 {
102 }

◆ update3DObjects()

void AssociatedObjectHandleBase::update3DObjects ( )
inherited

Definition at line 185 of file AssociatedObjectHandleBase.cxx.

186 {
187  VP1Msg::messageVerbose("AssociatedObjectHandleBase update3DObjects.");
188 
189  if (m_visible) {
190  m_d->detach();
191  m_d->ensureShapesErased(this);
192  m_d->ensureShapesBuild(this);
193  m_d->attach(this);
194  } else {
195  m_d->ensureShapesErased(this);
196  }
197 }

◆ visible()

bool AssociatedObjectHandleBase::visible ( ) const
inlineinherited

Definition at line 61 of file AssociatedObjectHandleBase.h.

61 { return m_visible; }

◆ zoomView()

void AscObj_TrackState::zoomView ( )

Depending on the controller settings, will attempt to zoom the view to this TSOS, for example in click()

Definition at line 488 of file AscObj_TrackState.cxx.

488  {
489  VP1Msg::messageVerbose("AscObj_TrackState::zoomView()");
490  if ( common()->controller()->orientAndZoomOnSingleSelection() )
491  {
492  // Zoom without orientation
493  // TODO - add orientation?
494  VP1Msg::messageVerbose("AscObj_TrackState::zoomView() Zoom without orientation");
495  std::set<SoCamera*> cameras = common()->system()->getCameraList();
496  std::set<SoCamera*>::iterator it,itE = cameras.end();
497  for (it=cameras.begin();it!=itE;++it) {
498  if (common()->controller()->assocObjDetailLevel()==TrackCommonFlags::SIMPLE)
499  {
500  VP1CameraHelper::animatedZoomToSubTree(*it,common()->ascObjSelectionManager()->getAscObjAttachSep(),shapeSimple(),2.0,1.0);
501  } else
502  {
503  VP1CameraHelper::animatedZoomToSubTree(*it,common()->ascObjSelectionManager()->getAscObjAttachSep(),shapeDetailed(),2.0,1.0);
504  }
505  }
506  } else {
507  VP1Msg::messageVerbose("AscObj_TrackState::zoomView() - zooming on selection not turned on.");
508  }
509 }

Member Data Documentation

◆ m_d

Imp* AssociatedObjectHandleBase::m_d
privateinherited

Definition at line 91 of file AssociatedObjectHandleBase.h.

◆ m_distToNextPar

double AscObj_TrackState::m_distToNextPar
private

Definition at line 62 of file AscObj_TrackState.h.

◆ m_indexOfPointOnTrack

unsigned AscObj_TrackState::m_indexOfPointOnTrack
private

Definition at line 61 of file AscObj_TrackState.h.

◆ m_objBrowseTree

QTreeWidgetItem* AscObj_TrackState::m_objBrowseTree
private

Definition at line 63 of file AscObj_TrackState.h.

◆ m_parts

TrackCommonFlags::TSOSPartsFlags AscObj_TrackState::m_parts
private

Definition at line 60 of file AscObj_TrackState.h.

◆ m_pickStyle

PICKSTYLE AssociatedObjectHandleBase::m_pickStyle
privateinherited

Definition at line 95 of file AssociatedObjectHandleBase.h.

◆ m_trackHandle

TrackHandleBase* AssociatedObjectHandleBase::m_trackHandle
privateinherited

Definition at line 93 of file AssociatedObjectHandleBase.h.

◆ m_trackstate

const ActsTrk::TrackStateBackend::ConstTrackStateProxy AscObj_TrackState::m_trackstate
private

Definition at line 64 of file AscObj_TrackState.h.

◆ m_visible

bool AssociatedObjectHandleBase::m_visible
privateinherited

Definition at line 94 of file AssociatedObjectHandleBase.h.


The documentation for this class was generated from the following files:
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
AssociatedObjectHandleBase::m_d
Imp * m_d
Definition: AssociatedObjectHandleBase.h:90
AssociatedObjectHandleBase::UNPICKABLE
@ UNPICKABLE
Definition: AssociatedObjectHandleBase.h:57
AscObjSelectionManager::registerAscObj
void registerAscObj(SoSeparator *simple, SoSeparator *detailed, AssociatedObjectHandleBase *)
Definition: AscObjSelectionManager.cxx:140
AssociatedObjectHandleBase::parts
virtual TrackCommonFlags::TSOSPartsFlags parts() const
Definition: AssociatedObjectHandleBase.h:46
AssociatedObjectHandleBase::lodCrossOverValue
virtual double lodCrossOverValue() const
Definition: AssociatedObjectHandleBase.h:82
AscObj_TrackState::m_objBrowseTree
QTreeWidgetItem * m_objBrowseTree
Definition: AscObj_TrackState.h:63
checkFileSG.line
line
Definition: checkFileSG.py:75
xAOD::UncalibMeasType::HGTDClusterType
@ HGTDClusterType
AssociatedObjectHandleBase::Imp::attach
void attach(AssociatedObjectHandleBase *theclass)
Definition: AssociatedObjectHandleBase.cxx:162
TrackSysCommonData::controller
TrackSystemController * controller() const
Definition: TrackSysCommonData.h:124
AssociatedObjectHandleBase::regionIndex
virtual int regionIndex() const
Definition: AssociatedObjectHandleBase.h:81
TrackCommonFlags::SIMPLE
@ SIMPLE
Definition: TrackCommonFlags.h:39
AssociatedObjectHandleBase::m_trackHandle
TrackHandleBase * m_trackHandle
Definition: AssociatedObjectHandleBase.h:93
TrackCommonFlags::TSOS_AnyMeasurement
@ TSOS_AnyMeasurement
Definition: TrackCommonFlags.h:61
AscObj_TrackState::addCylindricalSurfaceToShapes
void addCylindricalSurfaceToShapes(SoSeparator *&shape_simple, SoSeparator *&shape_detailed, const Acts::Surface &surface)
Definition: AscObj_TrackState.cxx:322
SoTubs
SoTubs - Inventor version of the G4Tubs Geant Geometry entity.
Definition: SoTubs.h:52
AscObj_TrackState::surface
const Acts::Surface & surface() const
Definition: AscObj_TrackState.h:44
xAOD::UncalibMeasType::StripClusterType
@ StripClusterType
hist_file_dump.d
d
Definition: hist_file_dump.py:137
mat
GeoMaterial * mat
Definition: LArDetectorConstructionTBEC.cxx:55
min
constexpr double min()
Definition: ap_fixedTest.cxx:26
AssociatedObjectHandleBase::hasSurface
bool hasSurface() const
Definition: AssociatedObjectHandleBase.h:52
AssociatedObjectHandleBase::COMPONENTS
@ COMPONENTS
Definition: AssociatedObjectHandleBase.h:57
TRTCalib_cfilter.p1
p1
Definition: TRTCalib_cfilter.py:130
TrackHandleBase::collHandle
TrackCollHandleBase * collHandle() const
Definition: TrackHandleBase.h:68
xAOD::UncalibMeasType::MMClusterType
@ MMClusterType
skel.it
it
Definition: skel.GENtoEVGEN.py:396
TrackSysCommonData::system
VP1TrackSystem * system() const
Definition: TrackSysCommonData.h:122
TrackSysCommonData::ascObjSelectionManager
AscObjSelectionManager * ascObjSelectionManager() const
Definition: TrackSysCommonData.h:123
xAOD::pion
@ pion
Definition: TrackingPrimitives.h:196
TrackCommonFlags::TSOS_AnySurface
@ TSOS_AnySurface
Definition: TrackCommonFlags.h:60
UploadAMITag.l
list l
Definition: UploadAMITag.larcaf.py:158
AscObj_TrackState::addPlaneSurfaceToShapes
void addPlaneSurfaceToShapes(SoSeparator *&shape_simple, SoSeparator *&shape_detailed, const Acts::Surface &surface)
Definition: AscObj_TrackState.cxx:276
AscObj_TrackState::addTrackParamInfoToShapes
void addTrackParamInfoToShapes(SoSeparator *&shape_simple, SoSeparator *&shape_detailed, bool showPars, bool showParsErrors, bool showSurfaces)
Definition: AscObj_TrackState.cxx:119
AscObj_TrackState::m_trackstate
const ActsTrk::TrackStateBackend::ConstTrackStateProxy m_trackstate
Definition: AscObj_TrackState.h:64
xAOD::UncalibMeasType::sTgcStripType
@ sTgcStripType
AssociatedObjectHandleBase::trackHandle
TrackHandleBase * trackHandle() const
Definition: AssociatedObjectHandleBase.h:64
AscObj_TrackState::addMaterialToSurfaceShapes
void addMaterialToSurfaceShapes(SoNode *&shape_simple, SoNode *&shape_detailed)
Definition: AscObj_TrackState.cxx:254
AscObj_TrackState::approxCenter
Amg::Vector3D approxCenter() const
Definition: AscObj_TrackState.cxx:99
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:77
AscObj_TrackState::m_distToNextPar
double m_distToNextPar
Definition: AscObj_TrackState.h:62
AssociatedObjectHandleBase::Imp::detach
void detach() const
Definition: AssociatedObjectHandleBase.cxx:147
TruthTest.itE
itE
Definition: TruthTest.py:25
TrackCommonFlags::TSOS_AnyErrors
@ TSOS_AnyErrors
Definition: TrackCommonFlags.h:67
AssociatedObjectHandleBase::Imp::sep_detailed
SoSeparator * sep_detailed
Definition: AssociatedObjectHandleBase.cxx:36
xAOD::UncalibMeasType::TgcStripType
@ TgcStripType
AscObj_TrackState::m_indexOfPointOnTrack
unsigned m_indexOfPointOnTrack
Definition: AscObj_TrackState.h:61
AscObj_TrackState::m_parts
TrackCommonFlags::TSOSPartsFlags m_parts
Definition: AscObj_TrackState.h:60
cm
const double cm
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/FCAL_ChannelMap.cxx:25
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131
TrackCommonFlags::TSOS_TrackPars
@ TSOS_TrackPars
bit 0
Definition: TrackCommonFlags.h:44
xAOD::UncalibratedMeasurement_v1
Definition: UncalibratedMeasurement_v1.h:13
AssociatedObjectHandleBase::m_visible
bool m_visible
Definition: AssociatedObjectHandleBase.h:94
AssociatedObjectHandleBase::common
TrackSysCommonData * common() const
Definition: AssociatedObjectHandleBase.cxx:105
xAOD::UncalibratedMeasurement_v1::type
virtual xAOD::UncalibMeasType type() const =0
Returns the type of the measurement type as a simple enumeration.
SoTransparency::initClass
static void initClass()
Definition: SoTransparency.cxx:29
AssociatedObjectHandleBase::m_pickStyle
PICKSTYLE m_pickStyle
Definition: AssociatedObjectHandleBase.h:95
TrackCommonFlags::TSOS_MeasRioOnTrackOutlier
@ TSOS_MeasRioOnTrackOutlier
bit 6
Definition: TrackCommonFlags.h:50
TrackSystemController::customMatSurfaces
SoMaterial * customMatSurfaces() const
Definition: TrackSystemController.cxx:1397
master.flag
bool flag
Definition: master.py:29
TrackSystemController::customMatHoleParameters
SoMaterial * customMatHoleParameters() const
Definition: TrackSystemController.cxx:1379
AscObj_TrackState::ensureInitSeps
static void ensureInitSeps(SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
Definition: AscObj_TrackState.cxx:436
AssociatedObjectHandleBase::Imp::sep_simple
SoSeparator * sep_simple
Definition: AssociatedObjectHandleBase.cxx:35
xAOD::Other
@ Other
hist_file_dump.f
f
Definition: hist_file_dump.py:135
SoGenericBox::setParametersForBox
void setParametersForBox(float dx, float dy, float dz, float xcenter=0.0, float ycenter=0.0, float zcenter=0.0)
Definition: SoGenericBox.cxx:179
AssociatedObjectHandleBase::setVisible
virtual void setVisible(bool)
Definition: AssociatedObjectHandleBase.cxx:171
TrackSystemController::customMatParameters
SoMaterial * customMatParameters() const
Definition: TrackSystemController.cxx:1373
TrackCommonFlags::TSOS_AnyMaterialEffects
@ TSOS_AnyMaterialEffects
Definition: TrackCommonFlags.h:59
TrackCommonFlags::TSOS_MaterialEffects
@ TSOS_MaterialEffects
bit 13
Definition: TrackCommonFlags.h:56
TrackHandleBase::common
TrackSysCommonData * common() const
Definition: TrackHandleBase.cxx:255
grepfile.sep
sep
Definition: grepfile.py:38
TrackCommonFlags::TSOS_AnyMeasRioOnTrack
@ TSOS_AnyMeasRioOnTrack
Definition: TrackCommonFlags.h:64
TrackSystemController::customMatMeasurementsOutliers
SoMaterial * customMatMeasurementsOutliers() const
Definition: TrackSystemController.cxx:1367
xAOD::Straw
@ Straw
Definition: TrackingPrimitives.h:557
python.selection.number
number
Definition: selection.py:20
TrackCommonFlags::TSOS_MeasRioOnTrackNotOutlier
@ TSOS_MeasRioOnTrackNotOutlier
bit 4
Definition: TrackCommonFlags.h:48
AssociatedObjectHandleBase::ALL
@ ALL
Definition: AssociatedObjectHandleBase.h:57
AssociatedObjectHandleBase::Imp::ensureShapesBuild
void ensureShapesBuild(AssociatedObjectHandleBase *theclass)
Definition: AssociatedObjectHandleBase.cxx:49
AscObjSelectionManager::unregisterAscObj
void unregisterAscObj(SoSeparator *simple, SoSeparator *detailed)
Definition: AscObjSelectionManager.cxx:164
TrackCommonFlags::TSOS_SurfacesDetElem
@ TSOS_SurfacesDetElem
bit 9
Definition: TrackCommonFlags.h:52
TrackCommonFlags::TSOS_Hole
@ TSOS_Hole
bit 14
Definition: TrackCommonFlags.h:57
ActsTrk::getUncalibratedMeasurement
const xAOD::UncalibratedMeasurement & getUncalibratedMeasurement(const ATLASUncalibSourceLink &source_link)
Definition: ATLASSourceLink.h:26
VP1Msg::messageVerbose
static void messageVerbose(const QString &)
Definition: VP1Msg.cxx:84
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
ParticleGun_SamplingFraction.radius
radius
Definition: ParticleGun_SamplingFraction.py:96
SoGenericBox::drawEdgeLines
SoSFBool drawEdgeLines
Definition: SoGenericBox.h:33
IVP13DSystem::getCameraList
CamList getCameraList()
Definition: IVP13DSystem.cxx:395
VP1Msg::message
static void message(const QString &, IVP1System *sys=0)
Definition: VP1Msg.cxx:30
TrackCommonFlags::TSOS_AnyParsErrors
@ TSOS_AnyParsErrors
Definition: TrackCommonFlags.h:66
SoGenericBox
Definition: SoGenericBox.h:26
xAOD::UncalibMeasType
UncalibMeasType
Define the type of the uncalibrated measurement.
Definition: MeasurementDefs.h:24
TrackCommonFlags::TSOS_NoObjects
@ TSOS_NoObjects
Definition: TrackCommonFlags.h:43
AssociatedObjectHandleBase::Imp::ensureShapesErased
void ensureShapesErased(AssociatedObjectHandleBase *theclass)
Definition: AssociatedObjectHandleBase.cxx:77
AssociatedObjectHandleBase::shapeSimple
SoSeparator * shapeSimple() const
Definition: AssociatedObjectHandleBase.cxx:200
TrackHandleBase::getAttachmentHandle
AssocObjAttachmentHandle * getAttachmentHandle(int regionIndex, const double &crossoverval)
Definition: TrackHandleBase.cxx:1468
AssociatedObjectHandleBase::shapeDetailed
SoSeparator * shapeDetailed() const
Definition: AssociatedObjectHandleBase.cxx:206
TrackSystemController::customMatMeasurements
SoMaterial * customMatMeasurements() const
Definition: TrackSystemController.cxx:1361
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
TrackCommonFlags::TSOS_SurfacesCustom
@ TSOS_SurfacesCustom
bit 10
Definition: TrackCommonFlags.h:53
TrackCollHandleBase::common
TrackSysCommonData * common() const
Definition: TrackCollHandleBase.h:79
xAOD::Plane
@ Plane
Definition: TrackingPrimitives.h:556
AssociatedObjectHandleBase::Imp::nascobjs
static int nascobjs
Definition: AssociatedObjectHandleBase.cxx:29
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
python.compressB64.c
def c
Definition: compressB64.py:93
VP1LinAlgUtils::toSoTransform
static SoTransform * toSoTransform(const HepGeom::Transform3D &, SoTransform *t=0)
Definition: VP1LinAlgUtils.cxx:40
xAOD::UncalibMeasType::RpcStripType
@ RpcStripType
length
double length(const pvec &v)
Definition: FPGATrackSimLLPDoubletHoughTransformTool.cxx:26
xAOD::UncalibMeasType::MdtDriftCircleType
@ MdtDriftCircleType
AssociatedObjectHandleBase::AssociatedObjectHandleBase
AssociatedObjectHandleBase(TrackHandleBase *)
Definition: AssociatedObjectHandleBase.cxx:111
jobOptions.points
points
Definition: jobOptions.GenevaPy8_Zmumu.py:97
xAOD::UncalibMeasType::PixelClusterType
@ PixelClusterType
common
Definition: common.py:1
AscObj_TrackState::addSurfaceToShapes
void addSurfaceToShapes(SoSeparator *&shape_simple, SoSeparator *&shape_detailed)
Definition: AscObj_TrackState.cxx:192