Index: /trunk/psLib/src/image/psImageStats.c
===================================================================
--- /trunk/psLib/src/image/psImageStats.c	(revision 1077)
+++ /trunk/psLib/src/image/psImageStats.c	(revision 1078)
@@ -451,2 +451,6 @@
     return(pixel);
 }
+
+
+
+
Index: /trunk/psLib/src/imageops/psImageStats.c
===================================================================
--- /trunk/psLib/src/imageops/psImageStats.c	(revision 1077)
+++ /trunk/psLib/src/imageops/psImageStats.c	(revision 1078)
@@ -451,2 +451,6 @@
     return(pixel);
 }
+
+
+
+
Index: /trunk/psLib/test/dataManip/Makefile
===================================================================
--- /trunk/psLib/test/dataManip/Makefile	(revision 1077)
+++ /trunk/psLib/test/dataManip/Makefile	(revision 1078)
@@ -3,6 +3,6 @@
 ##  Makefile:   test/sysUtils
 ##
-##  $Revision: 1.15 $  $Name: not supported by cvs2svn $
-##  $Date: 2004-06-15 02:45:43 $
+##  $Revision: 1.16 $  $Name: not supported by cvs2svn $
+##  $Date: 2004-06-24 01:40:38 $
 ##
 ##  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -44,4 +44,5 @@
  tst_psImageStats01 \
  tst_psImageStats02 \
+ tst_psImageStats03 \
  tst_psImageIO \
  tst_psVectorFFT \
Index: /trunk/psLib/test/image/tst_psImageStats02.c
===================================================================
--- /trunk/psLib/test/image/tst_psImageStats02.c	(revision 1077)
+++ /trunk/psLib/test/image/tst_psImageStats02.c	(revision 1078)
@@ -16,7 +16,7 @@
 #include <float.h>
 #include <math.h>
-#define IMAGE_SIZE 3
-#define CHEBY_X_DIM 3
-#define CHEBY_Y_DIM 3
+#define IMAGE_SIZE 64
+#define CHEBY_X_DIM 8
+#define CHEBY_Y_DIM 8
 #define THRESHOLD 1.0
 int main()
Index: /trunk/psLib/test/image/tst_psImageStats03.c
===================================================================
--- /trunk/psLib/test/image/tst_psImageStats03.c	(revision 1078)
+++ /trunk/psLib/test/image/tst_psImageStats03.c	(revision 1078)
@@ -0,0 +1,82 @@
+/*****************************************************************************
+    This routine must ensure that the psImagePixelInterpolation() routine
+    works correctly.
+ *****************************************************************************/
+#include <stdio.h>
+#include "pslib.h"
+#include "psTest.h"
+#include "psMemory.h"
+#include "psImage.h"
+#include "psImageStats.h"
+#include <float.h>
+#include <math.h>
+#define IMAGE_SIZE 10
+
+int main()
+{
+    psImage *tmpImage   = NULL;
+    int testStatus      = true;
+    int memLeaks        = 0;
+    int i               = 0;
+    int j               = 0;
+    float pixel         = 0.0;
+    float x             = 0.0;
+    float y             = 0.0;
+    int currentId       = psMemGetId();
+
+    /*************************************************************************/
+    /*  Allocate and initialize data structures                      */
+    /*************************************************************************/
+    printPositiveTestHeader(stdout,
+                            "psImageStats functions",
+                            "psImagePixelInterpolation()");
+
+    tmpImage = psImageAlloc(IMAGE_SIZE, IMAGE_SIZE, PS_TYPE_F32);
+    for (i=0;i<IMAGE_SIZE;i++) {
+        for (j=0;j<IMAGE_SIZE;j++) {
+            tmpImage->data.F32[i][j] = 4.0;
+            tmpImage->data.F32[i][j] = (float) (i + j) + (4.0 * (float) i);
+            tmpImage->data.F32[i][j] = (float) (i + j);
+            printf("%.1f ", tmpImage->data.F32[i][j]);
+        }
+        printf("\n");
+    }
+    for (i=0;i<IMAGE_SIZE-1;i++) {
+        for (j=0;j<IMAGE_SIZE-1;j++) {
+            x = 0.2 + (float) i;
+            y = 0.2 + (float) j;
+            pixel = psImagePixelInterpolation(tmpImage, x, y);
+            printf("%.1f ", pixel);
+        }
+        printf("\n");
+    }
+
+    for (i=0;i<IMAGE_SIZE-1;i++) {
+        for (j=0;j<IMAGE_SIZE-1;j++) {
+            x = 0.2 + (float) i;
+            y = 0.2 + (float) j;
+            pixel = psImagePixelInterpolation(tmpImage, x, y);
+            printf("image[%.1f][%.1f] is interpolated at %.1f\n", x, y, pixel);
+        }
+    }
+
+
+    psMemCheckCorruption(1);
+    printFooter(stdout,
+                "psImageStats functions",
+                "psImagePixelInterpolation()",
+                testStatus);
+
+    /*************************************************************************/
+    /*  Deallocate data structures                                   */
+    /*************************************************************************/
+    psImageFree(tmpImage);
+
+    psMemCheckCorruption(1);
+    memLeaks = psMemCheckLeaks(currentId,NULL,NULL);
+    if (0 != memLeaks) {
+        psAbort(__func__,"Memory Leaks! (%d leaks)", memLeaks);
+    }
+
+    return (!testStatus);
+}
