--- DarthVader/TrackerLevel2/src/TrkHough.cpp 2007/11/07 10:38:52 1.2 +++ DarthVader/TrackerLevel2/src/TrkHough.cpp 2008/10/22 15:17:36 1.3 @@ -53,6 +53,13 @@ // // //-------------------------------------- +void TrkHough::Set(){ + if(!Candidates)Candidates = new TClonesArray("TrkTrack"); +} +//-------------------------------------- +// +// +//-------------------------------------- /** * Fills a TrkHough object with values from a struct cTrkhough (to get data from F77 common). */ @@ -129,9 +136,11 @@ // al4[ii] = (Float_t) lc->al[ii][4]; // } TrkTrack* t_track = new TrkTrack(); - Candidates = new TClonesArray("TrkTrack"); + if(!Candidates) Candidates = new TClonesArray("TrkTrack"); TClonesArray &t = *Candidates; + for(int i=0; intracks; i++){ +// cout << " - "<seqno = i; t_track->image = 0; t_track->chi2 = lc->chi2[i]; @@ -179,10 +188,22 @@ //----------------------------------------------------- //----------------------------------------------------- }; + // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + // evaluated coordinates (to define GF) + // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + int ngf = TrkParams::nGF; + float *zgf = TrkParams::zGF; + Trajectory tgf = Trajectory(ngf,zgf); + tgf.DoTrack2(t_track->al);//<<<< integrate the trajectory + for(int ip=0; ipxGF[ip] = tgf.x[ip]; + t_track->yGF[ip] = tgf.y[ip]; + } // if(t_track->IsSaturated())t_track->Dump(); new(t[i]) TrkTrack(*t_track); t_track->Clear(); }; +// cout << t.GetEntries() <<" <> "<< Candidates->GetEntries()<