gcc6: fix misleading indentation warning
cosmetic changes to fix this warning. real bugs not found
This commit is contained in:
parent
9ebbfc7bdb
commit
9b8013d193
@ -1043,7 +1043,7 @@ icvRemoveQuadFromGroup(CvCBQuad **quads, int count, CvCBQuad *q0)
|
|||||||
q0->count--;
|
q0->count--;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1349,27 +1349,27 @@ bool CV_StereoCalibrationTest::checkPandROI( int test_case_idx, const Mat& M, co
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// step 2. check that all the points inside ROI belong to the original source image
|
// step 2. check that all the points inside ROI belong to the original source image
|
||||||
Mat temp(imgsize, CV_8U), utemp, map1, map2;
|
Mat temp(imgsize, CV_8U), utemp, map1, map2;
|
||||||
temp = Scalar::all(1);
|
temp = Scalar::all(1);
|
||||||
initUndistortRectifyMap(M, D, R, P, imgsize, CV_16SC2, map1, map2);
|
initUndistortRectifyMap(M, D, R, P, imgsize, CV_16SC2, map1, map2);
|
||||||
remap(temp, utemp, map1, map2, INTER_LINEAR);
|
remap(temp, utemp, map1, map2, INTER_LINEAR);
|
||||||
|
|
||||||
if(roi.x < 0 || roi.y < 0 || roi.x + roi.width > imgsize.width || roi.y + roi.height > imgsize.height)
|
if(roi.x < 0 || roi.y < 0 || roi.x + roi.width > imgsize.width || roi.y + roi.height > imgsize.height)
|
||||||
{
|
{
|
||||||
ts->printf(cvtest::TS::LOG, "Test #%d. The ROI=(%d, %d, %d, %d) is outside of the imge rectangle\n",
|
ts->printf(cvtest::TS::LOG, "Test #%d. The ROI=(%d, %d, %d, %d) is outside of the imge rectangle\n",
|
||||||
test_case_idx, roi.x, roi.y, roi.width, roi.height);
|
test_case_idx, roi.x, roi.y, roi.width, roi.height);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
double s = sum(utemp(roi))[0];
|
double s = sum(utemp(roi))[0];
|
||||||
if( s > roi.area() || roi.area() - s > roi.area()*(1-eps) )
|
if( s > roi.area() || roi.area() - s > roi.area()*(1-eps) )
|
||||||
{
|
{
|
||||||
ts->printf(cvtest::TS::LOG, "Test #%d. The ratio of black pixels inside the valid ROI (~%g%%) is too large\n",
|
ts->printf(cvtest::TS::LOG, "Test #%d. The ratio of black pixels inside the valid ROI (~%g%%) is too large\n",
|
||||||
test_case_idx, s*100./roi.area());
|
test_case_idx, s*100./roi.area());
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CV_StereoCalibrationTest::run( int )
|
void CV_StereoCalibrationTest::run( int )
|
||||||
|
@ -8097,19 +8097,19 @@ void AGAST(InputArray _img, std::vector<KeyPoint>& keypoints, int threshold, boo
|
|||||||
&& (kpts[lastRowCorner_ind].pt.y == lastRow) )
|
&& (kpts[lastRowCorner_ind].pt.y == lastRow) )
|
||||||
lastRowCorner_ind++;
|
lastRowCorner_ind++;
|
||||||
|
|
||||||
if( (kpts[lastRowCorner_ind].pt.x == currCorner->pt.x)
|
if( (kpts[lastRowCorner_ind].pt.x == currCorner->pt.x)
|
||||||
&& (lastRowCorner_ind != curr_idx) )
|
&& (lastRowCorner_ind != curr_idx) )
|
||||||
{
|
{
|
||||||
size_t w = lastRowCorner_ind;
|
size_t w = lastRowCorner_ind;
|
||||||
// find the maximum in this block
|
// find the maximum in this block
|
||||||
while(nmsFlags[w] != -1)
|
while(nmsFlags[w] != -1)
|
||||||
w = nmsFlags[w];
|
w = nmsFlags[w];
|
||||||
|
|
||||||
if(kpts[curr_idx].response < kpts[w].response)
|
if(kpts[curr_idx].response < kpts[w].response)
|
||||||
nmsFlags[curr_idx] = (int)w;
|
nmsFlags[curr_idx] = (int)w;
|
||||||
else
|
else
|
||||||
nmsFlags[w] = (int)curr_idx;
|
nmsFlags[w] = (int)curr_idx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// check left
|
// check left
|
||||||
|
@ -79,7 +79,8 @@ struct big_any_policy : typed_base_any_policy<T>
|
|||||||
{
|
{
|
||||||
virtual void static_delete(void** x)
|
virtual void static_delete(void** x)
|
||||||
{
|
{
|
||||||
if (* x) delete (* reinterpret_cast<T**>(x)); *x = NULL;
|
if (* x) delete (* reinterpret_cast<T**>(x));
|
||||||
|
*x = NULL;
|
||||||
}
|
}
|
||||||
virtual void copy_from_value(void const* src, void** dest)
|
virtual void copy_from_value(void const* src, void** dest)
|
||||||
{
|
{
|
||||||
|
@ -1772,7 +1772,8 @@ cmpUlpsFlt_(const int* src1, const int* src2, size_t total, int imaxdiff, size_t
|
|||||||
for( i = 0; i < total; i++ )
|
for( i = 0; i < total; i++ )
|
||||||
{
|
{
|
||||||
int a = src1[i], b = src2[i];
|
int a = src1[i], b = src2[i];
|
||||||
if( a < 0 ) a ^= C; if( b < 0 ) b ^= C;
|
if( a < 0 ) a ^= C;
|
||||||
|
if( b < 0 ) b ^= C;
|
||||||
int diff = std::abs(a - b);
|
int diff = std::abs(a - b);
|
||||||
if( realmaxdiff < diff )
|
if( realmaxdiff < diff )
|
||||||
{
|
{
|
||||||
@ -1794,7 +1795,8 @@ cmpUlpsFlt_(const int64* src1, const int64* src2, size_t total, int imaxdiff, si
|
|||||||
for( i = 0; i < total; i++ )
|
for( i = 0; i < total; i++ )
|
||||||
{
|
{
|
||||||
int64 a = src1[i], b = src2[i];
|
int64 a = src1[i], b = src2[i];
|
||||||
if( a < 0 ) a ^= C; if( b < 0 ) b ^= C;
|
if( a < 0 ) a ^= C;
|
||||||
|
if( b < 0 ) b ^= C;
|
||||||
double diff = fabs((double)a - (double)b);
|
double diff = fabs((double)a - (double)b);
|
||||||
if( realmaxdiff < diff )
|
if( realmaxdiff < diff )
|
||||||
{
|
{
|
||||||
|
@ -82,7 +82,7 @@ bool CV_ECC_BaseTest::isMapCorrect(const Mat& map)
|
|||||||
tr = tr & (!cvIsNaN(mapVal) && (fabs(mapVal) < 1e9));
|
tr = tr & (!cvIsNaN(mapVal) && (fabs(mapVal) < 1e9));
|
||||||
}
|
}
|
||||||
|
|
||||||
return tr;
|
return tr;
|
||||||
}
|
}
|
||||||
|
|
||||||
double CV_ECC_BaseTest::computeRMS(const Mat& mat1, const Mat& mat2){
|
double CV_ECC_BaseTest::computeRMS(const Mat& mat1, const Mat& mat2){
|
||||||
|
@ -371,8 +371,8 @@ static void icvInitCapture_V4L() {
|
|||||||
}
|
}
|
||||||
if (deviceHandle != -1)
|
if (deviceHandle != -1)
|
||||||
close(deviceHandle);
|
close(deviceHandle);
|
||||||
/* Set up to test the next /dev/video source in line */
|
/* Set up to test the next /dev/video source in line */
|
||||||
CameraNumber++;
|
CameraNumber++;
|
||||||
} /* End while */
|
} /* End while */
|
||||||
|
|
||||||
}; /* End icvInitCapture_V4L */
|
}; /* End icvInitCapture_V4L */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user