Index: branches/eam_branches/ipp-20110213/psphot/src/psphotCullPeaks.c
===================================================================
--- branches/eam_branches/ipp-20110213/psphot/src/psphotCullPeaks.c	(revision 30931)
+++ branches/eam_branches/ipp-20110213/psphot/src/psphotCullPeaks.c	(revision 30932)
@@ -1,3 +1,5 @@
 # include "psphotInternal.h"
+
+# define CULL_WITH_SMOOTHED_IMAGE 1
 
 /*
@@ -61,4 +63,10 @@
     float SAT_THRESHOLD  = 0.05*SATURATION;
 
+# if (CULL_WITH_SMOOTHED_IMAGE)
+    psLogMsg ("psphot", PS_LOG_INFO, "Culling peaks from footprints using the smoothed image");
+# else
+    psLogMsg ("psphot", PS_LOG_INFO, "Culling peaks from footprints using the raw (unsmoothed) image");
+# endif
+
     for (int i = 0; i < footprints->n; i++) {
 	pmFootprint *fp = footprints->data[i];
@@ -78,18 +86,21 @@
 	}
 
-	// if we cull using the significance image, then the thresholds are different
+# if (CULL_WITH_SMOOTHED_IMAGE)
+	// New (post r30869) style of culling using the smoothed image and variance (S/N)
+	// if we cull using the significance image, then the definition of variance is different (thus the bool in arg 8)
+	if (pmFootprintCullPeaks(signifR->image, signifR->variance, fp, nsigma_delta, fPadding, MIN_THRESHOLD, max_threshold, false) != PS_ERR_NONE) {
+	    return psError(PS_ERR_UNKNOWN, false, "Culling pmFootprint %d", fp->id);
+	}
+# else 
+	// Old (pre r30869) style of culling using the raw image and variance
+	if (pmFootprintCullPeaks(readout->image, readout->variance, fp, nsigma_delta, fPadding, MIN_THRESHOLD, max_threshold, true) != PS_ERR_NONE) {
+	     return psError(PS_ERR_UNKNOWN, false, "Culling pmFootprint %d", fp->id);
+	}
+# endif
+
+// Alternate style of culling using the smoothed image and raw variance (probably a bad idea)
 # if (0)
 	if (pmFootprintCullPeaks(signifR->image, readout->variance, fp, nsigma_delta, fPadding, MIN_THRESHOLD, max_threshold, true) != PS_ERR_NONE) {
 	    return psError(PS_ERR_UNKNOWN, false, "Culling pmFootprint %d", fp->id);
-	}
-# endif
-# if (1)
-	if (pmFootprintCullPeaks(signifR->image, signifR->variance, fp, nsigma_delta, fPadding, MIN_THRESHOLD, max_threshold, false) != PS_ERR_NONE) {
-	    return psError(PS_ERR_UNKNOWN, false, "Culling pmFootprint %d", fp->id);
-	}
-# endif
-# if (0)
-	if (pmFootprintCullPeaks(readout->image, readout->variance, fp, nsigma_delta, fPadding, MIN_THRESHOLD, max_threshold, true) != PS_ERR_NONE) {
-	     return psError(PS_ERR_UNKNOWN, false, "Culling pmFootprint %d", fp->id);
 	}
 # endif
Index: branches/eam_branches/ipp-20110213/psphot/src/psphotGuessModels.c
===================================================================
--- branches/eam_branches/ipp-20110213/psphot/src/psphotGuessModels.c	(revision 30931)
+++ branches/eam_branches/ipp-20110213/psphot/src/psphotGuessModels.c	(revision 30932)
@@ -182,20 +182,5 @@
         // moments
 
-# if (1)
-        bool useMoments = true;
-# else
-        bool useMoments = false;
-        useMoments = (source->mode & PM_SOURCE_MODE_SATSTAR);  // we only want to try if SATSTAR is set, but..
-# endif
-
-	float dX = source->moments->Mx - source->peak->xf;
-	float dY = source->moments->My - source->peak->yf;
-	float dR = hypot(dX, dY);
-
-        useMoments = useMoments && source->moments;          // can't if there are no moments
-        useMoments = useMoments && source->moments->nPixels; // can't if the moments were not measured
-        useMoments = useMoments && !(source->mode & PM_SOURCE_MODE_MOMENTS_FAILURE); // can't if the moments failed...
-	useMoments = useMoments && ((dR < 1.5) || (source->mode & PM_SOURCE_MODE_SATSTAR));
-	// only use the moments position if the moment-peak offset is small or the star is saturated
+        bool useMoments = pmSourcePositionUseMoments(source);
 
         float Xo, Yo;
Index: branches/eam_branches/ipp-20110213/psphot/src/psphotRadialApertures.c
===================================================================
--- branches/eam_branches/ipp-20110213/psphot/src/psphotRadialApertures.c	(revision 30931)
+++ branches/eam_branches/ipp-20110213/psphot/src/psphotRadialApertures.c	(revision 30932)
@@ -176,7 +176,12 @@
     }
 
-    // center of the apertures
-    float xCM = source->moments->Mx - 0.5 - source->pixels->col0; // coord of peak in subimage
-    float yCM = source->moments->My - 0.5 - source->pixels->row0; // coord of peak in subimage
+    float xCM = NAN, yCM = NAN;
+    if (pmSourcePositionUseMoments(source)) {
+	xCM = source->moments->Mx - 0.5 - source->pixels->col0; // coord of peak in subimage
+	yCM = source->moments->My - 0.5 - source->pixels->row0; // coord of peak in subimage
+    } else {
+	xCM = source->peak->xf - 0.5 - source->pixels->col0; // coord of peak in subimage
+	yCM = source->peak->yf - 0.5 - source->pixels->row0; // coord of peak in subimage
+    }
 
     // one pass through the pixels to select the valid pixels and calculate R^2
