minor + warnings
This commit is contained in:
parent
f10bff2653
commit
6b34532901
doc
modules
contrib/src
gpu
include/opencv2/gpu
src
@ -31,7 +31,7 @@ enum FeatureSet
|
|||||||
FEATURE_SET_COMPUTE_10, FEATURE_SET_COMPUTE_11,
|
FEATURE_SET_COMPUTE_10, FEATURE_SET_COMPUTE_11,
|
||||||
FEATURE_SET_COMPUTE_12, FEATURE_SET_COMPUTE_13,
|
FEATURE_SET_COMPUTE_12, FEATURE_SET_COMPUTE_13,
|
||||||
FEATURE_SET_COMPUTE_20, FEATURE_SET_COMPUTE_21,
|
FEATURE_SET_COMPUTE_20, FEATURE_SET_COMPUTE_21,
|
||||||
ATOMICS, NATIVE_DOUBLE
|
GLOBAL_ATOMICS, NATIVE_DOUBLE
|
||||||
};
|
};
|
||||||
\end{lstlisting}
|
\end{lstlisting}
|
||||||
|
|
||||||
|
@ -111,6 +111,9 @@ private:
|
|||||||
int scales_;
|
int scales_;
|
||||||
float min_scale_;
|
float min_scale_;
|
||||||
float max_scale_;
|
float max_scale_;
|
||||||
|
|
||||||
|
LocationImageRange(const LocationImageRange&);
|
||||||
|
LocationImageRange& operator=(const LocationImageRange&);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
LocationImageRange(const vector<Point>& locations, int scales = 5, float min_scale = 0.6, float max_scale = 1.6) :
|
LocationImageRange(const vector<Point>& locations, int scales = 5, float min_scale = 0.6, float max_scale = 1.6) :
|
||||||
@ -130,6 +133,8 @@ private:
|
|||||||
const vector<Point>& locations_;
|
const vector<Point>& locations_;
|
||||||
const vector<float>& scales_;
|
const vector<float>& scales_;
|
||||||
|
|
||||||
|
LocationScaleImageRange(const LocationScaleImageRange&);
|
||||||
|
LocationScaleImageRange& operator=(const LocationScaleImageRange&);
|
||||||
public:
|
public:
|
||||||
LocationScaleImageRange(const vector<Point>& locations, const vector<float>& scales) :
|
LocationScaleImageRange(const vector<Point>& locations, const vector<float>& scales) :
|
||||||
locations_(locations), scales_(scales)
|
locations_(locations), scales_(scales)
|
||||||
@ -355,6 +360,9 @@ private:
|
|||||||
int scale_cnt_;
|
int scale_cnt_;
|
||||||
|
|
||||||
bool has_next_;
|
bool has_next_;
|
||||||
|
|
||||||
|
LocationImageIterator(const LocationImageIterator&);
|
||||||
|
LocationImageIterator& operator=(const LocationImageIterator&);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
LocationImageIterator(const vector<Point>& locations, int scales, float min_scale, float max_scale);
|
LocationImageIterator(const vector<Point>& locations, int scales, float min_scale, float max_scale);
|
||||||
@ -374,6 +382,9 @@ private:
|
|||||||
size_t iter_;
|
size_t iter_;
|
||||||
|
|
||||||
bool has_next_;
|
bool has_next_;
|
||||||
|
|
||||||
|
LocationScaleImageIterator(const LocationScaleImageIterator&);
|
||||||
|
LocationScaleImageIterator& operator=(const LocationScaleImageIterator&);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
LocationScaleImageIterator(const vector<Point>& locations, const vector<float>& scales) :
|
LocationScaleImageIterator(const vector<Point>& locations, const vector<float>& scales) :
|
||||||
@ -714,7 +725,7 @@ float ChamferMatcher::Matching::getAngle(coordinate_t a, coordinate_t b, int& dx
|
|||||||
float angle = atan2((float)dy,(float)dx);
|
float angle = atan2((float)dy,(float)dx);
|
||||||
|
|
||||||
if (angle<0) {
|
if (angle<0) {
|
||||||
angle+=CV_PI;
|
angle+=(float)CV_PI;
|
||||||
}
|
}
|
||||||
|
|
||||||
return angle;
|
return angle;
|
||||||
|
@ -72,7 +72,7 @@ namespace cv
|
|||||||
FEATURE_SET_COMPUTE_13 = 13,
|
FEATURE_SET_COMPUTE_13 = 13,
|
||||||
FEATURE_SET_COMPUTE_20 = 20,
|
FEATURE_SET_COMPUTE_20 = 20,
|
||||||
FEATURE_SET_COMPUTE_21 = 21,
|
FEATURE_SET_COMPUTE_21 = 21,
|
||||||
ATOMICS = FEATURE_SET_COMPUTE_11,
|
GLOBAL_ATOMICS = FEATURE_SET_COMPUTE_11,
|
||||||
NATIVE_DOUBLE = FEATURE_SET_COMPUTE_13
|
NATIVE_DOUBLE = FEATURE_SET_COMPUTE_13
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -542,7 +542,7 @@ void cv::gpu::BruteForceMatcher_GPU_base::radiusMatch(const GpuMat& queryDescs,
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
CV_Assert(DeviceInfo().supports(ATOMICS));
|
CV_Assert(DeviceInfo().supports(GLOBAL_ATOMICS));
|
||||||
|
|
||||||
const int nQuery = queryDescs.rows;
|
const int nQuery = queryDescs.rows;
|
||||||
const int nTrain = trainDescs.rows;
|
const int nTrain = trainDescs.rows;
|
||||||
|
@ -201,7 +201,7 @@ Scalar cv::gpu::sum(const GpuMat& src, GpuMat& buf)
|
|||||||
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
||||||
|
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Caller caller = callers[src.depth()];
|
Caller caller = callers[src.depth()];
|
||||||
@ -242,7 +242,7 @@ Scalar cv::gpu::absSum(const GpuMat& src, GpuMat& buf)
|
|||||||
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
||||||
|
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Caller caller = callers[src.depth()];
|
Caller caller = callers[src.depth()];
|
||||||
@ -278,7 +278,7 @@ Scalar cv::gpu::sqrSum(const GpuMat& src, GpuMat& buf)
|
|||||||
sqrSumCaller<int>, sqrSumCaller<float>, 0 };
|
sqrSumCaller<int>, sqrSumCaller<float>, 0 };
|
||||||
|
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Size buf_size;
|
Size buf_size;
|
||||||
@ -371,7 +371,7 @@ void cv::gpu::minMax(const GpuMat& src, double* minVal, double* maxVal, const Gp
|
|||||||
if (mask.empty())
|
if (mask.empty())
|
||||||
{
|
{
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Caller caller = callers[src.type()];
|
Caller caller = callers[src.type()];
|
||||||
@ -381,7 +381,7 @@ void cv::gpu::minMax(const GpuMat& src, double* minVal, double* maxVal, const Gp
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
MaskedCaller* callers = masked_multipass_callers;
|
MaskedCaller* callers = masked_multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = masked_singlepass_callers;
|
callers = masked_singlepass_callers;
|
||||||
|
|
||||||
MaskedCaller caller = callers[src.type()];
|
MaskedCaller caller = callers[src.type()];
|
||||||
@ -474,7 +474,7 @@ void cv::gpu::minMaxLoc(const GpuMat& src, double* minVal, double* maxVal, Point
|
|||||||
if (mask.empty())
|
if (mask.empty())
|
||||||
{
|
{
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Caller caller = callers[src.type()];
|
Caller caller = callers[src.type()];
|
||||||
@ -484,7 +484,7 @@ void cv::gpu::minMaxLoc(const GpuMat& src, double* minVal, double* maxVal, Point
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
MaskedCaller* callers = masked_multipass_callers;
|
MaskedCaller* callers = masked_multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = masked_singlepass_callers;
|
callers = masked_singlepass_callers;
|
||||||
|
|
||||||
MaskedCaller caller = callers[src.type()];
|
MaskedCaller caller = callers[src.type()];
|
||||||
@ -546,7 +546,7 @@ int cv::gpu::countNonZero(const GpuMat& src, GpuMat& buf)
|
|||||||
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
ensureSizeIsEnough(buf_size, CV_8U, buf);
|
||||||
|
|
||||||
Caller* callers = multipass_callers;
|
Caller* callers = multipass_callers;
|
||||||
if (TargetArchs::builtWith(ATOMICS) && DeviceInfo().supports(ATOMICS))
|
if (TargetArchs::builtWith(GLOBAL_ATOMICS) && DeviceInfo().supports(GLOBAL_ATOMICS))
|
||||||
callers = singlepass_callers;
|
callers = singlepass_callers;
|
||||||
|
|
||||||
Caller caller = callers[src.type()];
|
Caller caller = callers[src.type()];
|
||||||
|
@ -41,6 +41,10 @@
|
|||||||
|
|
||||||
#ifndef _ncvruntimetemplates_hpp_
|
#ifndef _ncvruntimetemplates_hpp_
|
||||||
#define _ncvruntimetemplates_hpp_
|
#define _ncvruntimetemplates_hpp_
|
||||||
|
#if _MSC_VER >= 1200
|
||||||
|
#pragma warning( disable: 4800 )
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#include <stdarg.h>
|
#include <stdarg.h>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
@ -108,7 +108,7 @@ namespace
|
|||||||
CV_Assert(!img.empty() && img.type() == CV_8UC1);
|
CV_Assert(!img.empty() && img.type() == CV_8UC1);
|
||||||
CV_Assert(mask.empty() || (mask.size() == img.size() && mask.type() == CV_8UC1));
|
CV_Assert(mask.empty() || (mask.size() == img.size() && mask.type() == CV_8UC1));
|
||||||
CV_Assert(nOctaves > 0 && nIntervals > 2 && nIntervals < 22);
|
CV_Assert(nOctaves > 0 && nIntervals > 2 && nIntervals < 22);
|
||||||
CV_Assert(DeviceInfo().supports(ATOMICS));
|
CV_Assert(DeviceInfo().supports(GLOBAL_ATOMICS));
|
||||||
|
|
||||||
max_features = static_cast<int>(img.size().area() * featuresRatio);
|
max_features = static_cast<int>(img.size().area() * featuresRatio);
|
||||||
max_candidates = static_cast<int>(1.5 * max_features);
|
max_candidates = static_cast<int>(1.5 * max_features);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user