- Timestamp:
- Aug 3, 2011, 10:30:02 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20110710/psphot/src/psphotRadiusChecks.c
r31452 r31990 142 142 } 143 143 144 # define MIN_WINDOW 5.0 145 # define SCALE1 5.0 146 # define SCALE2 12.5 147 148 // call this function whenever you (re)-define the EXT model 149 bool psphotSetRadiusMoments (float *fitRadius, float *windowRadius, pmReadout *readout, pmSource *source, psImageMaskType markVal) { 150 151 psAssert (source, "source not defined??"); 152 psAssert (source->moments, "moments not defined??"); 153 154 *fitRadius = SCALE1 * source->moments->Mrf; 155 *fitRadius = PS_MIN (PS_MAX(*fitRadius, MIN_WINDOW), EXT_FIT_MAX_RADIUS); 156 157 *windowRadius = SCALE2 * source->moments->Mrf; 158 *windowRadius = PS_MIN (PS_MAX(*windowRadius, 2.5*MIN_WINDOW), 2.5*EXT_FIT_MAX_RADIUS); 159 160 // redefine the pixels if needed 161 pmSourceRedefinePixels (source, readout, source->peak->xf, source->peak->yf, *windowRadius); 162 163 // set the mask to flag the excluded pixels 164 psImageKeepCircle (source->maskObj, source->peak->xf, source->peak->yf, *fitRadius, "OR", markVal); 165 166 return true; 167 } 168 144 169 // call this function whenever you (re)-define the EXT model 145 170 bool psphotSetRadiusFootprint (float *radius, pmReadout *readout, pmSource *source, psImageMaskType markVal, float factor) {
Note:
See TracChangeset
for help on using the changeset viewer.
