From 75cf8c1b470ccf3b5150196bd9434d2c8d887b0f Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Fri, 16 Jul 2010 22:44:48 +0000 Subject: [PATCH] a few more warnings fixed --- modules/contrib/src/spinimages.cpp | 6 +++--- tests/cv/src/acameracalibration.cpp | 2 +- tests/cv/src/achesscorners.cpp | 2 +- tests/cv/src/tabruteforcematcher.cpp | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/contrib/src/spinimages.cpp b/modules/contrib/src/spinimages.cpp index 71d39c9f0a..7f0d7637c3 100644 --- a/modules/contrib/src/spinimages.cpp +++ b/modules/contrib/src/spinimages.cpp @@ -1053,7 +1053,7 @@ private: /* filtering by geometric consistency */ for(int i = 0; i < matchesSize; ++i) { - size_t consistNum = 1; + int consistNum = 1; float gc = float_max; for(int j = 0; j < matchesSize; ++j) @@ -1140,14 +1140,14 @@ private: } group_t allMatchesInds; - for(size_t i = 0; i < matchesSize; ++i) + for(int i = 0; i < matchesSize; ++i) allMatchesInds.insert(i); vector buf(matchesSize); float *buf_beg = &buf[0]; vector groups; - for(size_t g = 0; g < matchesSize; ++g) + for(int g = 0; g < matchesSize; ++g) { if (out) if (g % 100 == 0) *out << "G = " << g << endl; diff --git a/tests/cv/src/acameracalibration.cpp b/tests/cv/src/acameracalibration.cpp index 31752db635..f387e6638e 100644 --- a/tests/cv/src/acameracalibration.cpp +++ b/tests/cv/src/acameracalibration.cpp @@ -1405,7 +1405,7 @@ void CV_StereoCalibrationTest::run( int ) Size imgsize; int total = 0; - for( size_t i = 0; i < nframes; i++ ) + for( int i = 0; i < nframes; i++ ) { Mat left = imread(imglist[i*2]); Mat right = imread(imglist[i*2+1]); diff --git a/tests/cv/src/achesscorners.cpp b/tests/cv/src/achesscorners.cpp index 048a139c02..b77de699df 100644 --- a/tests/cv/src/achesscorners.cpp +++ b/tests/cv/src/achesscorners.cpp @@ -322,7 +322,7 @@ bool CV_ChessboardDetectorTest::checkByGenerator() const Size sizes[] = { Size(6, 6), Size(8, 6), Size(11, 12), Size(5, 4) }; const size_t sizes_num = sizeof(sizes)/sizeof(sizes[0]); - const size_t test_num = 16; + const int test_num = 16; int progress = 0; for(int i = 0; i < test_num; ++i) { diff --git a/tests/cv/src/tabruteforcematcher.cpp b/tests/cv/src/tabruteforcematcher.cpp index 5bb42a35bf..81895709e4 100644 --- a/tests/cv/src/tabruteforcematcher.cpp +++ b/tests/cv/src/tabruteforcematcher.cpp @@ -66,7 +66,7 @@ void BruteForceMatcherTest::run( int ) ts->printf( CvTS::LOG, "Matching without matrix multiplication time s: %f, us per pair: %f\n", genericMatcherTime*1e-6, genericMatcherTime/( descriptorsNumber*descriptorsNumber ) ); - if( specMatches.size() != descriptorsNumber || genericMatches.size() != descriptorsNumber ) + if( (int)specMatches.size() != descriptorsNumber || (int)genericMatches.size() != descriptorsNumber ) ts->set_failed_test_info( CvTS::FAIL_INVALID_OUTPUT ); for( int i=0;i