Index: trunk/psphot/src/psphotRadiusChecks.c
===================================================================
--- trunk/psphot/src/psphotRadiusChecks.c	(revision 13035)
+++ trunk/psphot/src/psphotRadiusChecks.c	(revision 14655)
@@ -6,5 +6,4 @@
 static float PSF_FIT_RADIUS = 0;	// radius to use in fitting (ignored if <= 0,
 					// and a per-object radius is calculated)
-static pmModelRadius modelRadiusPSF;
 
 bool psphotInitRadiusPSF(const psMetadata *recipe,
@@ -17,6 +16,4 @@
     PSF_FIT_RADIUS =  psMetadataLookupF32(&status, recipe, "PSF_FIT_RADIUS");
 
-    // this function specifies the radius at this the model hits the given flux
-    modelRadiusPSF       = pmModelRadius_GetFunction (type);
     return true;
 }
@@ -34,7 +31,7 @@
     if (radiusFit <= 0) {		// use fixed radius
 	if (moments == NULL) {
-	    radiusFit = modelRadiusPSF(model->params, PSF_FIT_NSIGMA*moments->dSky);
+	    radiusFit = model->modelRadius(model->params, PSF_FIT_NSIGMA*moments->dSky);
 	} else {
-	    radiusFit = modelRadiusPSF(model->params, 1.0);
+	    radiusFit = model->modelRadius(model->params, 1.0);
 	}
     }
@@ -62,5 +59,5 @@
 
     // set the fit radius based on the object flux limit and the model
-    model->radiusFit = (RADIUS_TYPE) (modelRadiusPSF (model->params, PSF_FIT_NSIGMA*moments->dSky) + dR + PSF_FIT_PADDING);
+    model->radiusFit = (RADIUS_TYPE) (model->modelRadius (model->params, PSF_FIT_NSIGMA*moments->dSky) + dR + PSF_FIT_PADDING);
     if (isnan(model->radiusFit)) psAbort("error in radius");
 	
@@ -78,5 +75,4 @@
 static float EXT_FIT_NSIGMA;
 static float EXT_FIT_PADDING;
-static pmModelRadius modelRadiusEXT;
 
 bool psphotInitRadiusEXT (psMetadata *recipe, pmModelType type) {
@@ -87,6 +83,4 @@
     EXT_FIT_PADDING  = psMetadataLookupF32 (&status, recipe, "EXT_FIT_PADDING");
 
-    // this function specifies the radius at this the model hits the given flux
-    modelRadiusEXT       = pmModelRadius_GetFunction (type);
     return true;
 }
@@ -101,5 +95,5 @@
 
     // set the fit radius based on the object flux limit and the model
-    model->radiusFit = (RADIUS_TYPE) (modelRadiusEXT (model->params, EXT_FIT_NSIGMA*moments->dSky) + EXT_FIT_PADDING);
+    model->radiusFit = (RADIUS_TYPE) (model->modelRadius (model->params, EXT_FIT_NSIGMA*moments->dSky) + EXT_FIT_PADDING);
     if (isnan(model->radiusFit)) psAbort("error in radius");
 
