IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 12, 2007, 2:37:22 PM (19 years ago)
Author:
Paul Price
Message:

psClipIter returns immediately if no clipping is desired. Default is no clipping (user must set rejection level explicitly).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psLib/src/math/psClip.c

    r11755 r11756  
    3333    params->numKeep = 0;
    3434    params->iter = 1;
    35     params->rej = 3.0;
     35    params->rej = 0.0;
    3636    params->masked = masked;
    3737    params->clipped = clipped;
     
    131131    PS_ASSERT_INT_NONZERO(params->meanStat, -1);
    132132    PS_ASSERT_INT_NONZERO(params->stdevStat, -1);
    133     if (!isfinite(params->rej) || params->rej <= 0) {
     133    if (!isfinite(params->rej) || params->rej < 0) {
    134134        psError(PS_ERR_BAD_PARAMETER_VALUE, true, "Rejection limit (%f) is not valid.\n", params->rej);
    135135        return -1;
     136    }
     137
     138    if (params->rej == 0.0) {
     139        // No clipping desired
     140        return 0;
    136141    }
    137142
Note: See TracChangeset for help on using the changeset viewer.