Changeset 3495


Ignore:
Timestamp:
03/13/04 17:14:43 (21 years ago)
Author:
gaug
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r3494 r3495  
    2828   * mcalib/MHCalibrationChargeCam.cc
    2929     - replaced Rel. Err. Limit for outliers in Phe's from 5 sigma to 7
     30
     31   * mraw/MRawEvtPixelIter.[h,cc]
     32     - function GetIdxMaxLoGainSamples can be called optionally with
     33       offset (because first "loGain" samples are often in reality
     34       hiGain with high values.
    3035
    3136
  • trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.cc

    r3183 r3495  
    233233// last one is returned.
    234234//
    235 Short_t MRawEvtPixelIter::GetIdxMaxLoGainSample() const
    236 {
    237     if (!HasLoGain())
    238         return -1; // means: not found
    239 
    240     Byte_t *ptr = fLoGainPos+1;
    241     Byte_t *max = fLoGainPos;
    242     const Byte_t *end = ptr + fNumLoGainSamples;
    243 
    244     do if (*ptr>*max) max = ptr;
    245     while (++ptr != end);
    246 
    247     return max-fLoGainPos;
     235Short_t MRawEvtPixelIter::GetIdxMaxLoGainSample(const Byte_t lofirst) const
     236{
     237
     238  if (!HasLoGain())
     239    return -1; // means: not found
     240 
     241  Byte_t *ptr = fLoGainPos+lofirst;
     242  Byte_t *max = ptr;
     243  const Byte_t *end = fLoGainPos + fNumLoGainSamples;
     244 
     245  do if (*ptr>*max) max = ptr;
     246  while (++ptr != end);
     247 
     248  return max-fLoGainPos;
    248249}
    249250
  • trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.h

    r3267 r3495  
    8787    Byte_t  GetMaxLoGainSample() const;
    8888    Byte_t  GetIdxMaxHiGainSample() const;
    89     Short_t GetIdxMaxLoGainSample() const;
     89    Short_t GetIdxMaxLoGainSample(const Byte_t lofirst=0) const;
    9090    Short_t GetIdxMaxHiLoGainSample() const;
    9191
Note: See TracChangeset for help on using the changeset viewer.