8#include <tracking/trackFitting/measurementCreator/creators/BaseMeasurementCreatorFromHit.h>
9#include <tracking/dataobjects/RecoTrack.h>
10#include <genfit/TrackPoint.h>
11#include <genfit/WireTrackCandHit.h>
15template <
class HitType, Const::EDetector detector>
17 genfit::MeasurementFactory<genfit::AbsMeasurement>& measurementFactory) :
20template <
class HitType, Const::EDetector detector>
25 genfit::AbsMeasurement* coordinateMeasurement = m_measurementFactory.createOne(detector, hit->getArrayIndex(),
28 return coordinateMeasurement;
31template <
class HitType, Const::EDetector detector>
33 genfit::AbsMeasurement* coordinateMeasurement,
36 genfit::TrackPoint* coordinateTrackPoint =
new genfit::TrackPoint(coordinateMeasurement,
40 return coordinateTrackPoint;
59 signed char rightLeftGenfitInformation = 0;
61 if (rightLeftHitInformation == RecoHitInformation::RightLeftInformation::c_left) {
62 rightLeftGenfitInformation = -1;
63 }
else if (rightLeftHitInformation == RecoHitInformation::RightLeftInformation::c_right) {
64 rightLeftGenfitInformation = 1;
68 auto trackCandHit = std::unique_ptr<genfit::WireTrackCandHit>(
new genfit::WireTrackCandHit(Const::CDC, cdcHit->getArrayIndex(), -1,
69 recoHitInformation.getSortingParameter(),
70 rightLeftGenfitInformation));
72 genfit::AbsMeasurement* coordinateMeasurement = m_measurementFactory.createOne(trackCandHit->getDetId(), trackCandHit->getHitId(),
77 return coordinateMeasurement;
Base Class to create measurements based on a given hit related to the RecoTrack.
genfit::AbsMeasurement * createCoordinateMeasurement(HitType *hit, const RecoHitInformation &recoHitInformation) const
You probably need a coordinate measurement on which you can base your measurements in createMeasureme...
BaseMeasurementCreatorFromHit(const genfit::MeasurementFactory< genfit::AbsMeasurement > &measurementFactory)
Creates a MeasurementCreator which handles the creation of measurements of a given kind.
genfit::TrackPoint * createTrackPointWithRecoHitInformation(genfit::AbsMeasurement *coordinateMeasurement, RecoTrack &recoTrack, const RecoHitInformation &recoHitInformation) const
Helper: Create a TrackPoint from a measurement with a given RecoHitInformation.
Base class for all measurement creators.
Class containing the result of the unpacker in raw data and the result of the digitizer in simulation...
static genfit::Track & getGenfitTrack(RecoTrack &recoTrack)
Give access to the RecoTrack's genfit::Track.
This is the Reconstruction Event-Data Model Track.
Abstract base class for different kinds of events.