1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 23:33:05 +04:00

Replace pow with std::pow

The C pow casts to double while std::pow has overloads that can be
optimized by the compiler.
Also replace pow(*, 1./3) by cbrt.
This commit is contained in:
Vincent Rabaud
2026-01-04 01:50:00 +01:00
parent 10589eb2c8
commit 5622958189
47 changed files with 131 additions and 140 deletions
+1 -1
View File
@@ -367,7 +367,7 @@ bool Core_EigenTest::check_full(int type)
for (int i = 0; i < ntests; ++i)
{
int src_size = (int)(std::pow(2.0, (rng.uniform(0, MAX_DEGREE) + 1.)));
int src_size = (int)(std::pow(2, (rng.uniform(0, MAX_DEGREE) + 1.)));
cv::Mat src(src_size, src_size, type);