- Timestamp:
- 01/10/05 11:19:15 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mbadpixels/MBadPixelsTreat.cc
r5728 r5761 469 469 const MGeomPix &gpix = (*fGeomCam)[i]; 470 470 471 const Int_t n0 = gpix.GetNumNeighbors(); 472 473 MArrayD time(n0); 474 for (int j=0; j<n0; j++) 475 time[j] = (*fTimes)[gpix.GetNeighbor(j)]; 476 477 Int_t p0=0; 478 Int_t p1=0; 471 MArrayD time(gpix.GetNumNeighbors()); 472 473 Int_t n0 = 0; 474 for (unsigned int j=0; j<time.GetSize(); j++) 475 { 476 const Double_t t = (*fTimes)[gpix.GetNeighbor(j)]; 477 if (t>=0) 478 time[n0++] = t; 479 } 480 481 Int_t p0=-1; 482 Int_t p1=-1; 479 483 480 484 Double_t min=FLT_MAX; … … 492 496 } 493 497 494 if ( TMath::Abs(time[p0] - time[p1])<250)498 if (p0>=0 && p1>=0 && TMath::Abs(time[p0] - time[p1])<250) 495 499 fTimes->SetTime(i, (time[p0]+time[p1])/2); 496 500 }
Note:
See TracChangeset
for help on using the changeset viewer.