Changeset 4609 for trunk/MagicSoft/Mars/mpedestal/MPedPhotCam.cc
- Timestamp:
- 08/13/04 14:59:17 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mpedestal/MPedPhotCam.cc
r4384 r4609 229 229 void MPedPhotCam::ReCalc(const MGeomCam &geom, MBadPixelsCam *bad) 230 230 { 231 232 231 const Int_t np = GetSize(); 233 232 const Int_t ns = GetNumSectors(); 234 233 const Int_t na = GetNumAreas(); 235 236 237 234 238 235 TArrayI acnt(na); … … 243 240 TArrayD ssumr(ns); 244 241 245 246 242 for (int i=0; i<np; i++) 247 243 { 248 249 250 if (bad && (*bad)[i].IsUnsuitable(MBadPixelsPix::kUnsuitableRun)) 251 continue; //was: .IsBad() 244 if (bad && (*bad)[i].IsUnsuitable(MBadPixelsPix::kUnsuitableRun)) 245 continue; //was: .IsBad() 252 246 253 247 // Create sums for areas and sectors … … 268 262 ssumr[sect] += ne*rms; 269 263 scnt[sect] += ne; 270 271 272 }273 274 for (int i=0; i<ns; i++){275 if (scnt[i]>0) GetSector(i).Set(ssumx[i]/scnt[i], ssumr[i]/scnt[i], scnt[i]);276 else GetSector(i).Set(-1., -1., 0);277 } 278 279 for (int i=0; i<na; i++){280 if (acnt[i]>0)GetArea(i).Set(asumx[i]/acnt[i], asumr[i]/acnt[i], acnt[i]);281 else GetArea(i).Set(-1., -1., 0);282 }264 } 265 266 for (int i=0; i<ns; i++) 267 if (scnt[i]>0) 268 GetSector(i).Set(ssumx[i]/scnt[i], ssumr[i]/scnt[i], scnt[i]); 269 else 270 GetSector(i).Clear(); 271 272 for (int i=0; i<na; i++) 273 if (acnt[i]>0) 274 GetArea(i).Set(asumx[i]/acnt[i], asumr[i]/acnt[i], acnt[i]); 275 else 276 GetArea(i).Clear(); 283 277 } 284 278
Note:
See TracChangeset
for help on using the changeset viewer.