Index: /trunk/psLib/test/astronomy/tst_psAstrometry01.c
===================================================================
--- /trunk/psLib/test/astronomy/tst_psAstrometry01.c	(revision 3975)
+++ /trunk/psLib/test/astronomy/tst_psAstrometry01.c	(revision 3976)
@@ -5,6 +5,6 @@
 *  @author GLG, MHPCC
 *
-*  @version $Revision: 1.27 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2005-05-11 22:00:35 $
+*  @version $Revision: 1.28 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2005-05-19 05:03:48 $
 *
 * XXX: Must test
@@ -719,5 +719,6 @@
                                     psPlaneTransform *trans3 = NULL;
                                     setCoeffs(trans1, trans2);
-                                    trans3 = psPlaneTransformCombine(NULL, trans1, trans2);
+                                    trans3 = psPlaneTransformCombine(NULL, trans1, trans2,psRegionSet(NAN,NAN,NAN,NAN),0);
+                                    //XXX: the last two parameters are bogus.  Needs to change.  -rdd
 
                                     if (trans3 == NULL) {
@@ -749,5 +750,5 @@
     printf("----------------------------------------------------------------------------------\n");
     printf("Calling psPlaneTransformCombine with NULL trans1.  Should generate error and return NULL.\n");
-    trans3 = psPlaneTransformCombine(NULL, NULL, trans2);
+    trans3 = psPlaneTransformCombine(NULL, NULL, trans2, psRegionSet(0,0,0,0), 10);
     if (trans3 != NULL) {
         printf("TEST ERROR: psPlaneTransformCombine() returned a non-NULL psPlaneTransform.\n");
@@ -758,5 +759,5 @@
     printf("----------------------------------------------------------------------------------\n");
     printf("Calling psPlaneTransformCombine with NULL trans2.  Should generate error and return NULL.\n");
-    trans3 = psPlaneTransformCombine(NULL, trans1, NULL);
+    trans3 = psPlaneTransformCombine(NULL, trans1, NULL, psRegionSet(0,0,0,0), 10);
     if (trans3 != NULL) {
         printf("TEST ERROR: psPlaneTransformCombine() returned a non-NULL psPlaneTransform.\n");
@@ -908,5 +909,5 @@
     psPlaneTransform *trans = psPlaneTransformAlloc(2, 2);
     psPlaneTransform *transOut = NULL;
-    psRegion *myRegion = psRegionAlloc(1.0, 5.0, 1.0, 5.0);
+    psRegion myRegion = psRegionSet(1.0, 5.0, 1.0, 5.0);
 
     //
@@ -931,12 +932,4 @@
     }
 
-    printf("----------------------------------------------------------------------------------\n");
-    printf("Calling psPlaneTransformInvert with NULL psRegion.  Should generate error and return NULL.\n");
-    transOut = psPlaneTransformInvert(NULL, trans, NULL, 10);
-    if (transOut != NULL) {
-        printf("TEST ERROR: psPlaneTransformInvert() returned a non-NULL psPlaneTransform.\n");
-        testStatus = false;
-        psFree(transOut);
-    }
     printf("----------------------------------------------------------------------------------\n");
     printf("Calling psPlaneTransformInvert with zero nSamples.  Should generate error and return NULL.\n");
@@ -988,5 +981,4 @@
 
     psFree(trans);
-    psFree(myRegion);
 
     fflush(stdout);
Index: /trunk/psLib/test/image/tst_psImage.c
===================================================================
--- /trunk/psLib/test/image/tst_psImage.c	(revision 3975)
+++ /trunk/psLib/test/image/tst_psImage.c	(revision 3976)
@@ -6,6 +6,6 @@
  *  @author Robert DeSonia, MHPCC
  *
- *  @version $Revision: 1.33 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2005-05-19 02:49:40 $
+ *  @version $Revision: 1.34 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2005-05-19 05:03:48 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -22,5 +22,4 @@
 
 static psS32 testImageAlloc(void);
-static psS32 testImageCopy(void);
 static psS32 testRegion(void);
 
@@ -28,6 +27,5 @@
                               {testImageAlloc,546,"psImageAlloc",0,false},
                               {testImageAlloc,548,"psImageFree",0,true},
-                              {testImageCopy,551,"psImageCopy",0,false},
-                              {testRegion,790,"psRegionAlloc",0,false},
+                              {testRegion,790,"psRegionSet",0,false},
                               {testRegion,791,"psRegionFromString",0,true},
                               {NULL}
@@ -237,145 +235,4 @@
 }
 
-psS32 testImageCopy(void)
-{
-    psImage* img = NULL;
-    psImage* img2 = NULL;
-    psImage* img3 = NULL;
-    psImage* img4 = NULL;
-    psU32 c = 128;
-    psU32 r = 256;
-
-    img = psImageAlloc(c,r,PS_TYPE_F32);
-    for (unsigned row=0;row<r;row++) {
-        psF32* imgRow = img->data.F32[row];
-        for (unsigned col=0;col<c;col++) {
-            imgRow[col] = (psF32)(row+col);
-        }
-    }
-    img2 = psImageAlloc(c,r,PS_TYPE_F32);
-    for (unsigned row=0;row<r;row++) {
-        psF32* img2Row = img2->data.F32[row];
-        for (unsigned col=0;col<c;col++) {
-            img2Row[col] = 0.0f;
-        }
-    }
-
-    img3 = psImageCopy(img2,img,PS_TYPE_F32);
-
-    // Verify the returned psImage structure pointer is equal to the input parameter output.
-    if (img2 != img3) {
-        psError(PS_ERR_UNKNOWN, true,"the image given for recycled wasn't");
-        return 1;
-    }
-
-    // Verify the returned psImage structure is the same type as the input image structure
-    // if the specified output argument is NULL.
-    img4 = psImageCopy(NULL,img,PS_TYPE_F32);
-    if (img4 == NULL) {
-        psError(PS_ERR_UNKNOWN, true,"output image doesn't exist");
-        return 4;
-    }
-    if (img4->type.type != img->type.type) {
-        psError(PS_ERR_UNKNOWN, true,"output image is not the same type as input image");
-        return 4;
-    }
-    for (psU32 row=0;row<r;row++) {
-        psF32* imgInRow = img->data.F32[row];
-        psF32* imgOutRow = img4->data.F32[row];
-        for (unsigned col=0;col<c;col++) {
-            if( imgInRow[col] != imgOutRow[col] ) {
-                psError(PS_ERR_UNKNOWN, true,"Input image not equal to output image at %d,%d!",
-                        col, row);
-                return 4;
-            }
-        }
-    }
-
-    // Verify the returned psImage structure member are equal to the values in
-    // the input psImage structure input.
-
-    #define testImageCopyType(IN,OUT) \
-    img = psImageRecycle(img,c,r,PS_TYPE_##IN); \
-    for (unsigned row=0;row<r;row++) { \
-        ps##IN* imgRow = img->data.IN[row]; \
-        for (unsigned col=0;col<c;col++) { \
-            imgRow[col] = (ps##IN)(row+col); \
-        } \
-    } \
-    img2 = psImageCopy(img2,img,PS_TYPE_##OUT); \
-    if (img2 == NULL) { \
-        psError(PS_ERR_UNKNOWN, true,"psImageCopy failed to copy U8."); \
-        return 2; \
-    } \
-    for (psU32 row=0;row<r;row++) { \
-        ps##IN* imgRow = img->data.IN[row]; \
-        ps##OUT* img2Row = img2->data.OUT[row]; \
-        for (psU32 col=0;col<c;col++) { \
-            if (abs(imgRow[col] - (ps##IN)(row+col)) > 0.5) { \
-                psError(PS_ERR_UNKNOWN, true,"Input image was changed at %d,%d!", \
-                        col,row); \
-                return 2; \
-            } \
-            if (abs(img2Row[col] - (ps##OUT)(imgRow[col])) > 0.5) { \
-                psError(PS_ERR_UNKNOWN, true,"returned psImage values after copy don't match at %d,%d " \
-                        "(%d vs %d)",\
-                        col,row,img2Row[col], (ps##OUT)(imgRow[col])); \
-                return 2; \
-            } \
-        } \
-    }
-
-    #define testImageCopyTypes(IN) \
-    printf("to psF32\n"); \
-    testImageCopyType(IN,F32);\
-    printf("to psF64\n"); \
-    testImageCopyType(IN,F64); \
-    printf("to psU8\n"); \
-    testImageCopyType(IN,U8); \
-    printf("to psU16\n"); \
-    testImageCopyType(IN,U16); \
-    printf("to psU32\n"); \
-    testImageCopyType(IN,U32); \
-    printf("to psS8\n"); \
-    testImageCopyType(IN,S8);\
-    printf("to psS16\n"); \
-    testImageCopyType(IN,S16);\
-    printf("to psS32\n"); \
-    testImageCopyType(IN,S32);
-
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU8");
-    testImageCopyTypes(U8);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU16");
-    testImageCopyTypes(U16);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU32");
-    testImageCopyTypes(U32);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS8");
-    testImageCopyTypes(S8);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS16");
-    testImageCopyTypes(S16);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS32");
-    testImageCopyTypes(S32);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psF32");
-    testImageCopyTypes(F32);
-    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psF64");
-    testImageCopyTypes(F64);
-
-    // Verify the returned psImage structure pointer is null and program
-    // execution doesn't stop, if the input parameter input is null.
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    img3 = psImageCopy(NULL,NULL,PS_TYPE_F32);
-    if (img3 != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageCopy didn't return NULL when input image was NULL.");
-        return 3;
-    }
-
-    psFree(img);
-    psFree(img2);
-    psFree(img3);
-    psFree(img4);
-
-    return 0;
-}
-
 static psS32 testRegion(void)
 {
@@ -385,15 +242,8 @@
     // Testpoint #790
 
-    psRegion* region = psRegionAlloc(1,2,3,4);
+    psRegion region = psRegionSet(1,2,3,4);
 
     testNum++;
-    if (region == NULL) {
-        psError(PS_ERR_UNKNOWN, false,
-                "psRegionAlloc returned a NULL pointer.");
-        return testNum;
-    }
-
-    testNum++;
-    if (region->x0 != 1 || region->x1 != 2 || region->y0 != 3 || region->y1 != 4) {
+    if (region.x0 != 1 || region.x1 != 2 || region.y0 != 3 || region.y1 != 4) {
         psError(PS_ERR_UNKNOWN, false,
                 "The region attributes are not set properly (%s)",
@@ -402,6 +252,4 @@
     }
 
-    psFree(region);
-
     // Testpoint #791
 
@@ -409,12 +257,5 @@
 
     testNum++;
-    if (region == NULL) {
-        psError(PS_ERR_UNKNOWN, false,
-                "psRegionFromString returned a NULL pointer.");
-        return testNum;
-    }
-
-    testNum++;
-    if (region->x0 != 1 || region->x1 != 2 || region->y0 != 3 || region->y1 != 4) {
+    if (region.x0 != 1 || region.x1 != 2 || region.y0 != 3 || region.y1 != 4) {
         psError(PS_ERR_UNKNOWN, false,
                 "The region attributes are not set properly (%s)",
@@ -423,9 +264,8 @@
     }
 
-    psFree(region);
     region = psRegionFromString("[1:2,3:]");
 
     testNum++;
-    if (region != NULL) {
+    if (! isnan(region.x0)) {
         psError(PS_ERR_UNKNOWN, false,
                 "psRegionFromString returned a non-NULL pointer given a malformed string.");
Index: /trunk/psLib/test/image/tst_psImageStructManip.c
===================================================================
--- /trunk/psLib/test/image/tst_psImageStructManip.c	(revision 3975)
+++ /trunk/psLib/test/image/tst_psImageStructManip.c	(revision 3976)
@@ -6,6 +6,6 @@
 *  @author Robert DeSonia, MHPCC
 *
-*  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2005-05-19 02:49:40 $
+*  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2005-05-19 05:03:48 $
 *
 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -19,5 +19,5 @@
 
 static psS32 testImageSubset(void);
-static psS32 testImageSubsection(void);
+static psS32 testImageCopy(void);
 static psS32 testImageTrim(void);
 
@@ -26,5 +26,5 @@
                               {testImageSubset,547,"psImageSubset",0,false},
                               {testImageSubset,550,"psImageSubset",0,true},
-                              {testImageSubsection,730,"psImageSubsection",0,false},
+                              {testImageCopy,551,"psImageCopy",0,false},
                               {testImageTrim, 744, "psImageTrim", 0, false},
                               {NULL}
@@ -46,6 +46,6 @@
     psS32 c = 128;
     psS32 r = 256;
-    psRegion region1 = {0,0,c/2,r/2};
-    psRegion region2 = {c/4,r/4,c/4+c/2,r/4+r/2};
+    psRegion region1 = psRegionSet(0,c/2,0,r/2);
+    psRegion region2 = psRegionSet(c/4,c/4+c/2,r/4,r/4+r/2);
 
     original = psImageAlloc(c,r,PS_TYPE_U32);
@@ -168,8 +168,5 @@
     memcpy(&preSubsetStruct,original,sizeof(psImage));
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,r/2,c/2,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original, psRegionSet(0,c/2,r/2,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when numRows=0.");
@@ -177,8 +174,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                c/2,0,c/2,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original,psRegionSet(c/2,c/2,0,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when numCols=0.");
@@ -196,8 +190,5 @@
 
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,0,c/2,r*2
-                            }
-                           );
+    subset1 = psImageSubset(original, psRegionSet(0,c/2, 0,r*2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset origin was outside of "
@@ -206,8 +197,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,0,c*2,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original,psRegionSet(0,c*2,0,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset origin was outside of "
@@ -216,8 +204,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                -1,0,c/2,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original, psRegionSet(-1,c/2,0,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset origin was outside of "
@@ -226,8 +211,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,-1,c/2,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original, psRegionSet(0,c/2,-1,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset origin was outside of "
@@ -242,8 +224,5 @@
 
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,0,c/2,r+1
-                            }
-                           );
+    subset1 = psImageSubset(original,psRegionSet(0,c/2,0,r+1));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset was outside of image (via rows).");
@@ -251,8 +230,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,0,c+1,r/2
-                            }
-                           );
+    subset1 = psImageSubset(original, psRegionSet(0,c+1,0,r/2));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset was outside of image (via cols).");
@@ -260,8 +236,5 @@
     }
     psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
-    subset1 = psImageSubset(original,(psRegion) {
-                                0,0,c+1,r+1
-                            }
-                           );
+    subset1 = psImageSubset(original,psRegionSet(0,c+1,0,r+1));
     if (subset1 != NULL) {
         psError(PS_ERR_UNKNOWN,true,"psImageSubset didn't return NULL when subset was outside of image (via row+cols).");
@@ -298,156 +271,141 @@
 }
 
-// #730: psImageSubsection shall create child image of a specified size from a parent psImage structure
-psS32 testImageSubsection(void)
+psS32 testImageCopy(void)
 {
-    psImage* original;
-    psImage* subset;
-    psS32 c = 128;
-    psS32 r = 256;
-    psS32 i;
-    psS32 numRegions = 4;
-    psS32 x1[] = {  0, 32, 64, 32};
-    psS32 x2[] = { 32, 64,127, 64};
-    psS32 y1[] = {  0, 32, 32,128};
-    psS32 y2[] = { 32, 64, 64,255};
-
-    original = psImageAlloc(c,r,PS_TYPE_U32);
-    for (psS32 row=0;row<r;row++) {
-        for (psS32 col=0;col<c;col++) {
-            original->data.F32[row][col] = row*1000+col;
-        }
-    }
-
-    for (i=0; i<numRegions; i++) {
-        char sectionStr[64];
-        sprintf(sectionStr,"[%d:%d,%d:%d]",x1[i],x2[i],y1[i],y2[i]);
-
-        psLogMsg(__func__,PS_LOG_INFO,"Testing subsection %s.",
-                 sectionStr);
-
-        subset = psImageSubsection(original,sectionStr);
-
-        if (subset == NULL) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection returned a NULL with a subset of %s.",
-                    sectionStr);
-            return 10*i+1;
-        }
-
-        if (subset->type.type != PS_TYPE_U32) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection output type was not proper(%d, should be %d).",
-                    subset->type.type, PS_TYPE_U32);
-            return 10*i+2;
-        }
-
-        if (subset->col0 != x1[i] || subset->row0 != y1[i]) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't set properly col0/row0 (%d/%d, should be %d/%d).",
-                    subset->col0,subset->row0,x1[i],y1[i]);
-            return 10*i+3;
-        }
-
-        if (subset->parent != original) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't set parent.");
-            return 10*i+4;
-        }
-
-        if (subset->children != NULL) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't set children to NULL.");
-            return 10*i+5;
-        }
-
-        if (original->children == NULL || original->children->n != i+1) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't increment number of children by one per subset.");
-            return 10*i+6;
-        }
-
-
-        if (original->children->data[i] != subset) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't properly store the children pointer.");
-            return 10*i+7;
-        }
-
-        psS32 numCols = x2[i]-x1[i]+1;
-        psS32 numRows = y2[i]-y1[i]+1;
-        if (subset->numCols != numCols || subset->numRows != numRows) {
-            psError(PS_ERR_UNKNOWN,true,"psImageSubsection output size was not proper(%dx%d, should be %dx%d).",
-                    subset->numCols, subset->numRows, numCols, numRows);
-            return 10*i+8;
-        }
-
-        for (psS32 row=0;row<numRows;row++) {
-            for (psS32 col=0;col<numCols;col++) {
-                if (subset->data.U32[row][col] != original->data.U32[row+y1[i]][col+x1[i]]) {
-                    psError(PS_ERR_UNKNOWN,true,"psImageSubset output #1 was wrong at %dx%d (%d vs %d).",
-                            row,col,subset->data.U32[row][col], original->data.U32[row+y1[i]][col+x1[i]]);
-                    return 10*i+9;
-                }
+    psImage* img = NULL;
+    psImage* img2 = NULL;
+    psImage* img3 = NULL;
+    psImage* img4 = NULL;
+    psU32 c = 128;
+    psU32 r = 256;
+
+    img = psImageAlloc(c,r,PS_TYPE_F32);
+    for (unsigned row=0;row<r;row++) {
+        psF32* imgRow = img->data.F32[row];
+        for (unsigned col=0;col<c;col++) {
+            imgRow[col] = (psF32)(row+col);
+        }
+    }
+    img2 = psImageAlloc(c,r,PS_TYPE_F32);
+    for (unsigned row=0;row<r;row++) {
+        psF32* img2Row = img2->data.F32[row];
+        for (unsigned col=0;col<c;col++) {
+            img2Row[col] = 0.0f;
+        }
+    }
+
+    img3 = psImageCopy(img2,img,PS_TYPE_F32);
+
+    // Verify the returned psImage structure pointer is equal to the input parameter output.
+    if (img2 != img3) {
+        psError(PS_ERR_UNKNOWN, true,"the image given for recycled wasn't");
+        return 1;
+    }
+
+    // Verify the returned psImage structure is the same type as the input image structure
+    // if the specified output argument is NULL.
+    img4 = psImageCopy(NULL,img,PS_TYPE_F32);
+    if (img4 == NULL) {
+        psError(PS_ERR_UNKNOWN, true,"output image doesn't exist");
+        return 4;
+    }
+    if (img4->type.type != img->type.type) {
+        psError(PS_ERR_UNKNOWN, true,"output image is not the same type as input image");
+        return 4;
+    }
+    for (psU32 row=0;row<r;row++) {
+        psF32* imgInRow = img->data.F32[row];
+        psF32* imgOutRow = img4->data.F32[row];
+        for (unsigned col=0;col<c;col++) {
+            if( imgInRow[col] != imgOutRow[col] ) {
+                psError(PS_ERR_UNKNOWN, true,"Input image not equal to output image at %d,%d!",
+                        col, row);
+                return 4;
             }
         }
     }
 
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (x1>x2)");
-    subset = psImageSubsection(original,"[64:32,32:64]");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't return NULL when x1 > x2.");
-        return 10*i+10;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (y1>y2)");
-    subset = psImageSubsection(original,"[32:64,64:32]");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN,true,"psImageSubsection didn't return NULL when y1 > y2.");
-        return 10*i+11;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (x2>nCols)");
-    subset = psImageSubsection(original,"[64:256,32:64]"); // assumes c<256
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when x2 > c.");
-        return 10*i+12;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (y2>=nRows)");
-    subset = psImageSubsection(original,"[32:64,64:256]"); // assumes r==256
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when y2 > r.");
-        return 10*i+13;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (malformed string - no brackets)");
-    subset = psImageSubsection(original,"32:64,32:64");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when subsection was '32:64,32:64'.");
-        return 10*i+14;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (malformed string - no colons)");
-    subset = psImageSubsection(original,"[32-64,32-64]");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when subsection was '[32-64,32-64]'.");
-        return 10*i+15;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (malformed string - not four numbers)");
-    subset = psImageSubsection(original,"[32:64,32]");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when subsection was '[32:64,32]'.");
-        return 10*i+16;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (image is NULL)");
-    subset = psImageSubsection(NULL,"[32:64,32:64]");
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when image was NULL.");
-        return 10*i+17;
-    }
-
-    psLogMsg(__func__,PS_LOG_INFO,"An error should follow (subsection string is NULL)");
-    subset = psImageSubsection(original,NULL);
-    if (subset != NULL) {
-        psError(PS_ERR_UNKNOWN, true,"psImageSubsection didn't return NULL when subsection was NULL.");
-        return 10*i+18;
-    }
-
-    psFree(original);
+    // Verify the returned psImage structure member are equal to the values in
+    // the input psImage structure input.
+
+    #define testImageCopyType(IN,OUT) \
+    img = psImageRecycle(img,c,r,PS_TYPE_##IN); \
+    for (unsigned row=0;row<r;row++) { \
+        ps##IN* imgRow = img->data.IN[row]; \
+        for (unsigned col=0;col<c;col++) { \
+            imgRow[col] = (ps##IN)(row+col); \
+        } \
+    } \
+    img2 = psImageCopy(img2,img,PS_TYPE_##OUT); \
+    if (img2 == NULL) { \
+        psError(PS_ERR_UNKNOWN, true,"psImageCopy failed to copy U8."); \
+        return 2; \
+    } \
+    for (psU32 row=0;row<r;row++) { \
+        ps##IN* imgRow = img->data.IN[row]; \
+        ps##OUT* img2Row = img2->data.OUT[row]; \
+        for (psU32 col=0;col<c;col++) { \
+            if (abs(imgRow[col] - (ps##IN)(row+col)) > 0.5) { \
+                psError(PS_ERR_UNKNOWN, true,"Input image was changed at %d,%d!", \
+                        col,row); \
+                return 2; \
+            } \
+            if (abs(img2Row[col] - (ps##OUT)(imgRow[col])) > 0.5) { \
+                psError(PS_ERR_UNKNOWN, true,"returned psImage values after copy don't match at %d,%d " \
+                        "(%d vs %d)",\
+                        col,row,img2Row[col], (ps##OUT)(imgRow[col])); \
+                return 2; \
+            } \
+        } \
+    }
+
+    #define testImageCopyTypes(IN) \
+    printf("to psF32\n"); \
+    testImageCopyType(IN,F32);\
+    printf("to psF64\n"); \
+    testImageCopyType(IN,F64); \
+    printf("to psU8\n"); \
+    testImageCopyType(IN,U8); \
+    printf("to psU16\n"); \
+    testImageCopyType(IN,U16); \
+    printf("to psU32\n"); \
+    testImageCopyType(IN,U32); \
+    printf("to psS8\n"); \
+    testImageCopyType(IN,S8);\
+    printf("to psS16\n"); \
+    testImageCopyType(IN,S16);\
+    printf("to psS32\n"); \
+    testImageCopyType(IN,S32);
+
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU8");
+    testImageCopyTypes(U8);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU16");
+    testImageCopyTypes(U16);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psU32");
+    testImageCopyTypes(U32);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS8");
+    testImageCopyTypes(S8);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS16");
+    testImageCopyTypes(S16);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psS32");
+    testImageCopyTypes(S32);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psF32");
+    testImageCopyTypes(F32);
+    psLogMsg(__func__,PS_LOG_INFO,"Image Copy Test for psF64");
+    testImageCopyTypes(F64);
+
+    // Verify the returned psImage structure pointer is null and program
+    // execution doesn't stop, if the input parameter input is null.
+    psLogMsg(__func__,PS_LOG_INFO,"An error should follow...");
+    img3 = psImageCopy(NULL,NULL,PS_TYPE_F32);
+    if (img3 != NULL) {
+        psError(PS_ERR_UNKNOWN, true,"psImageCopy didn't return NULL when input image was NULL.");
+        return 3;
+    }
+
+    psFree(img);
+    psFree(img2);
+    psFree(img3);
+    psFree(img4);
 
     return 0;
@@ -462,5 +420,5 @@
     psS32 halfR = r/2;
     psS32 halfC = c/2;
-    psRegion centerHalf = {qtrC,qtrR,qtrC+halfC,qtrR+halfR};
+    psRegion centerHalf = {qtrC,qtrC+halfC,qtrR,qtrR+halfR};
 
     psImage* image = psImageAlloc(c,r,PS_TYPE_F32);
@@ -517,8 +475,5 @@
     */
     image1 = psImageCopy(image1,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             qtrC,qtrR,0,0
-                         }
-                        );
+    image2 = psImageTrim(image1,psRegionSet(qtrC,0,qtrR,0));
 
     if (image1 != image2) {
@@ -559,8 +514,5 @@
     */
     image1 = psImageCopy(image1,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             qtrC,qtrR,-qtrC,-qtrR
-                         }
-                        );
+    image2 = psImageTrim(image1,psRegionSet(qtrC,-qtrC, qtrR,-qtrR));
 
     if (image1 != image2) {
@@ -602,8 +554,5 @@
     */
 
-    image2 = psImageTrim(NULL,(psRegion) {
-                             qtrC,qtrR,0,0
-                         }
-                        );
+    image2 = psImageTrim(NULL, psRegionSet(qtrC,0,qtrR,0));
 
     if (image2 != NULL) {
@@ -622,8 +571,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             -1,0,0,0
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(-1,0,0,0));
 
     if (image2 != NULL) {
@@ -642,8 +588,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             0,-1,0,0
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(0,0,-1,0));
 
     if (image2 != NULL) {
@@ -662,8 +605,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             0,0,image->numCols+1,0
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(0,image->numCols+1,0,0));
 
     if (image2 != NULL) {
@@ -682,8 +622,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             0,0,0,image->numRows+1
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(0,0,0,image->numRows+1));
 
     if (image2 != NULL) {
@@ -702,8 +639,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             0,0,-image->numCols,0
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(0,-image->numCols,0,0));
 
     if (image2 != NULL) {
@@ -722,8 +656,5 @@
 
     image1 = psImageCopy(NULL,image,PS_TYPE_F32);
-    image2 = psImageTrim(image1,(psRegion) {
-                             0,0,0,-image->numRows
-                         }
-                        );
+    image2 = psImageTrim(image1, psRegionSet(0,0,0,-image->numRows));
 
     if (image2 != NULL) {
Index: /trunk/psLib/test/image/verified/tst_psImage.stderr
===================================================================
--- /trunk/psLib/test/image/verified/tst_psImage.stderr	(revision 3975)
+++ /trunk/psLib/test/image/verified/tst_psImage.stderr	(revision 3976)
@@ -79,4 +79,8 @@
 <DATE><TIME>|<HOST>|E|psImageAlloc (FILE:LINENO)
     Specified number of rows (0) or columns (0) is invalid.
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [50:99,70:19], is invalid or outside input psImage's boundaries, [0:99,0:99].
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [70:19,90:39], is invalid or outside input psImage's boundaries, [0:99,0:99].
 
 ---> TESTPOINT PASSED (psImage{psImageAlloc} | tst_psImage.c)
@@ -84,34 +88,5 @@
 /***************************** TESTPOINT ******************************************\
 *             TestFile: tst_psImage.c                                              *
-*            TestPoint: psImage{psImageCopy}                                       *
-*             TestType: Positive                                                   *
-\**********************************************************************************/
-
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psU8
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psU16
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psU32
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psS8
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psS16
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psS32
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psF32
-<DATE><TIME>|<HOST>|I|testImageCopy
-    Image Copy Test for psF64
-<DATE><TIME>|<HOST>|I|testImageCopy
-    An error should follow...
-<DATE><TIME>|<HOST>|E|psImageCopy (FILE:LINENO)
-    Can not operate on a NULL psImage.
-
----> TESTPOINT PASSED (psImage{psImageCopy} | tst_psImage.c)
-
-/***************************** TESTPOINT ******************************************\
-*             TestFile: tst_psImage.c                                              *
-*            TestPoint: psImage{psRegionAlloc}                                     *
+*            TestPoint: psImage{psRegionSet}                                       *
 *             TestType: Positive                                                   *
 \**********************************************************************************/
@@ -120,4 +95,4 @@
     Specified subsection string, '[1:2,3:]', can not be parsed.  Must be in the form '[x1:x2,y1:y2]'.
 
----> TESTPOINT PASSED (psImage{psRegionAlloc} | tst_psImage.c)
+---> TESTPOINT PASSED (psImage{psRegionSet} | tst_psImage.c)
 
Index: /trunk/psLib/test/image/verified/tst_psImageGeomManip.stderr
===================================================================
--- /trunk/psLib/test/image/verified/tst_psImageGeomManip.stderr	(revision 3976)
+++ /trunk/psLib/test/image/verified/tst_psImageGeomManip.stderr	(revision 3976)
@@ -0,0 +1,281 @@
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageGeomManip.c                                     *
+*            TestPoint: psImage{psImageRebin}                                      *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for unsupported type.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified psImage type, psU8, is not supported.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for invallid mask type.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Input psImage mask type, psF32, is not the supported mask datatype of psU8.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for scale < 0.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified scale value, 0, must be a positive value.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for stats null.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified statistic can not be NULL.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for stats options 0.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified statistic option, 0, is not valid.  Must specify one and only one statistic type.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for stat options use range.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified statistic option, 8192, is not valid.  Must specify one and only one statistic type.
+<DATE><TIME>|<HOST>|I|testImageRebin
+    Following should be an error for stats with multiple options.
+<DATE><TIME>|<HOST>|E|psImageRebin (FILE:LINENO)
+    Specified statistic option, 2049, is not valid.  Must specify one and only one statistic type.
+
+---> TESTPOINT PASSED (psImage{psImageRebin} | tst_psImageGeomManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageGeomManip.c                                     *
+*            TestPoint: psImage{psImageRoll}                                       *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageRoll
+    Following should generate an error.
+<DATE><TIME>|<HOST>|E|psImageRoll (FILE:LINENO)
+    Can not operate on a NULL psImage.
+
+---> TESTPOINT PASSED (psImage{psImageRoll} | tst_psImageGeomManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageGeomManip.c                                     *
+*            TestPoint: psImage{psImageRotate}                                     *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageWriteSection
+    psImageWriteSection is deprecated.  Consider using psFitsWriteImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|W|psImageReadSection
+    psImageReadSection is deprecated.  Consider using psFitsReadImage instead.
+<DATE><TIME>|<HOST>|I|testImageRotate
+    Following should be an error
+<DATE><TIME>|<HOST>|E|psImageRotate (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageRotate
+    Following should be an error for invalid interpolation type.
+<DATE><TIME>|<HOST>|E|psImageRotate (FILE:LINENO)
+    Specified interpolation mode, -1, is unsupported.
+
+---> TESTPOINT PASSED (psImage{psImageRotate} | tst_psImageGeomManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageGeomManip.c                                     *
+*            TestPoint: psImage{psImageShift}                                      *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 0,0.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 0,16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 0,-16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32,0.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32,0.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32,16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32,-16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32,16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32,-16.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 0,16.4.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 0,-16.4.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32.7,0.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32.7,0.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32.6,16.2.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of 32.6,-16.2.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32.6,16.2.
+<DATE><TIME>|<HOST>|I|testImageShiftCase
+    Testing psImageShift with a 64x128 image for a shift of -32.6,-16.2.
+<DATE><TIME>|<HOST>|I|testImageShift
+    Following should be an error...
+<DATE><TIME>|<HOST>|E|psImageShift (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageShift
+    Following should be an error for invalid interpolation mode.
+<DATE><TIME>|<HOST>|E|psImageShift (FILE:LINENO)
+    Specified interpolation mode, -1, is unsupported.
+
+---> TESTPOINT PASSED (psImage{psImageShift} | tst_psImageGeomManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageGeomManip.c                                     *
+*            TestPoint: psImage{psImageResample}                                   *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|E|psImageResample (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|E|psImageResample (FILE:LINENO)
+    Specified scale value, 0, must be a positive value.
+<DATE><TIME>|<HOST>|E|psImageResample (FILE:LINENO)
+    Specified interpolation mode, -1, is unsupported.
+<DATE><TIME>|<HOST>|E|psImageResample (FILE:LINENO)
+    Specified psImage type, psBool, is not supported.
+
+---> TESTPOINT PASSED (psImage{psImageResample} | tst_psImageGeomManip.c)
+
Index: /trunk/psLib/test/image/verified/tst_psImagePixelExtract.stderr
===================================================================
--- /trunk/psLib/test/image/verified/tst_psImagePixelExtract.stderr	(revision 3976)
+++ /trunk/psLib/test/image/verified/tst_psImagePixelExtract.stderr	(revision 3976)
@@ -0,0 +1,147 @@
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelExtract.c                                  *
+*            TestPoint: psImage{psImageSlice}                                      *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified statistic can not be NULL.
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified slice direction, 5, is invalid.
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified subset range, [30:30,20:20], is invalid or outside input psImage's boundaries, [0:300,0:200].
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified subset range, [301:302,20:30], is invalid or outside input psImage's boundaries, [0:300,0:200].
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified subset range, [30:31,201:205], is invalid or outside input psImage's boundaries, [0:300,0:200].
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified subset range, [30:301,20:21], is invalid or outside input psImage's boundaries, [0:300,0:200].
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified subset range, [30:31,20:201], is invalid or outside input psImage's boundaries, [0:300,0:200].
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Specified statistic option, 0, is not valid.  Must specify one and only one statistic type.
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error mask size != image size.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Input psImage mask size, 200x300, does not match psImage input size, 300x200.
+<DATE><TIME>|<HOST>|I|testImageSlice
+    Following should be an error invalid mask type.
+<DATE><TIME>|<HOST>|E|psImageSlice (FILE:LINENO)
+    Input psImage mask type, psS8, is not the supported mask datatype of psU8.
+
+---> TESTPOINT PASSED (psImage{psImageSlice} | tst_psImagePixelExtract.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelExtract.c                                  *
+*            TestPoint: psImage{psImageCut}                                        *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (-1.000000,10.000000)->(240.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (300.000000,10.000000)->(240.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,10.000000)->(-1.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,10.000000)->(300.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,-1.000000)->(240.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,200.000000)->(240.000000,180.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,10.000000)->(240.000000,-1.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    The following should be an error.
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified line, (20.000000,10.000000)->(240.000000,200.000000), does not entirely lie in psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageCut
+    Following should be an error (NULL image).
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageCut
+    Following should be an error (length=0).
+<DATE><TIME>|<HOST>|E|psImageCut (FILE:LINENO)
+    Specified number of samples, 0, must be greater than 1 to make a line.
+
+---> TESTPOINT PASSED (psImage{psImageCut} | tst_psImagePixelExtract.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelExtract.c                                  *
+*            TestPoint: psImage{psImageRadialCut}                                  *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Specified radii vector can not be NULL.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Specified statistic can not be NULL.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Specified center, (301,100), is outside of the psImage boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Specified center, (150,201), is outside of the psImage boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Input psImage mask type, psF32, is not the supported mask datatype of psU8.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Input psImage mask size, 150x100, does not match psImage input size, 300x200.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Input radii vector size, 1, can not be less than 2.
+<DATE><TIME>|<HOST>|I|testImageRadialCut
+    Following should be an error.
+<DATE><TIME>|<HOST>|E|psImageRadialCut (FILE:LINENO)
+    Specified statistic option, 0, is not valid.  Must specify one and only one statistic type.
+
+---> TESTPOINT PASSED (psImage{psImageRadialCut} | tst_psImagePixelExtract.c)
+
Index: /trunk/psLib/test/image/verified/tst_psImagePixelManip.stderr
===================================================================
--- /trunk/psLib/test/image/verified/tst_psImagePixelManip.stderr	(revision 3976)
+++ /trunk/psLib/test/image/verified/tst_psImagePixelManip.stderr	(revision 3976)
@@ -0,0 +1,148 @@
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelManip.c                                    *
+*            TestPoint: psImage{psImageClip}                                       *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageClip
+    psImageClip shall limit the minimum and maximum data value within a psImage structure
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of F64 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of F32 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of S32 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of S16 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of S8 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of U16 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of U8 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of C32 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Testing clipping of C64 imagery
+<DATE><TIME>|<HOST>|I|testImageClip
+    Following should be an error (max<min)
+<DATE><TIME>|<HOST>|E|psImageClip (FILE:LINENO)
+    Specified min value, 256, can not be greater than the specified max value, 128.
+
+---> TESTPOINT PASSED (psImage{psImageClip} | tst_psImagePixelManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelManip.c                                    *
+*            TestPoint: psImage{psImageClipNAN}                                    *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageClipNAN
+    psImageClipNaN shall modified pixel values of NaN with a specified value
+<DATE><TIME>|<HOST>|I|testImageClipNAN
+    Following should be an error (invalid type)
+<DATE><TIME>|<HOST>|E|psImageClipNaN (FILE:LINENO)
+    Specified psImage type, psS32, is not supported.
+
+---> TESTPOINT PASSED (psImage{psImageClipNAN} | tst_psImagePixelManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelManip.c                                    *
+*            TestPoint: psImage{psImageClipComplexRegion}                          *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    psImageClipNaN shall modified pixel values of NaN with a specified value
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Testing clipping at 409.6+256i to 682.667+512i for psC32
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Testing clipping at 409.6+256i to 682.667+512i for psC64
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified real-portion of min value, 10, can not be greater than the real-portion of max value, 5.
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified imaginary-portion of min value, 10, can not be greater than the imaginary-portion of max value, 5.
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified real-portion of min value, 10, can not be greater than the real-portion of max value, 5.
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmin value, -6.80565e+38+0i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmin value, 6.80565e+38+0i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmin value, 0-6.80565e+38i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmin value, 0+6.80565e+38i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmax value, -6.80565e+38+0i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmax value, 6.80565e+38+0i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmax value, 0-6.80565e+38i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error:
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified vmax value, 0+6.80565e+38i, is not the the range of input psImage's valid pixel values (psC32), i.e. [-3.40282e+38:3.40282e+38].
+<DATE><TIME>|<HOST>|I|testImageClipComplexRegion
+    Following should be an error (invalid type)
+<DATE><TIME>|<HOST>|E|psImageClipComplexRegion (FILE:LINENO)
+    Specified psImage type, psS32, is not supported.
+
+---> TESTPOINT PASSED (psImage{psImageClipComplexRegion} | tst_psImagePixelManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImagePixelManip.c                                    *
+*            TestPoint: psImage{psImageOverlay}                                    *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as overlay isn't within image boundaries
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Specified subset range, [32:160,64:320], is invalid or outside input psImage's boundaries, [0:128,0:256].
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as overlay is NULL
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as image input is NULL
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as operator is invalid
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Specified operation, '$', is not supported.
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as operator is invalid
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Operation can not be NULL.
+<DATE><TIME>|<HOST>|I|testImageOverlay
+    Following should error as overlay is a different type
+<DATE><TIME>|<HOST>|E|psImageOverlaySection (FILE:LINENO)
+    Input overlay psImage type, psS64, must match input psImage type, psF32.
+
+---> TESTPOINT PASSED (psImage{psImageOverlay} | tst_psImagePixelManip.c)
+
Index: /trunk/psLib/test/image/verified/tst_psImageStructManip.stderr
===================================================================
--- /trunk/psLib/test/image/verified/tst_psImageStructManip.stderr	(revision 3976)
+++ /trunk/psLib/test/image/verified/tst_psImageStructManip.stderr	(revision 3976)
@@ -0,0 +1,125 @@
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageStructManip.c                                   *
+*            TestPoint: psImage{psImageSubset}                                     *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure members nrow and ncol are equal to the input parameter nrow and ncol respectively.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure contains expected values in the row member, if the input psImage structure image contains known values.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure member type is equal to the input psImage structure member type.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure members row0 and col0 are equal to the input parameters row0 and col0 respectively.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure member parent is equal to the input psImage structure pointer image.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure member children is null.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the input psImage structure image only has the following members changed: 1) Nchildren is increased by one. 2) parent contains pointer psImage structure out at parent[Nchildren-1].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure pointer is null and program execution doesn't stop, if the input parameter image is null. Also verified the input psImage structure is not modified.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure pointer is null and program  execution doesn't stop, if the input parameters nrow and/or ncol are zero. Also verify input psImage structure is not modified.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:63,128:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [64:63,0:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure pointer is null and program execution doesn't stop, if the input parameters row0 and col0 are not within the range of values of psImage structure image.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:63,0:511], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:255,0:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [-1:63,0:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:63,-1:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    Verify the returned psImage structure pointer is null and program execution doesn't stop if the input parameters nrow, ncol, row0 and col0 specify a range of data not within the input psImage structure image.  Also verify the input psImage structure is not modified.
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:63,0:256], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:128,0:127], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    An error should follow...
+<DATE><TIME>|<HOST>|E|imageSubset (FILE:LINENO)
+    Specified subset range, [0:128,0:256], is invalid or outside input psImage's boundaries, [0:127,0:255].
+<DATE><TIME>|<HOST>|I|testImageSubset
+    psImageFreeChildren shall deallocate any children images of a psImage structure
+
+---> TESTPOINT PASSED (psImage{psImageSubset} | tst_psImageStructManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageStructManip.c                                   *
+*            TestPoint: psImage{psImageCopy}                                       *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psU8
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psU16
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psU32
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psS8
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psS16
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psS32
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psF32
+<DATE><TIME>|<HOST>|I|testImageCopy
+    Image Copy Test for psF64
+<DATE><TIME>|<HOST>|I|testImageCopy
+    An error should follow...
+<DATE><TIME>|<HOST>|E|psImageCopy (FILE:LINENO)
+    Can not operate on a NULL psImage.
+
+---> TESTPOINT PASSED (psImage{psImageCopy} | tst_psImageStructManip.c)
+
+/***************************** TESTPOINT ******************************************\
+*             TestFile: tst_psImageStructManip.c                                   *
+*            TestPoint: psImage{psImageTrim}                                       *
+*             TestType: Positive                                                   *
+\**********************************************************************************/
+
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Can not operate on a NULL psImage.
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [-1:299,0:199], is invalid or outside input psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [0:299,-1:199], is invalid or outside input psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [0:300,0:199], is invalid or outside input psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [0:299,0:200], is invalid or outside input psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [0:-2147483349,0:199], is invalid or outside input psImage's boundaries, [0:299,0:199].
+<DATE><TIME>|<HOST>|E|psImageTrim (FILE:LINENO)
+    Specified subset range, [0:299,0:-2147483449], is invalid or outside input psImage's boundaries, [0:299,0:199].
+
+---> TESTPOINT PASSED (psImage{psImageTrim} | tst_psImageStructManip.c)
+
