@@ -74,12 +74,12 @@ void AKAZEFeatures::Allocate_Memory_Evolution(void) {
74
74
Evolution step;
75
75
step.size = Size (level_width, level_height);
76
76
step.esigma = options_.soffset *pow (2 .f , (float )(j) / (float )(options_.nsublevels ) + i);
77
- step.sigma_size = fRound (step.esigma * options_.derivative_factor / power); // In fact sigma_size only depends on j
77
+ step.sigma_size = cvRound (step.esigma * options_.derivative_factor / power); // In fact sigma_size only depends on j
78
78
step.etime = 0 .5f * (step.esigma * step.esigma );
79
79
step.octave = i;
80
80
step.sublevel = j;
81
81
step.octave_ratio = (float )power;
82
- step.border = fRound (smax * step.sigma_size ) + 1 ;
82
+ step.border = cvRound (smax * step.sigma_size ) + 1 ;
83
83
84
84
evolution_.push_back (step);
85
85
}
@@ -1301,9 +1301,9 @@ void Compute_Main_Orientation(KeyPoint& kpt, const std::vector<Evolution>& evolu
1301
1301
// get the right evolution level for this keypoint
1302
1302
const Evolution& e = evolution[kpt.class_id ];
1303
1303
// Get the information from the keypoint
1304
- int scale = fRound (0 .5f * kpt.size / e.octave_ratio );
1305
- int x0 = fRound (kpt.pt .x / e.octave_ratio );
1306
- int y0 = fRound (kpt.pt .y / e.octave_ratio );
1304
+ int scale = cvRound (0 .5f * kpt.size / e.octave_ratio );
1305
+ int x0 = cvRound (kpt.pt .x / e.octave_ratio );
1306
+ int y0 = cvRound (kpt.pt .y / e.octave_ratio );
1307
1307
1308
1308
// Sample derivatives responses for the points within radius of 6*scale
1309
1309
const int ang_size = 109 ;
@@ -1443,7 +1443,7 @@ void MSURF_Upright_Descriptor_64_Invoker::Get_MSURF_Upright_Descriptor_64(const
1443
1443
1444
1444
// Get the information from the keypoint
1445
1445
ratio = (float )(1 << kpt.octave );
1446
- scale = fRound (0 .5f *kpt.size / ratio);
1446
+ scale = cvRound (0 .5f *kpt.size / ratio);
1447
1447
const int level = kpt.class_id ;
1448
1448
Mat Lx = evolution[level].Mx ;
1449
1449
Mat Ly = evolution[level].My ;
@@ -1572,8 +1572,8 @@ void MSURF_Descriptor_64_Invoker::Get_MSURF_Descriptor_64(const KeyPoint& kpt, f
1572
1572
1573
1573
// Get the information from the keypoint
1574
1574
ratio = (float )(1 << kpt.octave );
1575
- scale = fRound (0 .5f *kpt.size / ratio);
1576
- angle = ( kpt.angle * static_cast <float >(CV_PI)) / 180 .f ;
1575
+ scale = cvRound (0 .5f *kpt.size / ratio);
1576
+ angle = kpt.angle * static_cast <float >(CV_PI / 180 .f ) ;
1577
1577
const int level = kpt.class_id ;
1578
1578
Mat Lx = evolution[level].Mx ;
1579
1579
Mat Ly = evolution[level].My ;
@@ -1613,11 +1613,11 @@ void MSURF_Descriptor_64_Invoker::Get_MSURF_Descriptor_64(const KeyPoint& kpt, f
1613
1613
// Get the gaussian weighted x and y responses
1614
1614
gauss_s1 = gaussian (xs - sample_x, ys - sample_y, 2 .5f *scale);
1615
1615
1616
- y1 = fRound (sample_y - 0 .5f );
1617
- x1 = fRound (sample_x - 0 .5f );
1616
+ y1 = cvRound (sample_y - 0 .5f );
1617
+ x1 = cvRound (sample_x - 0 .5f );
1618
1618
1619
- y2 = fRound (sample_y + 0 .5f );
1620
- x2 = fRound (sample_x + 0 .5f );
1619
+ y2 = cvRound (sample_y + 0 .5f );
1620
+ x2 = cvRound (sample_x + 0 .5f );
1621
1621
1622
1622
// fix crash: indexing with out-of-bounds index, this might happen near the edges of image
1623
1623
// clip values so they fit into the image
@@ -1706,7 +1706,7 @@ void Upright_MLDB_Full_Descriptor_Invoker::Get_Upright_MLDB_Full_Descriptor(cons
1706
1706
1707
1707
// Get the information from the keypoint
1708
1708
ratio = (float )(1 << kpt.octave );
1709
- scale = fRound (0 .5f *kpt.size / ratio);
1709
+ scale = cvRound (0 .5f *kpt.size / ratio);
1710
1710
const int level = kpt.class_id ;
1711
1711
Mat Lx = evolution[level].Mx ;
1712
1712
Mat Ly = evolution[level].My ;
@@ -1741,8 +1741,8 @@ void Upright_MLDB_Full_Descriptor_Invoker::Get_Upright_MLDB_Full_Descriptor(cons
1741
1741
sample_y = yf + l*scale;
1742
1742
sample_x = xf + k*scale;
1743
1743
1744
- y1 = fRound (sample_y);
1745
- x1 = fRound (sample_x);
1744
+ y1 = cvRound (sample_y);
1745
+ x1 = cvRound (sample_x);
1746
1746
1747
1747
ri = *(Lt.ptr <float >(y1)+x1);
1748
1748
rx = *(Lx.ptr <float >(y1)+x1);
@@ -1810,8 +1810,8 @@ void MLDB_Full_Descriptor_Invoker::MLDB_Fill_Values(float* values, int sample_st
1810
1810
float sample_y = yf + (l*co * scale + k*si*scale);
1811
1811
float sample_x = xf + (-l*si * scale + k*co*scale);
1812
1812
1813
- int y1 = fRound (sample_y);
1814
- int x1 = fRound (sample_x);
1813
+ int y1 = cvRound (sample_y);
1814
+ int x1 = cvRound (sample_x);
1815
1815
1816
1816
// fix crash: indexing with out-of-bounds index, this might happen near the edges of image
1817
1817
// clip values so they fit into the image
@@ -1900,10 +1900,10 @@ void MLDB_Full_Descriptor_Invoker::Get_MLDB_Full_Descriptor(const KeyPoint& kpt,
1900
1900
};
1901
1901
1902
1902
float ratio = (float )(1 << kpt.octave );
1903
- float scale = (float )fRound (0 .5f *kpt.size / ratio);
1903
+ float scale = (float )cvRound (0 .5f *kpt.size / ratio);
1904
1904
float xf = kpt.pt .x / ratio;
1905
1905
float yf = kpt.pt .y / ratio;
1906
- float angle = ( kpt.angle * static_cast <float >(CV_PI)) / 180 .f ;
1906
+ float angle = kpt.angle * static_cast <float >(CV_PI / 180 .f ) ;
1907
1907
float co = cos (angle);
1908
1908
float si = sin (angle);
1909
1909
@@ -1941,8 +1941,8 @@ void MLDB_Descriptor_Subset_Invoker::Get_MLDB_Descriptor_Subset(const KeyPoint&
1941
1941
1942
1942
// Get the information from the keypoint
1943
1943
float ratio = (float )(1 << kpt.octave );
1944
- int scale = fRound (0 .5f *kpt.size / ratio);
1945
- float angle = ( kpt.angle * static_cast <float >(CV_PI)) / 180 .f ;
1944
+ int scale = cvRound (0 .5f *kpt.size / ratio);
1945
+ float angle = kpt.angle * static_cast <float >(CV_PI / 180 .f ) ;
1946
1946
const int level = kpt.class_id ;
1947
1947
Mat Lx = evolution[level].Mx ;
1948
1948
Mat Ly = evolution[level].My ;
@@ -1983,8 +1983,8 @@ void MLDB_Descriptor_Subset_Invoker::Get_MLDB_Descriptor_Subset(const KeyPoint&
1983
1983
sample_y = yf + (l*scale*co + k*scale*si);
1984
1984
sample_x = xf + (-l*scale*si + k*scale*co);
1985
1985
1986
- y1 = fRound (sample_y);
1987
- x1 = fRound (sample_x);
1986
+ y1 = cvRound (sample_y);
1987
+ x1 = cvRound (sample_x);
1988
1988
1989
1989
di += *(Lt.ptr <float >(y1)+x1);
1990
1990
@@ -2049,7 +2049,7 @@ void Upright_MLDB_Descriptor_Subset_Invoker::Get_Upright_MLDB_Descriptor_Subset(
2049
2049
2050
2050
// Get the information from the keypoint
2051
2051
float ratio = (float )(1 << kpt.octave );
2052
- int scale = fRound (0 .5f *kpt.size / ratio);
2052
+ int scale = cvRound (0 .5f *kpt.size / ratio);
2053
2053
const int level = kpt.class_id ;
2054
2054
Mat Lx = evolution[level].Mx ;
2055
2055
Mat Ly = evolution[level].My ;
@@ -2081,8 +2081,8 @@ void Upright_MLDB_Descriptor_Subset_Invoker::Get_Upright_MLDB_Descriptor_Subset(
2081
2081
sample_y = yf + l*scale;
2082
2082
sample_x = xf + k*scale;
2083
2083
2084
- y1 = fRound (sample_y);
2085
- x1 = fRound (sample_x);
2084
+ y1 = cvRound (sample_y);
2085
+ x1 = cvRound (sample_x);
2086
2086
di += *(Lt.ptr <float >(y1)+x1);
2087
2087
2088
2088
if (options.descriptor_channels > 1 ) {
0 commit comments