Index: trunk/dvodist/www-util/tracker.html
===================================================================
--- trunk/dvodist/www-util/tracker.html	(revision 35770)
+++ trunk/dvodist/www-util/tracker.html	(revision 35770)
@@ -0,0 +1,17 @@
+<!-- Start eXTReMe Pro Tracker Code V3/7
+Login:    emagnier
+Help:     https://www.extremetracking.com
+Installation instructions:
+Copy and paste this code between the two body tags into the
+*source* of your pages or in your footer/template. Best is
+to use a normal text editor such as notepad. -->
+<script type="text/javascript"><!--
+EXd=document;location.protocol=="https:"?EXp="https":EXp="http";EXs="src";
+EXd.write("<img "+EXs+"="+EXp+"://nht-2.extreme-dm.com/n2.g?login=emagnier",
+"&url="+escape(EXd.URL)+"&jv="+navigator.javaEnabled()+"&",
+"d="+screen.width+"x"+screen.height+"&c="+screen.colorDepth+"",
+"&l="+escape(EXd.referrer)+" width=0 height=0>");//-->
+</script><noscript><img height="1" width="1" alt=""
+src="http://nht-2.extreme-dm.com/n2.g?login=emagnier&amp;url=nojs">
+</noscript>
+<!-- End eXTReMe Pro Tracker Code -->
Index: trunk/ippconfig/recipes/psphot.config
===================================================================
--- trunk/ippconfig/recipes/psphot.config	(revision 35769)
+++ trunk/ippconfig/recipes/psphot.config	(revision 35770)
@@ -106,4 +106,7 @@
 PSF_MIN_DS                          F32   0.01
 PSF_PARAM_WEIGHTS                   BOOL  FALSE
+
+LMM_FIT_CHISQ_CONVERGENCE           BOOL  TRUE            # use the (old) chisq convergence or the new parameter one 
+LMM_FIT_GAIN_FACTOR_MODE            S32   0               # there are 3 options to determine the gain factor (0,1,2)
 
 PSF_FIT_ITER                        S32   50              # Maximum number of fitting iterations for PSF
@@ -204,4 +207,6 @@
 # these models are used for high-quality shape analysis after all sources have been removed
 EXTENDED_SOURCE_FITS                BOOL  FALSE  # perform the detailed extended sourc fits?
+
+EXTENDED_SOURCE_MODELS_SELECTION    STR   ALL
 
 # extended source models applied to sources
@@ -613,2 +618,31 @@
 END
 
+GALAXY_TEST METADATA
+  # Extended source fit parameters
+  # these models are used for high-quality shape analysis after all sources have been removed
+  EXTENDED_SOURCE_FITS                BOOL  TRUE  # perform the detailed extended sourc fits?
+  EXT_MODEL                           STR   PS_MODEL_EXP
+
+  # if this is defined, it gives a list of the model names to fit below (ALL or NONE are also valid)
+  EXTENDED_SOURCE_MODELS_SELECTION    STR   NONE
+
+  # extended source models applied to sources
+  EXTENDED_SOURCE_MODELS METADATA 
+    TYPE      EXTENDED_SOURCE_MODEL  MODEL            SNLIM   PSF_CONVOLVED
+    EXP_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_EXP     10.0    TRUE
+    DEV_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_DEV     10.0    TRUE
+    SER_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_SERSIC  10.0    TRUE
+    GAU_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_GAUSS   10.0    TRUE
+    PGA_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_PGAUSS  10.0    TRUE
+    QGA_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_QGAUSS  10.0    TRUE
+    PS1_CONV  EXTENDED_SOURCE_MODEL  PS_MODEL_PS1_V1  10.0    TRUE
+
+    EXP_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_EXP     10.0    FALSE
+    DEV_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_DEV     10.0    FALSE
+    SER_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_SERSIC  10.0    FALSE
+    GAU_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_GAUSS   10.0    FALSE
+    PGA_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_PGAUSS  10.0    FALSE
+    QGA_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_QGAUSS  10.0    FALSE
+    PS1_RAW   EXTENDED_SOURCE_MODEL  PS_MODEL_PS1_V1  10.0    FALSE
+  END
+END
Index: trunk/ppSim/src/ppSimInsertStars.c
===================================================================
--- trunk/ppSim/src/ppSimInsertStars.c	(revision 35769)
+++ trunk/ppSim/src/ppSimInsertStars.c	(revision 35770)
@@ -125,5 +125,5 @@
 	// XXX set the mag & err values (should this be done in pmSourceFromModel?)
 	// XXX i should be applying the gain and the correct effective area
-	psEllipseAxes axes = pmPSF_ModelToAxes (model->params->data.F32, 20.0, model->type);
+	psEllipseAxes axes = pmPSF_ModelToAxes (model->params->data.F32, model->type);
 	float Area = 2.0 * M_PI * axes.major * axes.minor;
 
Index: trunk/ppSim/src/ppSimSetPSF.c
===================================================================
--- trunk/ppSim/src/ppSimSetPSF.c	(revision 35769)
+++ trunk/ppSim/src/ppSimSetPSF.c	(revision 35770)
@@ -118,4 +118,7 @@
 
 	pol = psEllipseAxesToPol (axes);
+	psEllipseAxes testaxes = psEllipsePolToAxes (pol, 0.1);
+	fprintf (stderr, "psf in axes: %f x %f @ %f\n", axes.major, axes.minor, axes.theta*PS_DEG_RAD);
+	fprintf (stderr, "psf ot axes: %f x %f @ %f\n", testaxes.major, testaxes.minor, testaxes.theta*PS_DEG_RAD);
     
 	param = psf->params->data[PM_PAR_E0];
