]> rtime.felk.cvut.cz Git - opencv.git/commitdiff
undistort map test bug fixed
authoralexeylatyshev <alexeylatyshev@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Mon, 15 Mar 2010 13:00:20 +0000 (13:00 +0000)
committeralexeylatyshev <alexeylatyshev@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Mon, 15 Mar 2010 13:00:20 +0000 (13:00 +0000)
git-svn-id: https://code.ros.org/svn/opencv/trunk@2817 73c94f0f-984f-4a5f-82bc-2d8db8d8ee08

opencv/tests/cv/src/aimgwarp.cpp

index 7f2c26a3ec049c69ac927d1221db5df5ededdb70..5ccb9b108596f9ff27dac9041f40d92f1e3a90b1 100644 (file)
@@ -1546,6 +1546,7 @@ void CV_UndistortMapTest::run_func()
        else
                cvInitUndistortMap( &test_mat[INPUT][0], &test_mat[INPUT][1],
                         test_array[OUTPUT][0], 0 );
+
 }
 
 
@@ -1597,11 +1598,17 @@ int CV_UndistortMapTest::prepare_test_case( int test_case_idx )
     cvTsConvert( &_a, _a0 );
        cvTsConvert( &_k, _k0 );
 
+       if (dualChannel)
+       {
+               cvZero(&test_mat[REF_OUTPUT][1]);
+               cvZero(&test_mat[OUTPUT][1]);
+       }
+
     return code;
 }
 
 
-void CV_UndistortMapTest::prepare_to_validation( int /*test_case_idx*/ )
+void CV_UndistortMapTest::prepare_to_validation( int test_case_idx )
 {
        if (!dualChannel )
                cvTsInitUndistortMap( &test_mat[INPUT][0], &test_mat[INPUT][1],