mirror of
https://github.com/opencv/opencv.git
synced 2026-07-31 08:13:04 +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:
@@ -11,7 +11,7 @@ namespace ot {
|
||||
|
||||
RgbHistogram::RgbHistogram(int32_t rgb_bin_size)
|
||||
: rgb_bin_size_(rgb_bin_size), rgb_num_bins_(256 / rgb_bin_size),
|
||||
rgb_hist_size_(static_cast<int32_t>(pow(rgb_num_bins_, 3))) {
|
||||
rgb_hist_size_(static_cast<int32_t>(std::pow(rgb_num_bins_, 3))) {
|
||||
}
|
||||
|
||||
RgbHistogram::~RgbHistogram(void) {
|
||||
|
||||
Reference in New Issue
Block a user