IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 16001


Ignore:
Timestamp:
Jan 4, 2008, 11:17:49 AM (18 years ago)
Author:
eugene
Message:

handle N < 2, values are nan, inf

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/tools/src/medianfilter.c

    r14820 r16001  
    101101        v = (float *)tmpmatr[k].buffer;
    102102        if (v[j] < MinValid) continue;
     103        if (isnan(v[j])) continue;
     104        if (isinf(v[j])) continue;
    103105        list[k] = v[j];
    104106        Nvalid ++;
     
    138140  float temp;
    139141 
     142  if (N < 2) return;
     143
    140144  l = N >> 1;
    141145  ir = N - 1;
Note: See TracChangeset for help on using the changeset viewer.