CGEM BOSS 6.6.5.g
BESIII Offline Software System
Loading...
Searching...
No Matches
DstConvert.h
Go to the documentation of this file.
1/*
2 * 2018/5/30 Long Peixun IHEP
3 * Convert DST tracks to REC tracks
4*/
5
6#ifndef DST_CONVERT
7#define DST_CONVERT
8
17
18//Convert TMdcTrack to TRecMdcTrack
20{
21 dist->setTrackId(src->trackId());
22 dist->setStat(src->stat());
23 dist->setChi2(src->chi2());
24 dist->setNdof(src->ndof());
25 dist->setNster(src->nster());
26 dist->setNlayer(src->nlayer());
27
28 Double_t tmpHelix[5];
29 for (int i = 0; i < 5; ++i) tmpHelix[i] = src->helix(i);
30 dist->setHelix(tmpHelix);
31 Double_t tmpErr[15];
32 for (int i = 0; i < 15; ++i) tmpErr[i] = src->err(i);
33 dist->setErr(tmpErr);
34}
35
36//Convert TTofTrack to TRecTofTrack
38{
39 dist->setTofTrackID(src->tofTrackID());
40 dist->setTrackID(src->trackID());
41 dist->setTofID(src->tofID());
42 dist->setStatus(src->status());
43 dist->setPath(src->path());
44 dist->setZrHit(src->zrhit());
45 dist->setPh(src->ph());
46 dist->setTof(src->tof());
47 dist->setErrTof(src->errtof());
48 dist->setBeta(src->beta());
49 dist->setQuality(src->quality());
50 dist->setT0(src->t0());
51 dist->setErrT0(src->errt0());
52 dist->setErrZ(src->errz());
53 dist->setPhi(src->phi());
54 dist->setErrPhi(src->errphi());
55 dist->setEnergy(src->energy());
56 dist->setErrEnergy(src->errenergy());
57
58 Double_t tmpTexp[5];
59 for (int i = 0; i < 5; ++i) tmpTexp[i] = src->texp(i);
60 dist->setTexp(tmpTexp);
61 Double_t tmpToffset[6];
62 for (int i = 0; i < 6; ++i) tmpToffset[i] = src->toffset(i);
63 dist->setTexp(tmpToffset);
64 Double_t tmpSigma[6];
65 for (int i = 0; i < 6; ++i) tmpSigma[i] = src->sigma(i);
66 dist->setTexp(tmpSigma);
67}
68
69//Convert TEmcTrack to TRecEmcShower
71{
72 dist->setTrackId(src->trackId());
73 dist->setNumHits(src->numHits());
74 dist->setStatus(src->status());
75 dist->setCellId(src->cellId());
76 dist->setModule(src->module());
77 dist->setX(src->x());
78 dist->setY(src->y());
79 dist->setZ(src->z());
80 dist->setTheta(src->theta());
81 dist->setPhi(src->phi());
82 dist->setDtheta(src->dtheta());
83 dist->setDphi(src->dphi());
84 dist->setEnergy(src->energy());
85 dist->setDE(src->dE());
86 dist->setESeed(src->eSeed());
87 dist->setE3x3(src->e3x3());
88 dist->setE5x5(src->e5x5());
89 dist->setTime(src->time());
90 dist->setSecondMoment(src->secondMoment());
91 dist->setLatMoment(src->latMoment());
92 dist->setA20Moment(src->a20Moment());
93 dist->setA42Moment(src->a42Moment());
94
95 Double_t tmpErr[6];
96 for (int i = 0; i < 6; ++i) tmpErr[i] = src->err(i);
97 dist->setErr(tmpErr);
98}
99
100//Convert TMucTrack to TRecMucTrack
102{
103 dist->setTrackId(src->trackId());
104 dist->setId(src->id());
105 dist->setStatus(src->status());
106 dist->setType(src->type());
107 dist->setStartPart(src->startPart());
108 dist->setEndPart(src->endPart());
109 dist->setBrLastLayer(src->brLastLayer());
110 dist->setEcLastLayer(src->ecLastLayer());
111 dist->setNumHits(src->numHits());
112 dist->setNumLayers(src->numLayers());
113 dist->setMaxHitsInLayer(src->maxHitsInLayer());
114 dist->setDepth(src->depth());
115 dist->setChi2(src->chi2());
116 dist->setDof(src->dof());
117 dist->setRms(src->rms());
118 dist->setDistance(src->distance());
119 dist->setDeltaPhi(src->deltaPhi());
120 dist->setXPos(src->xPos());
121 dist->setYPos(src->yPos());
122 dist->setZPos(src->zPos());
123 dist->setXPosSigma(src->xPosSigma());
124 dist->setYPosSigma(src->yPosSigma());
125 dist->setZPosSigma(src->zPosSigma());
126 dist->setPx(src->px());
127 dist->setPy(src->py());
128 dist->setPz(src->pz());
129 dist->setkalRechi2(src->kalRechi2());
130 dist->setkalDof(src->kaldof());
131 dist->setkalDepth(src->kaldepth());
132 dist->setkalbrLastLayer(src->kalbrLastLayer());
133 dist->setkalecLastLayer(src->kalecLastLayer());
134}
135
136#endif
void cvtMucDst2MucRec(TRecMucTrack *dist, const TMucTrack *src)
Definition: DstConvert.h:101
void cvtMdcDst2MdcRec(TRecMdcTrack *dist, const TMdcTrack *src)
Definition: DstConvert.h:19
void cvtEmcDst2EmcRec(TRecEmcShower *dist, const TEmcTrack *src)
Definition: DstConvert.h:70
void cvtTofDst2TofRec(TRecTofTrack *dist, const TTofTrack *src)
Definition: DstConvert.h:37
Double_t time() const
Definition: TEmcTrack.h:42
Double_t a42Moment() const
Definition: TEmcTrack.h:46
Int_t trackId() const
Definition: TEmcTrack.h:19
Double_t eSeed() const
Definition: TEmcTrack.h:39
Double_t err(Int_t i) const
Definition: TEmcTrack.h:47
Int_t status() const
Definition: TEmcTrack.h:21
Double_t energy() const
Definition: TEmcTrack.h:37
Double_t y() const
Definition: TEmcTrack.h:25
Double_t dtheta() const
Definition: TEmcTrack.h:35
Double_t e3x3() const
Definition: TEmcTrack.h:40
Double_t theta() const
Definition: TEmcTrack.h:27
Double_t secondMoment() const
Definition: TEmcTrack.h:43
Int_t module() const
Definition: TEmcTrack.h:23
Double_t phi() const
Definition: TEmcTrack.h:30
Double_t x() const
Definition: TEmcTrack.h:24
Double_t a20Moment() const
Definition: TEmcTrack.h:45
Double_t z() const
Definition: TEmcTrack.h:26
Double_t dE() const
Definition: TEmcTrack.h:38
Int_t cellId() const
Definition: TEmcTrack.h:22
Int_t numHits() const
Definition: TEmcTrack.h:20
Double_t e5x5() const
Definition: TEmcTrack.h:41
Double_t dphi() const
Definition: TEmcTrack.h:36
Double_t latMoment() const
Definition: TEmcTrack.h:44
const Double_t helix(Int_t i) const
Definition: TMdcTrack.h:14
const Double_t chi2() const
Definition: TMdcTrack.h:16
const Int_t stat() const
Definition: TMdcTrack.h:15
const Int_t nster() const
Definition: TMdcTrack.h:19
const Double_t err(Int_t i) const
Definition: TMdcTrack.h:18
const Int_t trackId() const
Definition: TMdcTrack.h:13
const Int_t ndof() const
Definition: TMdcTrack.h:17
const Int_t nlayer() const
Definition: TMdcTrack.h:20
Double_t zPos() const
Definition: TMucTrack.h:43
Int_t numHits() const
Definition: TMucTrack.h:32
Int_t kalbrLastLayer() const
Definition: TMucTrack.h:61
Int_t brLastLayer() const
Definition: TMucTrack.h:30
Double_t pz() const
Definition: TMucTrack.h:51
Double_t deltaPhi() const
Definition: TMucTrack.h:54
Int_t dof() const
Definition: TMucTrack.h:38
Int_t trackId() const
Definition: TMucTrack.h:23
Double_t zPosSigma() const
Definition: TMucTrack.h:47
Int_t kaldof() const
Definition: TMucTrack.h:59
Int_t kalecLastLayer() const
Definition: TMucTrack.h:62
Double_t px() const
Definition: TMucTrack.h:49
Double_t depth() const
Definition: TMucTrack.h:36
Double_t xPos() const
Definition: TMucTrack.h:41
Int_t numLayers() const
Definition: TMucTrack.h:33
Int_t status() const
Definition: TMucTrack.h:25
Double_t kalRechi2() const
Definition: TMucTrack.h:58
Double_t yPosSigma() const
Definition: TMucTrack.h:46
Int_t id() const
Definition: TMucTrack.h:24
Double_t yPos() const
Definition: TMucTrack.h:42
Double_t xPosSigma() const
Definition: TMucTrack.h:45
Int_t type() const
Definition: TMucTrack.h:26
Double_t distance() const
Definition: TMucTrack.h:53
Int_t maxHitsInLayer() const
Definition: TMucTrack.h:34
Double_t rms() const
Definition: TMucTrack.h:39
Int_t startPart() const
Definition: TMucTrack.h:28
Int_t endPart() const
Definition: TMucTrack.h:29
Double_t py() const
Definition: TMucTrack.h:50
Int_t ecLastLayer() const
Definition: TMucTrack.h:31
Double_t chi2() const
Definition: TMucTrack.h:37
Double_t kaldepth() const
Definition: TMucTrack.h:60
void setDphi(const Double_t dpi)
Definition: TRecEmcShower.h:68
void setTime(const Double_t time)
Definition: TRecEmcShower.h:74
void setY(const Double_t y)
Definition: TRecEmcShower.h:61
void setX(const Double_t x)
Definition: TRecEmcShower.h:60
void setDtheta(const Double_t dt)
Definition: TRecEmcShower.h:66
void setA20Moment(const Double_t a20Moment)
Definition: TRecEmcShower.h:77
void setStatus(const Int_t st)
Definition: TRecEmcShower.h:57
void setModule(const Int_t mod)
Definition: TRecEmcShower.h:59
void setTheta(const Double_t theta)
Definition: TRecEmcShower.h:65
void setEnergy(const Double_t e)
Definition: TRecEmcShower.h:63
void setSecondMoment(const Double_t secondMoment)
Definition: TRecEmcShower.h:75
void setE3x3(const Double_t e3x3)
Definition: TRecEmcShower.h:70
void setZ(const Double_t z)
Definition: TRecEmcShower.h:62
void setE5x5(const Double_t e5x5)
Definition: TRecEmcShower.h:71
void setCellId(const Int_t id)
Definition: TRecEmcShower.h:58
void setESeed(const Double_t eSeed)
Definition: TRecEmcShower.h:69
void setNumHits(const Int_t hit)
Definition: TRecEmcShower.h:56
void setErr(const Double_t err[6])
void setDE(const Double_t de)
Definition: TRecEmcShower.h:64
void setA42Moment(const Double_t a42Moment)
Definition: TRecEmcShower.h:78
void setPhi(const Double_t pi)
Definition: TRecEmcShower.h:67
void setTrackId(const Int_t trackId)
Definition: TRecEmcShower.h:55
void setLatMoment(const Double_t latMoment)
Definition: TRecEmcShower.h:76
void setStat(const Int_t stat)
Definition: TRecMdcTrack.h:51
void setNdof(const Int_t ndof)
Definition: TRecMdcTrack.h:53
void setErr(const Double_t er[15])
Definition: TRecMdcTrack.h:55
void setHelix(const Double_t helix[5])
Definition: TRecMdcTrack.h:48
void setNster(const Int_t ns)
Definition: TRecMdcTrack.h:60
void setNlayer(const Int_t nlayer)
Definition: TRecMdcTrack.h:61
void setChi2(const Double_t chi)
Definition: TRecMdcTrack.h:52
void setTrackId(const Int_t trackId)
Definition: TRecMdcTrack.h:47
void setRms(Double_t rms)
Definition: TRecMucTrack.h:84
void setMaxHitsInLayer(Int_t maxHits)
Definition: TRecMucTrack.h:79
void setkalbrLastLayer(Int_t br)
Definition: TRecMucTrack.h:107
void setZPos(Double_t z)
Definition: TRecMucTrack.h:90
void setXPos(Double_t x)
Definition: TRecMucTrack.h:88
void setEcLastLayer(Int_t layer)
Definition: TRecMucTrack.h:76
void setYPosSigma(Double_t y)
Definition: TRecMucTrack.h:93
void setkalDof(Int_t f)
Definition: TRecMucTrack.h:105
void setPz(Double_t pz)
Definition: TRecMucTrack.h:98
void setkalecLastLayer(Int_t ec)
Definition: TRecMucTrack.h:108
void setStartPart(Int_t part)
Definition: TRecMucTrack.h:73
void setNumHits(Int_t numHits)
Definition: TRecMucTrack.h:77
void setBrLastLayer(Int_t layer)
Definition: TRecMucTrack.h:75
void setPy(Double_t py)
Definition: TRecMucTrack.h:97
void setStatus(Int_t st)
Definition: TRecMucTrack.h:70
void setDeltaPhi(Double_t dphi)
Definition: TRecMucTrack.h:86
void setEndPart(Int_t part)
Definition: TRecMucTrack.h:74
void setTrackId(Int_t trackId)
Definition: TRecMucTrack.h:68
void setkalRechi2(Double_t ch)
Definition: TRecMucTrack.h:104
void setYPos(Double_t y)
Definition: TRecMucTrack.h:89
void setNumLayers(Int_t numLayers)
Definition: TRecMucTrack.h:78
void setId(Int_t id)
Definition: TRecMucTrack.h:69
void setDepth(Double_t depth)
Definition: TRecMucTrack.h:81
void setXPosSigma(Double_t x)
Definition: TRecMucTrack.h:92
void setPx(Double_t px)
Definition: TRecMucTrack.h:96
void setChi2(Double_t chi2)
Definition: TRecMucTrack.h:82
void setDof(Int_t dof)
Definition: TRecMucTrack.h:83
void setZPosSigma(Double_t z)
Definition: TRecMucTrack.h:94
void setkalDepth(Double_t de)
Definition: TRecMucTrack.h:106
void setType(Int_t type)
Definition: TRecMucTrack.h:71
void setDistance(Double_t dist)
Definition: TRecMucTrack.h:85
void setTof(Double_t tof)
Definition: TRecTofTrack.h:70
void setTrackID(Int_t trackID)
Definition: TRecTofTrack.h:64
void setEnergy(Double_t energy)
Definition: TRecTofTrack.h:102
void setTexp(Double_t texp[5])
Definition: TRecTofTrack.h:73
void setStatus(UInt_t status)
Definition: TRecTofTrack.h:66
void setT0(Double_t t0)
Definition: TRecTofTrack.h:96
void setQuality(Int_t quality)
Definition: TRecTofTrack.h:94
void setErrZ(Double_t errz)
Definition: TRecTofTrack.h:99
void setErrTof(Double_t etof)
Definition: TRecTofTrack.h:71
void setTofID(Int_t tofID)
Definition: TRecTofTrack.h:65
void setBeta(Double_t beta)
Definition: TRecTofTrack.h:72
void setPhi(Double_t phi)
Definition: TRecTofTrack.h:100
void setErrPhi(Double_t errphi)
Definition: TRecTofTrack.h:101
void setTofTrackID(Int_t tofTrackID)
Definition: TRecTofTrack.h:63
void setPath(Double_t path)
Definition: TRecTofTrack.h:67
void setPh(Double_t ph)
Definition: TRecTofTrack.h:69
void setErrEnergy(Double_t errenergy)
Definition: TRecTofTrack.h:103
void setZrHit(Double_t zrhit)
Definition: TRecTofTrack.h:68
void setErrT0(Double_t errt0)
Definition: TRecTofTrack.h:97
Double_t errt0() const
Definition: TTofTrack.h:98
Double_t ph() const
Definition: TTofTrack.h:67
Double_t energy() const
Definition: TTofTrack.h:103
Double_t phi() const
Definition: TTofTrack.h:101
Int_t tofID() const
Definition: TTofTrack.h:61
Double_t errenergy() const
Definition: TTofTrack.h:104
Double_t path() const
Definition: TTofTrack.h:65
Double_t beta() const
Definition: TTofTrack.h:70
Double_t texp(Int_t i) const
Definition: TTofTrack.h:72
Double_t errphi() const
Definition: TTofTrack.h:102
Double_t zrhit() const
Definition: TTofTrack.h:66
Double_t toffset(Int_t i) const
Definition: TTofTrack.h:79
Int_t quality() const
Definition: TTofTrack.h:95
Int_t tofTrackID() const
Definition: TTofTrack.h:59
Double_t t0() const
Definition: TTofTrack.h:97
Double_t tof() const
Definition: TTofTrack.h:68
Double_t errz() const
Definition: TTofTrack.h:100
UInt_t status() const
Definition: TTofTrack.h:63
Double_t sigma(Int_t i) const
Definition: TTofTrack.h:87
Double_t errtof() const
Definition: TTofTrack.h:69
Int_t trackID() const
Definition: TTofTrack.h:60