Index: trunk/psphot/src/apply_psf_model.c
===================================================================
--- trunk/psphot/src/apply_psf_model.c	(revision 4216)
+++ trunk/psphot/src/apply_psf_model.c	(revision 4251)
@@ -5,7 +5,9 @@
 // run this function to a specific flux limit?
 
-bool apply_psf_model (psImage *image, psMetadata *config, psArray *sources, pmPSF *psf, psStats *sky) 
+bool apply_psf_model (psImageData *imdata, psMetadata *config, psArray *sources, pmPSF *psf, psStats *sky) 
 { 
     bool  status;
+    float x;
+    float y;
     int   Nfit = 0;
     int   Niter = 0;
@@ -42,4 +44,5 @@
 	x = model->params->data.F32[2];
 	y = model->params->data.F32[3];
+	// XXX I need to check if the model center has moved too much relative to the peak
 
 	// set the fit radius based on the object flux limit and the model
@@ -51,7 +54,4 @@
 	}
 	
-	// mask off saturated pixels (move this to setup?)
-	pmSourceMaskSaturated (source, SATURATE);
-
 	// check if we need to redefine the pixels
 	if (model->radius > OUTER) {
