Skip to content

Commit e5229a1

Browse files
committed
Merge pull request #556 from polarfuchs99:master
2 parents 5c67347 + c2b5589 commit e5229a1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

modules/line_descriptor/perf/perf_matching.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ uchar invertSingleBits( uchar dividend_char, int numBits )
101101
/* reconvert to decimal */
102102
uchar result = 0;
103103
for ( int i = (int) bin_vector.size() - 1; i >= 0; i-- )
104-
result += (uchar) ( bin_vector[i] * pow( 2, i ) );
104+
result += (uchar) ( bin_vector[i] * ( 1 << i ) );
105105

106106
return result;
107107
}

modules/line_descriptor/test/test_matcher_regression.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ uchar CV_BinaryDescriptorMatcherTest::invertSingleBits( uchar dividend_char, int
123123
/* reconvert to decimal */
124124
uchar result = 0;
125125
for ( int i = (int) bin_vector.size() - 1; i >= 0; i-- )
126-
result += (uchar) ( bin_vector[i] * pow( 2, i ) );
126+
result += (uchar) ( bin_vector[i] * ( 1 << i ) );
127127

128128
return result;
129129
}

0 commit comments

Comments
 (0)