Index: /trunk/psLib/src/image/psImageStats.c
===================================================================
--- /trunk/psLib/src/image/psImageStats.c	(revision 767)
+++ /trunk/psLib/src/image/psImageStats.c	(revision 767)
@@ -0,0 +1,31 @@
+/// This routine must determine the various statistics for the image.
+psStats *
+psImageGetStats(const psImage *input,
+                psStats *stats)
+{
+    if (input->type.typr == PS_TYPE_UINT8) {
+        return(psArrayStats(input->data.u8, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_UINT16) {
+        return(psArrayStats(input->data.u16, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_FLOAT) {
+        return(psArrayStats(input->data.F32, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_DOUBLE) {
+        return(psArrayStats(input->data.F64, NULL, 0xffffffff, stats));
+    }
+}
+
+
+psHistogram *
+psImageHistogram(psHistogram *hist,
+                 const psImage *input)
+{}
+
+psPolynomial2D *
+psImageFitPolynomial(const psImage *input,
+                     psPolynomial2D *coeffs);
+{}
+
+int
+psImageEvalPolynomial(const psImage *input,
+                      const psPolynomial2D *coeffs);
+{}
Index: /trunk/psLib/src/image/psImageStats.h
===================================================================
--- /trunk/psLib/src/image/psImageStats.h	(revision 767)
+++ /trunk/psLib/src/image/psImageStats.h	(revision 767)
@@ -0,0 +1,32 @@
+#if !defined(PS_IMAGE_STATS_H)
+#define PS_IMAGE_STATS_H
+#include "psVector.h"
+#include "psImage.h"
+#include "psStats.h"
+#include "psFunctions.h"
+
+/// This routine must determine the various statistics for the image.
+psStats *
+psImageGetStats(const psImage *input,   ///< image (or subimage) to calculate stats
+                psStats *stats          ///< defines statistics to be calculated & target
+               );
+
+/// Construct a histogram from an image (or subimage).
+psHistogram *
+psImageHistogram(psHistogram *hist,     ///< input histogram description & target
+                 const psImage *input   ///< determine histogram of this image
+                );
+
+/// Fit a 2-D polynomial surface to an image.
+psPolynomial2D *
+psImageFitPolynomial(const psImage *input, ///< image to fit
+                     psPolynomial2D *coeffs ///< coefficient structure carries in desired terms & target
+                    );
+
+/// Evaluate a 2-D polynomial surface to image pixels.
+int
+psImageEvalPolynomial(const psImage *input, ///< image to fit
+                      const psPolynomial2D *coeffs ///< coefficient structure carries in desired terms
+                     );
+
+#endif
Index: /trunk/psLib/src/imageops/psImageStats.c
===================================================================
--- /trunk/psLib/src/imageops/psImageStats.c	(revision 767)
+++ /trunk/psLib/src/imageops/psImageStats.c	(revision 767)
@@ -0,0 +1,31 @@
+/// This routine must determine the various statistics for the image.
+psStats *
+psImageGetStats(const psImage *input,
+                psStats *stats)
+{
+    if (input->type.typr == PS_TYPE_UINT8) {
+        return(psArrayStats(input->data.u8, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_UINT16) {
+        return(psArrayStats(input->data.u16, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_FLOAT) {
+        return(psArrayStats(input->data.F32, NULL, 0xffffffff, stats));
+    } else if (input->type.typr == PS_TYPE_DOUBLE) {
+        return(psArrayStats(input->data.F64, NULL, 0xffffffff, stats));
+    }
+}
+
+
+psHistogram *
+psImageHistogram(psHistogram *hist,
+                 const psImage *input)
+{}
+
+psPolynomial2D *
+psImageFitPolynomial(const psImage *input,
+                     psPolynomial2D *coeffs);
+{}
+
+int
+psImageEvalPolynomial(const psImage *input,
+                      const psPolynomial2D *coeffs);
+{}
Index: /trunk/psLib/src/imageops/psImageStats.h
===================================================================
--- /trunk/psLib/src/imageops/psImageStats.h	(revision 767)
+++ /trunk/psLib/src/imageops/psImageStats.h	(revision 767)
@@ -0,0 +1,32 @@
+#if !defined(PS_IMAGE_STATS_H)
+#define PS_IMAGE_STATS_H
+#include "psVector.h"
+#include "psImage.h"
+#include "psStats.h"
+#include "psFunctions.h"
+
+/// This routine must determine the various statistics for the image.
+psStats *
+psImageGetStats(const psImage *input,   ///< image (or subimage) to calculate stats
+                psStats *stats          ///< defines statistics to be calculated & target
+               );
+
+/// Construct a histogram from an image (or subimage).
+psHistogram *
+psImageHistogram(psHistogram *hist,     ///< input histogram description & target
+                 const psImage *input   ///< determine histogram of this image
+                );
+
+/// Fit a 2-D polynomial surface to an image.
+psPolynomial2D *
+psImageFitPolynomial(const psImage *input, ///< image to fit
+                     psPolynomial2D *coeffs ///< coefficient structure carries in desired terms & target
+                    );
+
+/// Evaluate a 2-D polynomial surface to image pixels.
+int
+psImageEvalPolynomial(const psImage *input, ///< image to fit
+                      const psPolynomial2D *coeffs ///< coefficient structure carries in desired terms
+                     );
+
+#endif
