Changeset 10550 for trunk/psLib/src/imageops/psImageBackground.c
- Timestamp:
- Dec 8, 2006, 1:38:54 AM (19 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/imageops/psImageBackground.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/imageops/psImageBackground.c
r10396 r10550 73 73 if (!psVectorSort(values, values)) { 74 74 psError(PS_ERR_UNKNOWN, false, "Unable to sort values.\n"); 75 psFree(stats);76 75 psFree(values); 77 return NULL;76 return false; 78 77 } 79 78 … … 91 90 } else { 92 91 // XXX leave this as a psphot user option (passed in as part of stats?) 93 if ( stats->options & PS_STAT_FITTED_MEAN) {92 if ((stats->options & PS_STAT_FITTED_MEAN) || (stats->options & PS_STAT_FITTED_MEAN_V2)) { 94 93 stats->clipSigma = 1.0; 95 94 } 96 if ( psVectorStats (stats, values, NULL, NULL, 0) == NULL) {95 if (!psVectorStats (stats, values, NULL, NULL, 0)) { 97 96 psError(PS_ERR_UNKNOWN, false, "Unable to measure statistics for image background " 98 97 "(%dx%d, (row0,col0) = (%d,%d)", 99 98 image->numRows, image->numCols, image->row0, image->col0); 100 psFree(stats);101 99 psFree(values); 102 return NULL;100 return false; 103 101 } 104 102 } 105 103 106 104 psFree(values); 107 return stats;105 return true; 108 106 }
Note:
See TracChangeset
for help on using the changeset viewer.
