|
ATLAS Offline Software
|
Definition at line 76 of file TrackHandleBase.cxx.
◆ Imp()
◆ ~Imp()
TrackHandleBase::Imp::~Imp |
( |
| ) |
|
|
inline |
◆ addPathsToSoLineSetAndSoVertexProperty()
void TrackHandleBase::Imp::addPathsToSoLineSetAndSoVertexProperty |
( |
const Amg::SetVectorVector3D * |
paths, |
|
|
int & |
iver, |
|
|
int & |
numlines, |
|
|
SoLineSet * |
line, |
|
|
SoVertexProperty * |
vertices |
|
) |
| const |
Definition at line 620 of file TrackHandleBase.cxx.
634 Amg::SetVectorVector3D::const_iterator itProjPart, itProjPartEnd(
paths->end());
635 for (itProjPart =
paths->begin();itProjPart!=itProjPartEnd;++itProjPart)
◆ addPathToSoLineSetAndSoVertexProperty()
void TrackHandleBase::Imp::addPathToSoLineSetAndSoVertexProperty |
( |
const std::vector< Amg::Vector3D > & |
points, |
|
|
int & |
iver, |
|
|
int & |
numlines, |
|
|
SoLineSet * |
line, |
|
|
SoVertexProperty * |
vertices |
|
) |
| const |
Definition at line 556 of file TrackHandleBase.cxx.
570 std::vector<Amg::Vector3D >::const_iterator pointsIt, pointsItEnd(
points.end());
571 unsigned npointsused(0);
580 vertexPlanePhi-=
M_PI;
593 double newPhi= vertexPlanePhi+
M_PI;
594 if (
cos(vertexPlanePhi-trkPhi)>0) newPhi=vertexPlanePhi;
597 for (pointsIt =
points.begin();pointsIt!=pointsItEnd && pointsIt->mag2()<maxR2; ++pointsIt) {
605 tempPoint = *pointsIt;
610 vertices->vertex.set1Value(iver++,tempPoint.x(),tempPoint.y(),tempPoint.z());
612 vertices->vertex.set1Value(iver++,pointsIt->x(),pointsIt->y(),pointsIt->z());
616 line->numVertices.set1Value(numlines++,npointsused);
◆ addTSOS()
◆ attach3DObjects()
void TrackHandleBase::Imp::attach3DObjects |
( |
| ) |
|
◆ convertLineSetToCylinders()
void TrackHandleBase::Imp::convertLineSetToCylinders |
( |
SoLineSet * |
line, |
|
|
SoSeparator * |
sep, |
|
|
const double & |
cylradius |
|
) |
| |
|
static |
Definition at line 851 of file TrackHandleBase.cxx.
854 SoVertexProperty *vertices =
static_cast<SoVertexProperty *
>(
line->vertexProperty.getValue());
859 lastTransf.makeIdentity();
861 for (
int iline=0;iline<
line->numVertices.getNum();++iline) {
862 int nvert=
line->numVertices[iline];
867 for (
int jvert= ivert; jvert<ivert+nvert-1;++jvert) {
868 SbVec3f
p1 = vertices->vertex[jvert].getValue();
869 SbVec3f
p2 = vertices->vertex[jvert+1].getValue();
870 SoCylinder * cyl =
new SoCylinder;
871 cyl->radius = cylradius;
876 m.setTranslate(SbVec3f(0,0.5*
l,0));
878 SbRotation rot(SbVec3f(0,1,0),
v);
879 SbMatrix
m2;
m2.setRotate(rot);
888 mat.multRight(lastTransf.inverse());
889 SoMatrixTransform * mt =
new SoMatrixTransform;
890 mt->matrix.setValue(
mat);
◆ detach3DObjects()
void TrackHandleBase::Imp::detach3DObjects |
( |
| ) |
|
◆ determineMaterial()
SoMaterial * TrackHandleBase::Imp::determineMaterial |
( |
| ) |
|
Definition at line 1286 of file TrackHandleBase.cxx.
1325 if (handle==
nullptr) {
1333 float phiDistance = sqrt (
pow( selectedTrackMom.phi() - thisTrackMom.phi(),2) );
1334 float etaDistance = sqrt (
pow( selectedTrackMom.eta() - thisTrackMom.eta(),2) );
1338 float brightness=
std::max(0.2, 1.0-(etaDistance/5.0) );
1341 SoMaterial*
mat =
new SoMaterial;
1350 if (colScale>0.01) {
1353 QColor tempCol = QColor::fromRgbF(
r,
g,
b );
1355 tempCol.getHsvF(&
h,&
s,&
v);
1360 tempCol.setHsvF(
h,
s,
v);
1362 tempCol.getRgbF(&r2,&
g2,&b2);
1365 r3 =
r+(
r2-
r)*colScale;
1366 b3 =
b+(b2-
b)*colScale;
1367 g3 =
g+(
g2-
g)*colScale;
◆ dist()
double TrackHandleBase::Imp::dist |
( |
const SbVec3f & |
p1, |
|
|
const SbVec3f & |
p2 |
|
) |
| |
|
static |
◆ ensureInitPointsProjections_InDet()
void TrackHandleBase::Imp::ensureInitPointsProjections_InDet |
( |
bool |
raw | ) |
|
Definition at line 1094 of file TrackHandleBase.cxx.
1117 std::vector<Amg::Vector3D > *
points=
nullptr;
1130 projections->clear();
1131 projections->insert(std::vector<Amg::Vector3D >());
1150 projections->clear();
1151 projections->insert(std::vector<Amg::Vector3D >());
◆ ensureInitPointsProjections_Muon()
void TrackHandleBase::Imp::ensureInitPointsProjections_Muon |
( |
bool |
raw | ) |
|
Definition at line 1156 of file TrackHandleBase.cxx.
1179 std::vector<Amg::Vector3D > *
points;
1193 projections->insert(std::vector<Amg::Vector3D >());
1200 bool outsidechamber;
1201 std::vector<Amg::Vector3D > proj1, proj2;
1214 std::vector<Amg::Vector3D >::const_iterator pointsIt=
points->begin(), pointsItEnd=
points->end()-1;
1215 for (;pointsIt!=pointsItEnd; ++pointsIt) {
1219 firstEndWall_pointA, firstEndWall_pointB,
1220 secondEndWall_pointA, secondEndWall_pointB,
1225 "Problems with projectAndConstrainLineSegmentToMDTChamberEndWalls(..)");
1231 if (!outsidechamber){
1232 if ( proj1.empty() ) {
1233 proj1.push_back(firstEndWall_pointA); proj1.push_back(firstEndWall_pointB);
1235 if ( proj1[proj1.size()-1] == firstEndWall_pointA ) {
1236 proj1.push_back(firstEndWall_pointB);
1239 projections->insert(proj1); proj1.clear();
1240 proj1.push_back(firstEndWall_pointA); proj1.push_back(firstEndWall_pointB);
1243 if ( proj2.empty() ) {
1244 proj2.push_back(secondEndWall_pointA); proj2.push_back(secondEndWall_pointB);
1248 if ( proj2[proj2.size()-1] == secondEndWall_pointA ) {
1249 proj2.push_back(secondEndWall_pointB);
1252 projections->insert(proj2); proj2.clear();
1253 proj2.push_back(secondEndWall_pointA); proj2.push_back(secondEndWall_pointB);
1259 if ( !proj1.empty() ) {
1260 projections->insert(proj1);
1262 if ( !proj2.empty() ) {
1263 projections->insert(proj2);
◆ ensureInitPointsPropagated()
void TrackHandleBase::Imp::ensureInitPointsPropagated |
( |
| ) |
|
◆ ensureInitPointsRaw()
void TrackHandleBase::Imp::ensureInitPointsRaw |
( |
| ) |
|
Definition at line 984 of file TrackHandleBase.cxx.
1003 bool unsafeparts(
false);
1007 for (; tsos_iter != tsos_end; ++tsos_iter) {
1014 trackParam = (*tsos_iter)->trackParameters();
1022 if (!firstmomentum) {
1030 if (!firstmomentum) {
1034 if (firstmomentum->mag()==0.0) {
1045 delete firstmomentum;
1046 firstmomentum =
nullptr;
1057 +
" points for track.");
◆ ensureLoadPathInfo()
void TrackHandleBase::Imp::ensureLoadPathInfo |
( |
| ) |
|
◆ isSane()
◆ materialChanged()
void TrackHandleBase::Imp::materialChanged |
( |
| ) |
|
◆ rebuild3DObjects()
void TrackHandleBase::Imp::rebuild3DObjects |
( |
| ) |
|
Definition at line 658 of file TrackHandleBase.cxx.
683 std::vector<Amg::Vector3D > *
points;
698 line =
new SoLineSet();
702 SoVertexProperty * vertices =
new SoVertexProperty();
704 int iver(0), numlines(0);
714 line->vertexProperty = vertices;
722 std::vector<Trk::PlaneSurface>::const_iterator surfIt=surfaces.begin(), surfEnd=surfaces.end();
725 for (;surfIt!=surfEnd;++surfIt){
728 SoNode * nodeToAdd = theSurfSep;
744 SoText2 *labelText =
new SoText2;
780 if (
mom.mag2()==0.0) {
781 text <<
"Momentum : 0 (undefined)";
786 double pseudoRapidity =
mom.eta();
795 labelText->string.set1Value(
row++,
array.data());
800 unsigned int point=(
points->size()-1)*labelTrackOffset;
811 SoTranslation *labelTranslate =
new SoTranslation;
816 labelTranslate->translation.setValue(labelPos.x()+(xOffset*offScale),labelPos.y()+(yOffset*offScale),labelPos.z()+(zOffset*offScale));
818 SoMaterial *sMat =
new SoMaterial();
820 sColor.setValue(SbColor(0, 0, 1));
821 sMat->diffuseColor = sColor;
◆ associatedObjects
◆ attachmentHandles
◆ charge
double TrackHandleBase::Imp::charge |
◆ chargeinit
bool TrackHandleBase::Imp::chargeinit |
◆ customColouredTSOSParts
TrackCommonFlags::TSOSPartsFlags TrackHandleBase::Imp::customColouredTSOSParts |
◆ extrapSurfaces_sep
SoSeparator* TrackHandleBase::Imp::extrapSurfaces_sep |
◆ extraRepAttached
bool TrackHandleBase::Imp::extraRepAttached |
◆ extraRepresentation
SoSeparator* TrackHandleBase::Imp::extraRepresentation |
◆ inittouchedchambers
bool TrackHandleBase::Imp::inittouchedchambers |
|
mutable |
◆ label_sep
SoSeparator* TrackHandleBase::Imp::label_sep |
◆ line
SoLineSet* TrackHandleBase::Imp::line |
◆ m_objBrowseTree
QTreeWidgetItem* TrackHandleBase::Imp::m_objBrowseTree |
◆ mass
double TrackHandleBase::Imp::mass |
◆ massinit
bool TrackHandleBase::Imp::massinit |
◆ ntrackhandles
int TrackHandleBase::Imp::ntrackhandles = 0 |
|
static |
◆ pathInfo_Points
◆ pathInfo_TrkTrack
◆ pathInfoLoaded
bool TrackHandleBase::Imp::pathInfoLoaded |
◆ points_propagated
std::vector<Amg::Vector3D >* TrackHandleBase::Imp::points_propagated |
◆ points_propagated_id_projections
◆ points_propagated_muon_projections
◆ points_raw
◆ points_raw_id_projections
◆ points_raw_muon_projections
◆ randommaterial
SoMaterial* TrackHandleBase::Imp::randommaterial |
◆ shownTSOSParts
TrackCommonFlags::TSOSPartsFlags TrackHandleBase::Imp::shownTSOSParts |
◆ tempMaxPropRadius
float TrackHandleBase::Imp::tempMaxPropRadius |
◆ theclass
◆ touchedmuonchambers
std::set<GeoPVConstLink> TrackHandleBase::Imp::touchedmuonchambers |
|
mutable |
◆ tsos_ascobjs
The documentation for this class was generated from the following file:
JetConstituentVector::iterator iterator
SoMaterial * getMaterialForCharge(const double &charge) const
static double dist(const SbVec3f &p1, const SbVec3f &p2)
MuonChamberProjectionHelper * muonChamberProjectionHelper() const
TrackPropagationHelper * trackPropagationHelper() const
const std::set< GeoPVConstLink > & touchedMuonChambers() const
int labelZOffset()
Absolute z offset.
TrackHandleBase * theclass
double collMaterialTransparency() const
bool extendTracks() const
int labelXOffset()
Absolute x offset.
Const iterator class for DataVector/DataList.
TrackSystemController * controller() const
std::map< std::pair< int, double >, AssocObjAttachmentHandle * > attachmentHandles
SoMaterial * material() const
virtual void currentMaterialChanged()
TrackCommonFlags::TrackPartsFlags parts() const
const Amg::Vector3D & position() const
Access method for the position.
float trackLabelTrkOffset()
Percentage of postion along track.
const Trk::TrackStates * trackStateOnSurfaces() const
return a pointer to a const DataVector of const TrackStateOnSurfaces.
SoMaterial * m_currentmaterial
static bool isSafe(const Trk::TrackStateOnSurface *)
static void convertLineSetToCylinders(SoLineSet *line, SoSeparator *sep, const double &cylradius)
virtual unsigned getNTGCHits() const
TrackCollHandleBase * collHandle() const
void ensureInitPointsProjections_InDet(bool raw)
VP1TrackSystem * system() const
static bool isSane(const Amg::Vector3D &p)
int vertexProjectionAngle() const
void registerTrack(SoNode *, TrackHandleBase *)
SoSeparator * extraRepresentation
virtual unsigned getNSCTHits() const
SoMaterial * materialFromVertex(const TrackHandleBase *trk) const
Returns the material for the vertex which knows this trackhandle (if known)
virtual const std::vector< Amg::Vector3D > * provide_pathInfoPoints()
std::set< std::vector< Amg::Vector3D >, VectorVector3DComparer > SetVectorVector3D
static QString str(const QString &s)
std::vector< Trk::PlaneSurface > & getExtrapolationSurfaces() const
bool ignoreMEOTinProp() const
Amg::SetVectorVector3D * points_propagated_muon_projections
Amg::RotationMatrix3D setPhi(Amg::RotationMatrix3D mat, double angle, int convention=0)
static double phiFromXY(const double &x, const double &y)
virtual unsigned getNsTGCHits() const
SoMaterial * determineMaterial()
int labelYOffset()
Absolute y offset.
void registerAssocObject(AssociatedObjectHandleBase *)
Trackhandle assumes ownership.
virtual unsigned getNTRTHits() const
virtual const Trk::FitQuality * getFitQuality() const
Amg::SetVectorVector3D * points_propagated_id_projections
virtual TrackCommonFlags::TSOSPartsFlags parts() const
QTreeWidgetItem * m_objBrowseTree
SoMaterial * randommaterial
void projectPath(const std::vector< Amg::Vector3D > &path, Amg::SetVectorVector3D &resulting_projections) const
const Trk::Track * pathInfo_TrkTrack
Used in the case of a Trk::Track.
virtual Amg::Vector3D momentum() const
static const int unknownPDG
virtual unsigned getNRPCHits() const
COLOURBY colourBy() const
void rerandomiseRandomMaterial()
TrackLabelModes trackLabels()
SoNode * translateSurface(const Trk::Surface &sf, const bool &simple=false) const
InDetProjHelper * indetProjHelper_SCT() const
void ensureInitPointsPropagated()
bool projectAndConstrainLineSegmentToMDTChamberEndWalls(const GeoPVConstLink &mdtChamber, const Amg::Vector3D &pointA, const Amg::Vector3D &pointB, Amg::Vector3D &firstEndWall_pointA, Amg::Vector3D &firstEndWall_pointB, Amg::Vector3D &secondEndWall_pointA, Amg::Vector3D &secondEndWall_pointB, bool &outsidechamber)
bool showExtrapolationSurfaces() const
double collMaterialBrightness() const
Trk::IExtrapolator * propagator() const
virtual int pdgCode() const
0 means unknown
virtual unsigned getNMDTHits() const
double trackTubeRadius() const
virtual unsigned getNMMHits() const
TrackCollHandleBase * m_collhandle
TrackSysCommonData * common() const
virtual Trk::ParticleHypothesis extrapolationParticleHypothesis() const
Default implementation of this next method bases hypothesis on pdgCode() and charge():
const DataVector< const TrackParameters > * trackParameters() const
Return a pointer to a vector of TrackParameters.
virtual unsigned getNPixelHits() const
SoMaterial * getMaterialForPDGCode(const int &pdgcode) const
void addPathsToSoLineSetAndSoVertexProperty(const Amg::SetVectorVector3D *paths, int &iver, int &numlines, SoLineSet *, SoVertexProperty *) const
IVP1System * systemBase() const
TrackCommonFlags::TSOSPartsFlags shownTSOSParts
SoSeparator * extrapSurfaces_sep
for debugging.
TrackHandleBase * lastSelectedTrackHandle()
pointer to base of last selected track (zero if nothing selected)
static void messageVerbose(const QString &)
const std::vector< Amg::Vector3D > * pathInfo_Points
Used in all other cases.
Eigen::Matrix< double, 3, 1 > Vector3D
static QString shortInfo(const Trk::MeasurementBase &mb)
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
bool isKnownMDTChamber(const GeoPVConstLink &mdtChamber)
const Amg::Vector3D & momentum() const
Access method for the momentum.
virtual unsigned getNCSCHits() const
void ensureInitPointsProjections_Muon(bool raw)
static void messageDebug(const QString &)
bool makePointsCharged(std::vector< Amg::Vector3D > &points, const Trk::Track *, Trk::IExtrapolator *extrapolator, Trk::ParticleHypothesis hypo=Trk::nonInteracting, bool useMEOT=false, const Trk::Volume *volume=0)
void ensureLoadPathInfo()
virtual const Trk::Track * provide_pathInfoTrkTrack() const
InDetProjHelper * indetProjHelper_TRT() const
InDetProjHelper * indetProjHelper_Pixel() const
Amg::SetVectorVector3D * points_raw_muon_projections
float propMaxRadius() const
Amg::SetVectorVector3D * points_raw_id_projections
void ensureInitPointsRaw()
void addPathToSoLineSetAndSoVertexProperty(const std::vector< Amg::Vector3D > &points, int &iver, int &numlines, SoLineSet *, SoVertexProperty *) const
TrackCommonFlags::TSOSPartsFlags customColouredTSOSParts
virtual void setVisible(bool)
std::vector< Amg::Vector3D > * points_propagated
SoMaterial * getMaterialForMomentum(const double &absmom) const
static bool hasMuonGeometry()
VP1ExtraSepLayerHelper * sephelper() const
std::vector< AssociatedObjectHandleBase * > * tsos_ascobjs
void message(const QString &) const
void messageVerbose(const QString &) const
static QString particleName(const int &pdgcode, bool &ok)
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
const Trk::Volume * extrapolateToThisVolume() const
Returns the volume to which we extrapolate ID tracks, or zero if no VolumesSvc found.
std::vector< Amg::Vector3D > * points_raw
bool makePointsNeutral(std::vector< Amg::Vector3D > &points, const Trk::Track *)