61 |
if ( !OrbitalInfoTrk ) OrbitalInfoTrk = new TClonesArray("OrbitalInfoTrkVar",2); //ELENA} |
if ( !OrbitalInfoTrk ) OrbitalInfoTrk = new TClonesArray("OrbitalInfoTrkVar",2); //ELENA} |
62 |
// if ( !Iij ) Iij = new TMatrixD(3,3); |
// if ( !Iij ) Iij = new TMatrixD(3,3); |
63 |
}//ELENA |
}//ELENA |
64 |
|
//-------------------------------------- |
65 |
|
// |
66 |
|
// |
67 |
|
//-------------------------------------- |
68 |
|
void OrbitalInfo::SetTrackArray(TClonesArray *track){//ELENA |
69 |
|
// if(track && strcmp(track->GetClass()->GetName(),"OrbitalInfoTrkVar")==0){ |
70 |
|
if(OrbitalInfoTrk)OrbitalInfoTrk->Clear("C"); |
71 |
|
OrbitalInfoTrk = track; |
72 |
|
// } |
73 |
|
} |
74 |
|
|
75 |
OrbitalInfoTrkVar *OrbitalInfo::GetOrbitalInfoTrkVar(Int_t itrk){ |
OrbitalInfoTrkVar *OrbitalInfo::GetOrbitalInfoTrkVar(Int_t itrk){ |
76 |
// |
// |
85 |
OrbitalInfoTrkVar *orbtrack = (OrbitalInfoTrkVar*)t[itrk]; |
OrbitalInfoTrkVar *orbtrack = (OrbitalInfoTrkVar*)t[itrk]; |
86 |
return orbtrack; |
return orbtrack; |
87 |
} |
} |
88 |
|
/** |
89 |
|
* Retrieves the tof track matching the seqno-th tracker stored track. |
90 |
|
* |
91 |
|
*/ |
92 |
|
OrbitalInfoTrkVar *OrbitalInfo::GetOrbitalInfoStoredTrack(int seqno){ |
93 |
|
|
94 |
|
if( ntrk()==0 ){ |
95 |
|
printf("OrbitalInfo::GetOrbitalInfoStoredTrack(int) : requested tracker SeqNo %i but no OrbitalInforimeter tracks are stored\n",seqno); |
96 |
|
return NULL; |
97 |
|
}; |
98 |
|
|
99 |
|
OrbitalInfoTrkVar *c = 0; |
100 |
|
Int_t it_tof=0; |
101 |
|
|
102 |
|
do { |
103 |
|
c = GetOrbitalInfoTrkVar(it_tof); |
104 |
|
it_tof++; |
105 |
|
} while( c && seqno != c->trkseqno && it_tof < ntrk()); |
106 |
|
|
107 |
|
if(!c || seqno != c->trkseqno){ |
108 |
|
c = 0; |
109 |
|
if(seqno!=-1 ) printf("OrbitalInfo::GetOrbitalInfoStoredTrack(int) : requested tracker SeqNo %i does not match OrbitalInfo stored tracks\n",seqno); |
110 |
|
}; |
111 |
|
return c; |
112 |
|
|
113 |
|
} |
114 |
|
|
115 |
void OrbitalInfo::Clear(Option_t *t){ |
void OrbitalInfo::Clear(Option_t *t){ |
116 |
// |
// |
157 |
qkind = -1000; |
qkind = -1000; |
158 |
errq = -1000; |
errq = -1000; |
159 |
azim = -1000; |
azim = -1000; |
160 |
|
rtqual =-1000; |
161 |
// std::fill_n(goodAttitude, 5, 0); |
// std::fill_n(goodAttitude, 5, 0); |
162 |
} |
} |
163 |
|
|
203 |
l2->qkind = qkind; |
l2->qkind = qkind; |
204 |
l2->errq = errq; |
l2->errq = errq; |
205 |
l2->azim = azim; |
l2->azim = azim; |
206 |
|
l2->rtqual=rtqual; |
207 |
|
|
208 |
// memcpy(l2->goodAttitude, goodAttitude, sizeof(goodAttitude)); |
// memcpy(l2->goodAttitude, goodAttitude, sizeof(goodAttitude)); |
209 |
} |
} |
247 |
qkind = l2->qkind; |
qkind = l2->qkind; |
248 |
errq = l2->errq; |
errq = l2->errq; |
249 |
azim = l2->azim; |
azim = l2->azim; |
250 |
|
rtqual=l2->rtqual; |
251 |
|
|
252 |
// memcpy(goodAttitude, l2->goodAttitude, sizeof(l2->goodAttitude)); |
// memcpy(goodAttitude, l2->goodAttitude, sizeof(l2->goodAttitude)); |
253 |
} |
} |