Changeset 5647 for trunk/psLib/test/math/tst_psSpline1D.c
- Timestamp:
- Nov 30, 2005, 3:20:38 PM (21 years ago)
- File:
-
- 1 edited
-
trunk/psLib/test/math/tst_psSpline1D.c (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/test/math/tst_psSpline1D.c
r5546 r5647 13 13 * @author GLG, MHPCC 14 14 * 15 * @version $Revision: 1. 4$ $Name: not supported by cvs2svn $16 * @date $Date: 2005-1 1-18 20:04:38 $15 * @version $Revision: 1.5 $ $Name: not supported by cvs2svn $ 16 * @date $Date: 2005-12-01 01:20:38 $ 17 17 * 18 18 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 28 28 // {testFunction, testpointNumber, description, expected rc, boolean-ignore this test} 29 29 testDescription tests[] = { 30 {psSplineAllocTest, 0000, "(TEST A) psSplineAllocTest",true, false},31 {psSplineEvalTest, 0000, "(TEST B) psSplineEvalTest",true, false},30 {psSplineAllocTest, 0000, "(TEST A) psSplineAllocTest", true, false}, 31 {psSplineEvalTest, 0000, "(TEST B) psSplineEvalTest", true, false}, 32 32 {psSplineEvalVectorTest, 0000, "(TEST C) psSplineEvalVectorTest", true, false}, 33 33 {NULL} … … 40 40 otherwise it returns TRUE. 41 41 ********************************************************************************/ 42 psBool CheckErrorF32(psF32 actual, 43 psF32 expect) 42 psBool CheckErrorF32( 43 psF32 actual, 44 psF32 expect) 44 45 { 45 46 if ((fabs(actual - expect) / fabs(expect)) > ERROR_TOLERANCE_PERCENT) { … … 50 51 } 51 52 52 psS32 main( psS32 argc, char* argv[] ) 53 psS32 main( 54 psS32 argc, 55 char* argv[]) 53 56 { 54 57 psLogSetFormat("HLNM"); 55 58 psLogSetLevel( PS_LOG_INFO ); 56 59 // 57 // Set the following trace le evls to track what is happening in the60 // Set the following trace levels to track what is happening in the 58 61 // various functions in psSpline.c 59 62 // … … 113 116 testStatus = false; 114 117 } 118 /* 119 XXX: Must allocate these members. 120 tmpSline->spline = (psPolynomial1D **) psAlloc(numSplines * sizeof(psPolynomial1D *)); 121 for (psS32 i=0;i<numSplines;i++) { 122 spline->spline[i] = psPolynomial1DAlloc(3, PS_POLYNOMIAL_ORD); 123 } 124 */ 115 125 116 126 psFree(tmpSpline); … … 197 207 } 198 208 199 200 209 tmpSpline = psVectorFitSpline1D(xF32, yF32); 201 210 if (tmpSpline == NULL) { 202 printf("TEST ERROR: Could not allocate psSpline1D data structure \n");211 printf("TEST ERROR: Could not allocate psSpline1D data structure (1)\n"); 203 212 testStatus = false; 204 213 } … … 712 721 psS32 testStatus = psSplineEvalTest_sub(10); 713 722 714 // HEY 715 testStatus |= psSplineEvalTest_sub00(0);716 testStatus |= psSplineEvalTest_sub00b(0);717 testStatus |= psSplineEvalTest_sub00c(0);723 // HEY: XXX: Test with empty psVectors. 724 // testStatus |= psSplineEvalTest_sub00(0); 725 // testStatus |= psSplineEvalTest_sub00b(0); 726 // testStatus |= psSplineEvalTest_sub00c(0); 718 727 719 728 testStatus |= psSplineEvalTest_sub00(1);
Note:
See TracChangeset
for help on using the changeset viewer.
