Changeset 1456 for trunk/MagicSoft/Mars/manalysis/MImgCleanStd.cc
- Timestamp:
- 07/30/02 14:29:49 (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/manalysis/MImgCleanStd.cc
r1455 r1456 89 89 // (std: 3 sigma, clean level 1) 90 90 // 91 void MImgCleanStd::CleanStep1() 91 // Returns the maximum Pixel Id (used for ispixused in CleanStep2) 92 // 93 Int_t MImgCleanStd::CleanStep1() 92 94 { 93 95 const Int_t entries = fEvt->GetNumPixels(); 96 97 Int_t max = entries; 94 98 95 99 // … … 107 111 if (entry <= fCleanLvl1 * noise) 108 112 pix.SetPixelUnused(); 109 } 113 114 if (pix.GetPixId()>max) 115 max = pix.GetPixId(); 116 } 117 return max; 110 118 } 111 119 … … 115 123 // survived 116 124 // 117 void MImgCleanStd::CleanStep2() 125 // takes the maximum pixel id from CleanStep1 as an argument 126 // 127 void MImgCleanStd::CleanStep2(Int_t max) 118 128 { 119 129 const Int_t entries = fEvt->GetNumPixels(); … … 125 135 // (MCerPhotEvt::IsPixelUsed) all the time. 126 136 // 127 // FIXME: The dynamic allocation may still be a problem if we 128 // don't store all pixels in the array... but this music 129 // of the future ;-) 130 Byte_t *ispixused = new Byte_t[fEvt->GetNumPixels()]; 137 Byte_t *ispixused = new Byte_t[max]; 131 138 132 139 for (Int_t i=0; i<entries; i++)
Note:
See TracChangeset
for help on using the changeset viewer.