Index: trunk/psLib/test/image/tst_psImageFFT.c
===================================================================
--- trunk/psLib/test/image/tst_psImageFFT.c	(revision 2204)
+++ trunk/psLib/test/image/tst_psImageFFT.c	(revision 2273)
@@ -6,6 +6,6 @@
  *  @author Robert DeSonia, MHPCC
  *
- *  @version $Revision: 1.12 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-10-27 00:57:33 $
+ *  @version $Revision: 1.13 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-11-04 01:05:00 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -85,9 +85,9 @@
     img2 = psImageFFT(img2,img,PS_FFT_FORWARD);
     if (img2->type.type != PS_TYPE_C32) {
-        psError(__func__,"FFT didn't produce complex values?");
+        psError(PS_ERR_UNKNOWN, true,"FFT didn't produce complex values?");
         return 1;
     }
     if (img2->numCols != m || img2->numRows != n) {
-        psError(__func__,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
+        psError(PS_ERR_UNKNOWN, true,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
                 img2->numCols,img2->numRows,m,n);
         return 2;
@@ -103,5 +103,5 @@
                 if (! (col == 0 && (row == 1 || row == n-1))
                         && ! (row == 0 && (col==1 || col == n-1)) ) {
-                    psError(__func__,"Result invalid at %d,%d (%.2f)",col,row,mag);
+                    psError(PS_ERR_UNKNOWN, true,"Result invalid at %d,%d (%.2f)",col,row,mag);
                     return 3;
                 }
@@ -109,5 +109,5 @@
                 if ( (col == 0 && (row == 1 || row == n-1))
                         || (row == 0 && (col==1 || col == n-1)) ) {
-                    psError(__func__,"Result invalid at %d,%d (%.2f)",col,row,mag);
+                    psError(PS_ERR_UNKNOWN, true,"Result invalid at %d,%d (%.2f)",col,row,mag);
                     return 4;
                 }
@@ -120,10 +120,10 @@
 
     if (img3->type.type != PS_TYPE_C32) {
-        psError(__func__,"FFT didn't produce complex values?");
+        psError(PS_ERR_UNKNOWN, true,"FFT didn't produce complex values?");
         return 5;
     }
 
     if (img3->numCols != m || img3->numRows != n) {
-        psError(__func__,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
+        psError(PS_ERR_UNKNOWN, true,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
                 img3->numCols,img3->numRows,m,n);
         return 6;
@@ -136,5 +136,5 @@
             psF32 pixel = creal(img3Row[col])/m/n;
             if (fabsf(pixel-imgRow[col]) > 0.1) {
-                psError(__func__,"Reverse FFT didn't give original image back (%d,%d %.2f vs %.2f)",
+                psError(PS_ERR_UNKNOWN, true,"Reverse FFT didn't give original image back (%d,%d %.2f vs %.2f)",
                         col,row,pixel,imgRow[col]);
                 return 7;
@@ -149,10 +149,10 @@
         char* typeStr;
         PS_TYPE_NAME(typeStr,img3->type.type)
-        psError(__func__,"FFT asked to make real result, but I got a %s type image?",typeStr);
+        psError(PS_ERR_UNKNOWN, true,"FFT asked to make real result, but I got a %s type image?",typeStr);
         return 8;
     }
 
     if (img3->numCols != m || img3->numRows != n) {
-        psError(__func__,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
+        psError(PS_ERR_UNKNOWN, true,"FFT didn't produce proper size result (%dx%d vs. expected %dx%d).",
                 img3->numCols,img3->numRows,m,n);
         return 9;
@@ -165,5 +165,5 @@
             psF32 pixel = img3Row[col]/m/n;
             if (fabsf(pixel-imgRow[col]) > 0.1) {
-                psError(__func__,"Reverse FFT didn't give original image back (%d,%d %.2f vs %.2f)",
+                psError(PS_ERR_UNKNOWN, true,"Reverse FFT didn't give original image back (%d,%d %.2f vs %.2f)",
                         col,row,pixel,imgRow[col]);
                 return 10;
@@ -175,5 +175,5 @@
     psLogMsg(__func__,PS_LOG_INFO,"Following should be an error.");
     if (psImageFFT(NULL,img2,PS_FFT_REVERSE|PS_FFT_FORWARD) != NULL) {
-        psError(__func__,"PS_FFT_REVERSE|PS_FFT_FORWARD option produced something?");
+        psError(PS_ERR_UNKNOWN, true,"PS_FFT_REVERSE|PS_FFT_FORWARD option produced something?");
         return 11;
     }
@@ -181,5 +181,5 @@
     psLogMsg(__func__,PS_LOG_INFO,"Following should be an error.");
     if (psImageFFT(NULL,img2,PS_FFT_FORWARD|PS_FFT_REAL_RESULT) != NULL) {
-        psError(__func__,"PS_FFT_FORWARD|PS_FFT_REAL_RESULT option produced something?");
+        psError(PS_ERR_UNKNOWN, true,"PS_FFT_FORWARD|PS_FFT_REAL_RESULT option produced something?");
         return 12;
     }
@@ -188,5 +188,5 @@
     img4 = psImageFFT(NULL,NULL,PS_FFT_FORWARD);
     if (img4 != NULL ) {
-        psError(__func__,"psImageFFT should return null for a null input image.");
+        psError(PS_ERR_UNKNOWN, true,"psImageFFT should return null for a null input image.");
         return 10;
     }
@@ -197,5 +197,5 @@
     img5 = psImageFFT(NULL,img4,PS_FFT_REAL_RESULT);
     if (img5 != NULL) {
-        psError(__func__,"psImageFFT should return null for an invalid FFT direction.");
+        psError(PS_ERR_UNKNOWN, true,"psImageFFT should return null for an invalid FFT direction.");
         return 11;
     }
@@ -229,9 +229,9 @@
     img2 = psImageReal(img2,img);
     if (img2 == NULL) {
-        psError(__func__,"psImageReal returned a NULL?");
+        psError(PS_ERR_UNKNOWN, true,"psImageReal returned a NULL?");
         return 1;
     }
     if (img2->type.type != PS_TYPE_F32) {
-        psError(__func__,"psImageReal returned a wrong type (%d)?",
+        psError(PS_ERR_UNKNOWN, true,"psImageReal returned a wrong type (%d)?",
                 img2->type.type);
         return 2;
@@ -240,9 +240,9 @@
     img3 = psImageImaginary(img3,img);
     if (img3 == NULL) {
-        psError(__func__,"psImageImaginary returned a NULL?");
+        psError(PS_ERR_UNKNOWN, true,"psImageImaginary returned a NULL?");
         return 3;
     }
     if (img3->type.type != PS_TYPE_F32) {
-        psError(__func__,"psImageImaginary returned a wrong type (%d)?",
+        psError(PS_ERR_UNKNOWN, true,"psImageImaginary returned a wrong type (%d)?",
                 img3->type.type);
         return 4;
@@ -255,10 +255,10 @@
         for (psU32 col=0;col<m;col++) {
             if (fabsf(img2Row[col] - row) > FLT_EPSILON) {
-                psError(__func__,"psImageReal didn't return the real portion at n=%d",
+                psError(PS_ERR_UNKNOWN, true,"psImageReal didn't return the real portion at n=%d",
                         n);
                 return 5;
             }
             if (fabsf(img3Row[col] - col) > FLT_EPSILON) {
-                psError(__func__,"psImageImaginary didn't return the imag portion at n=%d",
+                psError(PS_ERR_UNKNOWN, true,"psImageImaginary didn't return the imag portion at n=%d",
                         n);
                 return 6;
@@ -307,5 +307,5 @@
     // 3. verify that the result is a psC32
     if (img3->type.type != PS_TYPE_C32) {
-        psError(__func__,"Image Type from psImageComplex is not complex? (%d)",
+        psError(PS_ERR_UNKNOWN, true,"Image Type from psImageComplex is not complex? (%d)",
                 img3->type.type);
         return 1;
@@ -319,5 +319,5 @@
             if (fabsf(crealf(img3Row[col]) - row) > FLT_EPSILON ||
                     fabsf(cimagf(img3Row[col]) - col) > FLT_EPSILON) {
-                psError(__func__,"psImageComplex result is invalid (%d,%d, %.2f+%.2fi)",
+                psError(PS_ERR_UNKNOWN, true,"psImageComplex result is invalid (%d,%d, %.2f+%.2fi)",
                         col,row,crealf(img3Row[col]),cimagf(img3Row[col]));
                 return 2;
@@ -334,5 +334,5 @@
     // 8. verify that an appropriate error occurred. (this partially has to be done via inspection)
     if (img3 != NULL) {
-        psError(__func__,"psImageComplex returned a image though input types mismatched.");
+        psError(PS_ERR_UNKNOWN, true,"psImageComplex returned a image though input types mismatched.");
         return 3;
     }
@@ -347,5 +347,5 @@
     // 11. verify thet an appropriate error occurred.
     if (img3 != NULL) {
-        psError(__func__,"psImageComplex returned a image though input sizes mismatched.");
+        psError(PS_ERR_UNKNOWN, true,"psImageComplex returned a image though input sizes mismatched.");
         return 4;
     }
@@ -380,5 +380,5 @@
     // 3. verify result is psC32
     if (img2->type.type != PS_TYPE_C32) {
-        psError(__func__,"the psImageConjugate didn't return a C32 image.");
+        psError(PS_ERR_UNKNOWN, true,"the psImageConjugate didn't return a C32 image.");
         return 1;
     }
@@ -390,5 +390,5 @@
             if (fabsf(crealf(img2Row[col]) - row) > FLT_EPSILON ||
                     fabsf(cimagf(img2Row[col]) + col) > FLT_EPSILON) {
-                psError(__func__,"psImageComplex result is invalid (%d,%d, %.2f+%.2fi)",
+                psError(PS_ERR_UNKNOWN, true,"psImageComplex result is invalid (%d,%d, %.2f+%.2fi)",
                         col,row,crealf(img2Row[col]),cimagf(img2Row[col]));
                 return 2;
@@ -425,5 +425,5 @@
     // 3. verify result is psF32
     if (img2->type.type != PS_TYPE_F32) {
-        psError(__func__,"the type was not PS_TYPE_F32.");
+        psError(PS_ERR_UNKNOWN, true,"the type was not PS_TYPE_F32.");
         return 1;
     }
@@ -438,5 +438,5 @@
 
             if (fabsf(img2Row[col] - power) > 2.0f*FLT_EPSILON) {
-                psError(__func__,"psImagePowerSpectrum result is invalid (%d,%d, %.2f vs %.2f)",
+                psError(PS_ERR_UNKNOWN, true,"psImagePowerSpectrum result is invalid (%d,%d, %.2f vs %.2f)",
                         col,row,img2Row[col],power);
                 return 2;
