1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-31 00:03:03 +04:00

Merge pull request #23109 from seanm:misc-warnings

* Fixed clang -Wnewline-eof warnings
* Fixed all trivial clang -Wextra-semi and -Wc++98-compat-extra-semi warnings
* Removed trailing semi from various macros
* Fixed various -Wunused-macros warnings
* Fixed some trivial -Wdocumentation warnings
* Fixed some -Wdocumentation-deprecated-sync warnings
* Fixed incorrect indentation
* Suppressed some clang warnings in 3rd party code
* Fixed QRCodeEncoder::Params documentation.

---------

Co-authored-by: Alexander Smorkalov <alexander.smorkalov@xperience.ai>
This commit is contained in:
Sean McBride
2023-10-06 06:33:21 -04:00
committed by GitHub
parent 24fd39538e
commit 5fb3869775
135 changed files with 620 additions and 534 deletions
@@ -36,15 +36,15 @@
namespace cv {
template <typename T>
DualQuat<T>::DualQuat():w(0), x(0), y(0), z(0), w_(0), x_(0), y_(0), z_(0){};
DualQuat<T>::DualQuat():w(0), x(0), y(0), z(0), w_(0), x_(0), y_(0), z_(0){}
template <typename T>
DualQuat<T>::DualQuat(const T vw, const T vx, const T vy, const T vz, const T _w, const T _x, const T _y, const T _z):
w(vw), x(vx), y(vy), z(vz), w_(_w), x_(_x), y_(_y), z_(_z){};
w(vw), x(vx), y(vy), z(vz), w_(_w), x_(_x), y_(_y), z_(_z){}
template <typename T>
DualQuat<T>::DualQuat(const Vec<T, 8> &q):w(q[0]), x(q[1]), y(q[2]), z(q[3]),
w_(q[4]), x_(q[5]), y_(q[6]), z_(q[7]){};
w_(q[4]), x_(q[5]), y_(q[6]), z_(q[7]){}
template <typename T>
DualQuat<T> DualQuat<T>::createFromQuat(const Quat<T> &realPart, const Quat<T> &dualPart)
@@ -188,4 +188,4 @@ CV_CPU_OPTIMIZATION_HAL_NAMESPACE_END
//! @endcond
} // cv::
} // cv::
+1 -1
View File
@@ -215,7 +215,7 @@ public:
template<int l> Matx(const Matx<_Tp, m, l>& a, const Matx<_Tp, l, n>& b, Matx_MatMulOp);
Matx(const Matx<_Tp, n, m>& a, Matx_TOp);
_Tp val[m*n]; //< matrix elements
_Tp val[m*n]; ///< matrix elements
};
typedef Matx<float, 1, 2> Matx12f;
+1 -1
View File
@@ -779,7 +779,7 @@ public:
void start();
void stop();
uint64 durationNS() const; //< duration in nanoseconds
uint64 durationNS() const; ///< duration in nanoseconds
protected:
struct Impl;
+3 -3
View File
@@ -89,7 +89,7 @@ public:
//! conjugation
Complex conj() const;
_Tp re, im; //< the real and the imaginary parts
_Tp re, im; ///< the real and the imaginary parts
};
typedef Complex<float> Complexf;
@@ -2031,8 +2031,8 @@ double jaccardDistance(const Rect_<_Tp>& a, const Rect_<_Tp>& b) {
/** @brief Finds out if there is any intersection between two rectangles
*
* mainly useful for language bindings
* @param rect1 First rectangle
* @param rect2 Second rectangle
* @param a First rectangle
* @param b Second rectangle
* @return the area of the intersection
*/
CV_EXPORTS_W inline double rectangleIntersectionArea(const Rect2d& a, const Rect2d& b) { return (a & b).area(); }
@@ -47,11 +47,11 @@ public:
explicit FileLock(const char* fname);
~FileLock();
void lock(); //< acquire exclusive (writer) lock
void unlock(); //< release exclusive (writer) lock
void lock(); ///< acquire exclusive (writer) lock
void unlock(); ///< release exclusive (writer) lock
void lock_shared(); //< acquire shareable (reader) lock
void unlock_shared(); //< release shareable (reader) lock
void lock_shared(); ///< acquire shareable (reader) lock
void unlock_shared(); ///< release shareable (reader) lock
struct Impl;
protected:
@@ -70,11 +70,11 @@ public:
struct LocationExtraData;
struct LocationStaticStorage
{
LocationExtraData** ppExtra; //< implementation specific data
const char* name; //< region name (function name or other custom name)
const char* filename; //< source code filename
int line; //< source code line
int flags; //< flags (implementation code path: Plain, IPP, OpenCL)
LocationExtraData** ppExtra; ///< implementation specific data
const char* name; ///< region name (function name or other custom name)
const char* filename; ///< source code filename
int line; ///< source code line
int flags; ///< flags (implementation code path: Plain, IPP, OpenCL)
};
Region(const LocationStaticStorage& location);
@@ -100,18 +100,18 @@ private:
//! Specify region flags
enum RegionLocationFlag {
REGION_FLAG_FUNCTION = (1 << 0), //< region is function (=1) / nested named region (=0)
REGION_FLAG_APP_CODE = (1 << 1), //< region is Application code (=1) / OpenCV library code (=0)
REGION_FLAG_SKIP_NESTED = (1 << 2), //< avoid processing of nested regions
REGION_FLAG_FUNCTION = (1 << 0), ///< region is function (=1) / nested named region (=0)
REGION_FLAG_APP_CODE = (1 << 1), ///< region is Application code (=1) / OpenCV library code (=0)
REGION_FLAG_SKIP_NESTED = (1 << 2), ///< avoid processing of nested regions
REGION_FLAG_IMPL_IPP = (1 << 16), //< region is part of IPP code path
REGION_FLAG_IMPL_OPENCL = (2 << 16), //< region is part of OpenCL code path
REGION_FLAG_IMPL_OPENVX = (3 << 16), //< region is part of OpenVX code path
REGION_FLAG_IMPL_IPP = (1 << 16), ///< region is part of IPP code path
REGION_FLAG_IMPL_OPENCL = (2 << 16), ///< region is part of OpenCL code path
REGION_FLAG_IMPL_OPENVX = (3 << 16), ///< region is part of OpenVX code path
REGION_FLAG_IMPL_MASK = (15 << 16),
REGION_FLAG_REGION_FORCE = (1 << 30),
REGION_FLAG_REGION_NEXT = (1 << 31), //< close previous region (see #CV_TRACE_REGION_NEXT macro)
REGION_FLAG_REGION_NEXT = (1 << 31), ///< close previous region (see #CV_TRACE_REGION_NEXT macro)
ENUM_REGION_FLAG_FORCE_INT = INT_MAX
};
+2 -2
View File
@@ -2,7 +2,7 @@
#include "opencv2/core/async.hpp"
CV_PY_TO_CLASS(AsyncArray);
CV_PY_FROM_CLASS(AsyncArray);
CV_PY_TO_CLASS(AsyncArray)
CV_PY_FROM_CLASS(AsyncArray)
#endif
+10 -10
View File
@@ -20,18 +20,18 @@ template<> struct pyopencvVecConverter<cuda::GpuMat>
}
};
CV_PY_TO_CLASS(cuda::GpuMat);
CV_PY_TO_CLASS(cuda::Stream);
CV_PY_TO_CLASS(cuda::Event);
CV_PY_TO_CLASS(cuda::HostMem);
CV_PY_TO_CLASS(cuda::GpuMat)
CV_PY_TO_CLASS(cuda::Stream)
CV_PY_TO_CLASS(cuda::Event)
CV_PY_TO_CLASS(cuda::HostMem)
CV_PY_TO_CLASS_PTR(cuda::GpuMat);
CV_PY_TO_CLASS_PTR(cuda::GpuMat::Allocator);
CV_PY_TO_CLASS_PTR(cuda::GpuMat)
CV_PY_TO_CLASS_PTR(cuda::GpuMat::Allocator)
CV_PY_FROM_CLASS(cuda::GpuMat);
CV_PY_FROM_CLASS(cuda::Stream);
CV_PY_FROM_CLASS(cuda::HostMem);
CV_PY_FROM_CLASS(cuda::GpuMat)
CV_PY_FROM_CLASS(cuda::Stream)
CV_PY_FROM_CLASS(cuda::HostMem)
CV_PY_FROM_CLASS_PTR(cuda::GpuMat::Allocator);
CV_PY_FROM_CLASS_PTR(cuda::GpuMat::Allocator)
#endif
+2 -2
View File
@@ -4,8 +4,8 @@
typedef std::vector<Range> vector_Range;
CV_PY_TO_CLASS(UMat);
CV_PY_FROM_CLASS(UMat);
CV_PY_TO_CLASS(UMat)
CV_PY_FROM_CLASS(UMat)
static bool cv_mappable_to(const Ptr<Mat>& src, Ptr<UMat>& dst)
{
+1 -1
View File
@@ -45,4 +45,4 @@ PERF_TEST_P(MatDepth_tb, DISABLED_Allocation_Aligned,
SANITY_CHECK_NOTHING();
}
};
}
+1 -1
View File
@@ -53,7 +53,6 @@
#undef CV__ALLOCATOR_STATS_LOG
//#define OPENCV_ALLOC_ENABLE_STATISTICS
#define OPENCV_ALLOC_STATISTICS_LIMIT 4096 // don't track buffers less than N bytes
#ifdef HAVE_POSIX_MEMALIGN
@@ -63,6 +62,7 @@
#endif
#ifdef OPENCV_ALLOC_ENABLE_STATISTICS
#define OPENCV_ALLOC_STATISTICS_LIMIT 4096 // don't track buffers less than N bytes
#include <map>
#endif
+1 -1
View File
@@ -8,4 +8,4 @@
#include "arithm.simd_declarations.hpp"
#define ARITHM_DISPATCHING_ONLY
#include "arithm.simd.hpp"
#include "arithm.simd.hpp"
+1 -1
View File
@@ -414,4 +414,4 @@ inline int arithm_ipp_mul32f(const float *src1, size_t step1, const float *src2,
#if !ARITHM_USE_IPP
#define ARITHM_CALL_IPP(...)
#endif
#endif
-2
View File
@@ -64,8 +64,6 @@ namespace cv
Discrete Fourier Transform
\****************************************************************************************/
#define CV_MAX_LOCAL_DFT_SIZE (1 << 15)
static unsigned char bitrevTab[] =
{
0x00,0x80,0x40,0xc0,0x20,0xa0,0x60,0xe0,0x10,0x90,0x50,0xd0,0x30,0xb0,0x70,0xf0,
+94 -48
View File
@@ -69,10 +69,14 @@
/**
Add: _dst[i] = src1[i] + src2[i]_ @n
Sub: _dst[i] = src1[i] - src2[i]_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
*/
//! @addtogroup core_hal_interface_addsub Element-wise add and subtract
//! @{
@@ -96,10 +100,14 @@ inline int hal_ni_sub64f(const double *src1_data, size_t src1_step, const double
/**
Minimum: _dst[i] = min(src1[i], src2[i])_ @n
Maximum: _dst[i] = max(src1[i], src2[i])_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
*/
//! @addtogroup core_hal_interface_minmax Element-wise minimum or maximum
//! @{
@@ -122,11 +130,14 @@ inline int hal_ni_min64f(const double *src1_data, size_t src1_step, const double
/**
Absolute difference: _dst[i] = | src1[i] - src2[i] |_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param scale additional multiplier
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
*/
//! @addtogroup core_hal_interface_absdiff Element-wise absolute difference
//! @{
@@ -144,10 +155,14 @@ Bitwise AND: _dst[i] = src1[i] & src2[i]_ @n
Bitwise OR: _dst[i] = src1[i] | src2[i]_ @n
Bitwise XOR: _dst[i] = src1[i] ^ src2[i]_ @n
Bitwise NOT: _dst[i] = !src[i]_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
*/
//! @addtogroup core_hal_interface_logical Bitwise logical operations
//! @{
@@ -201,10 +216,14 @@ inline int hal_ni_not8u(const uchar *src_data, size_t src_step, uchar *dst_data,
/**
Compare: _dst[i] = src1[i] op src2[i]_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
@param operation one of (CV_HAL_CMP_EQ, CV_HAL_CMP_GT, ...)
*/
//! @addtogroup core_hal_interface_compare Element-wise compare
@@ -230,10 +249,14 @@ inline int hal_ni_cmp64f(const double *src1_data, size_t src1_step, const double
/**
Multiply: _dst[i] = scale * src1[i] * src2[i]_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
@param scale additional multiplier
*/
//! @addtogroup core_hal_interface_multiply Element-wise multiply
@@ -249,10 +272,14 @@ inline int hal_ni_mul64f(const double *src1_data, size_t src1_step, const double
/**
Divide: _dst[i] = scale * src1[i] / src2[i]_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data and step
@param src1_step first source image data and step
@param src2_data second source image data and step
@param src2_step second source image data and step
@param dst_data destination image data and step
@param dst_step destination image data and step
@param width dimensions of the images
@param height dimensions of the images
@param scale additional multiplier
*/
//! @addtogroup core_hal_interface_divide Element-wise divide
@@ -268,9 +295,12 @@ inline int hal_ni_div64f(const double *src1_data, size_t src1_step, const double
/**
Computes reciprocial: _dst[i] = scale / src[i]_
@param src_data,src_step source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src_data source image data
@param src_step source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
@param scale additional multiplier
*/
//! @addtogroup core_hal_interface_reciprocial Element-wise reciprocial
@@ -310,10 +340,14 @@ inline int hal_ni_recip64f(const double *src_data, size_t src_step, double *dst_
/**
Computes weighted sum of two arrays using formula: _dst[i] = a * src1[i] + b * src2[i] + c_
@param src1_data,src1_step first source image data and step
@param src2_data,src2_step second source image data and step
@param dst_data,dst_step destination image data and step
@param width,height dimensions of the images
@param src1_data first source image data
@param src1_step first source image step
@param src2_data second source image data
@param src2_step second source image step
@param dst_data destination image data
@param dst_step destination image step
@param width width of the images
@param height height of the images
@param scalars numbers _a_, _b_, and _c_
*/
//! @addtogroup core_hal_interface_addWeighted Element-wise weighted sum
@@ -381,7 +415,8 @@ inline int hal_ni_merge64s(const int64 **src_data, int64 *dst_data, int len, int
/**
@param y,x source Y and X arrays
@param y source Y arrays
@param x source X arrays
@param dst destination array
@param len length of arrays
@param angleInDegrees if set to true return angles in degrees, otherwise in radians
@@ -399,7 +434,8 @@ inline int hal_ni_fastAtan64f(const double* y, const double* x, double* dst, int
/**
@param x,y source X and Y arrays
@param x source X array
@param y source Y array
@param dst destination array
@param len length of arrays
*/
@@ -530,7 +566,8 @@ inline int hal_ni_dftFree1D(cvhalDFT *context) { return CV_HAL_ERROR_NOT_IMPLEME
/**
@param context double pointer to context storing all necessary data
@param width,height image dimensions
@param width image width
@param height image height
@param depth image type (CV_32F or CV_64F)
@param src_channels number of channels in input image
@param dst_channels number of channels in output image
@@ -540,8 +577,10 @@ inline int hal_ni_dftFree1D(cvhalDFT *context) { return CV_HAL_ERROR_NOT_IMPLEME
inline int hal_ni_dftInit2D(cvhalDFT **context, int width, int height, int depth, int src_channels, int dst_channels, int flags, int nonzero_rows) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
/**
@param context pointer to context storing all necessary data
@param src_data,src_step source image data and step
@param dst_data,dst_step destination image data and step
@param src_data source image data
@param src_step source image step
@param dst_data destination image data
@param dst_step destination image step
*/
inline int hal_ni_dft2D(cvhalDFT *context, const uchar *src_data, size_t src_step, uchar *dst_data, size_t dst_step) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
/**
@@ -557,15 +596,18 @@ inline int hal_ni_dftFree2D(cvhalDFT *context) { return CV_HAL_ERROR_NOT_IMPLEME
/**
@param context double pointer to context storing all necessary data
@param width,height image dimensions
@param width image width
@param height image height
@param depth image type (CV_32F or CV_64F)
@param flags algorithm options (combination of CV_HAL_DFT_INVERSE, ...)
*/
inline int hal_ni_dctInit2D(cvhalDFT **context, int width, int height, int depth, int flags) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
/**
@param context pointer to context storing all necessary data
@param src_data,src_step source image data and step
@param dst_data,dst_step destination image data and step
@param src_data source image data
@param src_step source image step
@param dst_data destination image data
@param dst_step destination image step
*/
inline int hal_ni_dct2D(cvhalDFT *context, const uchar *src_data, size_t src_step, uchar *dst_data, size_t dst_step) { return CV_HAL_ERROR_NOT_IMPLEMENTED; }
/**
@@ -717,11 +759,15 @@ inline int hal_ni_gemm64fc(const double* src1, size_t src1_step, const double* s
/**
@brief Finds the global minimum and maximum in an array.
@param src_data,src_step Source image
@param width,height Source image dimensions
@param src_data Source image
@param src_step Source image
@param width Source image dimensions
@param height Source image dimensions
@param depth Depth of source image
@param minVal,maxVal Pointer to the returned global minimum and maximum in an array.
@param minIdx,maxIdx Pointer to the returned minimum and maximum location.
@param minVal Pointer to the returned global minimum and maximum in an array.
@param maxVal Pointer to the returned global minimum and maximum in an array.
@param minIdx Pointer to the returned minimum and maximum location.
@param maxIdx Pointer to the returned minimum and maximum location.
@param mask Specified array region.
*/
inline int hal_ni_minMaxIdx(const uchar* src_data, size_t src_step, int width, int height, int depth, double* minVal, double* maxVal,
+3 -3
View File
@@ -1545,9 +1545,9 @@ void cv::minMaxIdx(InputArray _src, double* minVal,
if (!src.empty() && mask.empty())
{
if( minidx == 0 )
minidx = 1;
if( maxidx == 0 )
maxidx = 1;
minidx = 1;
if( maxidx == 0 )
maxidx = 1;
}
if( minidx == 0 )
+1 -1
View File
@@ -791,7 +791,7 @@ int getThreadNum()
return 0;
#endif
#elif defined HAVE_HPX
return (int)(hpx::get_num_worker_threads());
return (int)(hpx::get_num_worker_threads());
#elif defined HAVE_OPENMP
return omp_get_thread_num();
#elif defined HAVE_GCD
@@ -367,4 +367,4 @@ size_t base64::RawDataToBinaryConvertor::make_to_binary_funcs(const std::string
return offset_packed;
}
}
}
@@ -124,4 +124,4 @@ private:
}
}
#endif
#endif
-34
View File
@@ -306,9 +306,6 @@ softdouble cos(const softdouble& a) { return f64_cos(a); }
| The values to return on conversions to 32-bit integer formats that raise an
| invalid exception.
*----------------------------------------------------------------------------*/
#define ui32_fromPosOverflow 0xFFFFFFFF
#define ui32_fromNegOverflow 0
#define ui32_fromNaN 0xFFFFFFFF
#define i32_fromPosOverflow 0x7FFFFFFF
#define i32_fromNegOverflow (-0x7FFFFFFF - 1)
#define i32_fromNaN 0x7FFFFFFF
@@ -317,9 +314,6 @@ softdouble cos(const softdouble& a) { return f64_cos(a); }
| The values to return on conversions to 64-bit integer formats that raise an
| invalid exception.
*----------------------------------------------------------------------------*/
#define ui64_fromPosOverflow UINT64_C( 0xFFFFFFFFFFFFFFFF )
#define ui64_fromNegOverflow 0
#define ui64_fromNaN UINT64_C( 0xFFFFFFFFFFFFFFFF )
#define i64_fromPosOverflow UINT64_C( 0x7FFFFFFFFFFFFFFF )
//fixed unsigned unary minus: -x == ~x + 1
//#define i64_fromNegOverflow (-UINT64_C( 0x7FFFFFFFFFFFFFFF ) - 1)
@@ -422,34 +416,6 @@ struct uint64_extra { uint64_t v, extra; };
struct uint128_extra { struct uint128 v; uint64_t extra; };
#endif
/*----------------------------------------------------------------------------
| These macros are used to isolate the differences in word order between big-
| endian and little-endian platforms.
*----------------------------------------------------------------------------*/
#ifndef WORDS_BIGENDIAN
#define wordIncr 1
#define indexWord( total, n ) (n)
#define indexWordHi( total ) ((total) - 1)
#define indexWordLo( total ) 0
#define indexMultiword( total, m, n ) (n)
#define indexMultiwordHi( total, n ) ((total) - (n))
#define indexMultiwordLo( total, n ) 0
#define indexMultiwordHiBut( total, n ) (n)
#define indexMultiwordLoBut( total, n ) 0
#define INIT_UINTM4( v3, v2, v1, v0 ) { v0, v1, v2, v3 }
#else
#define wordIncr -1
#define indexWord( total, n ) ((total) - 1 - (n))
#define indexWordHi( total ) 0
#define indexWordLo( total ) ((total) - 1)
#define indexMultiword( total, m, n ) ((total) - 1 - (m))
#define indexMultiwordHi( total, n ) 0
#define indexMultiwordLo( total, n ) ((total) - (n))
#define indexMultiwordHiBut( total, n ) 0
#define indexMultiwordLoBut( total, n ) (n)
#define INIT_UINTM4( v3, v2, v1, v0 ) { v3, v2, v1, v0 }
#endif
enum {
softfloat_mulAdd_subC = 1,
softfloat_mulAdd_subProd = 2
+1 -1
View File
@@ -220,4 +220,4 @@ void split64s(const int64* src, int64** dst, int len, int cn )
#endif
CV_CPU_OPTIMIZATION_NAMESPACE_END
}} // namespace
}} // namespace
+7 -7
View File
@@ -648,7 +648,7 @@ static void inRangeS(const Mat& src, const Scalar& lb, const Scalar& rb, Mat& ds
}
} // namespace
CVTEST_GUARD_SYMBOL(inRange);
CVTEST_GUARD_SYMBOL(inRange)
struct InRangeSOp : public BaseElemWiseOp
{
@@ -1178,7 +1178,7 @@ struct MeanOp : public BaseElemWiseOp
MeanOp() : BaseElemWiseOp(1, FIX_ALPHA+FIX_BETA+FIX_GAMMA+SUPPORT_MASK+SCALAR_OUTPUT, 1, 1, Scalar::all(0))
{
context = 3;
};
}
void op(const vector<Mat>& src, Mat& dst, const Mat& mask)
{
dst.create(1, 1, CV_64FC4);
@@ -1201,7 +1201,7 @@ struct SumOp : public BaseElemWiseOp
SumOp() : BaseElemWiseOp(1, FIX_ALPHA+FIX_BETA+FIX_GAMMA+SCALAR_OUTPUT, 1, 1, Scalar::all(0))
{
context = 3;
};
}
void op(const vector<Mat>& src, Mat& dst, const Mat&)
{
dst.create(1, 1, CV_64FC4);
@@ -1261,7 +1261,7 @@ struct MeanStdDevOp : public BaseElemWiseOp
{
cn = 0;
context = 7;
};
}
void op(const vector<Mat>& src, Mat& dst, const Mat& mask)
{
dst.create(1, 2, CV_64FC4);
@@ -1302,7 +1302,7 @@ struct NormOp : public BaseElemWiseOp
{
context = 1;
normType = 0;
};
}
int getRandomType(RNG& rng)
{
int type = cvtest::randomType(rng, _OutputArray::DEPTH_MASK_ALL_BUT_8S, 1, 4);
@@ -1348,7 +1348,7 @@ struct MinMaxLocOp : public BaseElemWiseOp
MinMaxLocOp() : BaseElemWiseOp(1, FIX_ALPHA+FIX_BETA+FIX_GAMMA+SUPPORT_MASK+SCALAR_OUTPUT, 1, 1, Scalar::all(0))
{
context = ARITHM_MAX_NDIMS*2 + 2;
};
}
int getRandomType(RNG& rng)
{
return cvtest::randomType(rng, _OutputArray::DEPTH_MASK_ALL_BUT_8S, 1, 1);
@@ -1395,7 +1395,7 @@ struct reduceArgMinMaxOp : public BaseElemWiseOp
isLast(false), isMax(false), axis(0)
{
context = ARITHM_MAX_NDIMS*2 + 2;
};
}
int getRandomType(RNG& rng) override
{
return cvtest::randomType(rng, _OutputArray::DEPTH_MASK_ALL_BUT_8S, 1, 1);