Index: trunk/archive/scripts/src/phase2/papPhase2.c
===================================================================
--- trunk/archive/scripts/src/phase2/papPhase2.c	(revision 5633)
+++ trunk/archive/scripts/src/phase2/papPhase2.c	(revision 5651)
@@ -17,4 +17,5 @@
 #include "pmSubtractBias.h"
 #include "pmChipMosaic.h"
+#include "pmFPAMorph.h"
 
 // Phase 2 needs to:
@@ -287,4 +288,7 @@
     }
 
+    pmFPAPrint(input);
+    exit(1);
+
 #ifdef PRODUCTION
     psFitsClose(inputFile);
@@ -296,5 +300,5 @@
     pmFPAReadMask(input, inputFile);
     pmFPAReadWeight(input, inputFile);
-#else
+//#else
     {
 	// Generate mask and weight frame
@@ -827,8 +831,22 @@
     psLogMsg("phase2", PS_LOG_INFO, "Processing completed after %f sec.\n", psTimerMark("phase2"));
 
+
+#if 1
+    // Testing pmFPAMorph
+    psMetadata *newCamera = psMetadataConfigParse(NULL, NULL, "megacam_splice.config", true);
+    pmFPA *newFPA = pmFPAConstruct(newCamera);
+    pmFPAMorph(newFPA, input, true, 0, 0);
+    psFits *newFile = psFitsAlloc("morph.fits");
+    pmFPAWrite(newFile, newFPA, database);
+    psFree(newFile);
+    psFree(newFPA);
+#endif
+
+#if 0
     // Write the output
     pmFPAWrite(outputFile, input, database);
     pmFPAWriteMask(input, outputFile);
     pmFPAWriteWeight(input, outputFile);
+#endif
 
     psLogMsg("phase2", PS_LOG_INFO, "Output completed after %f sec.\n", psTimerMark("phase2"));
