Fixed number of warnings. Fixed mingw64 build.
This commit is contained in:
@@ -111,22 +111,22 @@ int main(int argc, const char* argv[])
|
||||
GpuMat d_fu, d_fv;
|
||||
|
||||
d_flow(d_frame0, d_frame1, d_fu, d_fv);
|
||||
|
||||
|
||||
Mat flowFieldForward;
|
||||
getFlowField(Mat(d_fu), Mat(d_fv), flowFieldForward);
|
||||
|
||||
|
||||
cout << "\tBackward..." << endl;
|
||||
|
||||
GpuMat d_bu, d_bv;
|
||||
|
||||
d_flow(d_frame1, d_frame0, d_bu, d_bv);
|
||||
|
||||
|
||||
Mat flowFieldBackward;
|
||||
getFlowField(Mat(d_bu), Mat(d_bv), flowFieldBackward);
|
||||
|
||||
#ifdef HAVE_OPENGL
|
||||
cout << "Create Optical Flow Needle Map..." << endl;
|
||||
|
||||
|
||||
GpuMat d_vertex, d_colors;
|
||||
|
||||
createOpticalFlowNeedleMap(d_fu, d_fv, d_vertex, d_colors);
|
||||
@@ -153,7 +153,7 @@ int main(int argc, const char* argv[])
|
||||
d_bt.upload(channels[0]);
|
||||
d_gt.upload(channels[1]);
|
||||
d_rt.upload(channels[2]);
|
||||
|
||||
|
||||
// temporary buffer
|
||||
GpuMat d_buf;
|
||||
|
||||
@@ -179,8 +179,8 @@ int main(int argc, const char* argv[])
|
||||
// interpolate red channel
|
||||
interpolateFrames(d_r, d_rt, d_fu, d_fv, d_bu, d_bv, timePos, d_rNew, d_buf);
|
||||
|
||||
GpuMat channels[] = {d_bNew, d_gNew, d_rNew};
|
||||
merge(channels, 3, d_newFrame);
|
||||
GpuMat channels3[] = {d_bNew, d_gNew, d_rNew};
|
||||
merge(channels3, 3, d_newFrame);
|
||||
|
||||
frames.push_back(Mat(d_newFrame));
|
||||
|
||||
@@ -218,7 +218,7 @@ int main(int argc, const char* argv[])
|
||||
return 0;
|
||||
|
||||
case 'A':
|
||||
if (currentFrame > 0)
|
||||
if (currentFrame > 0)
|
||||
--currentFrame;
|
||||
|
||||
imshow("Interpolated frame", frames[currentFrame]);
|
||||
@@ -269,7 +269,7 @@ void getFlowField(const Mat& u, const Mat& v, Mat& flowField)
|
||||
{
|
||||
float d = max(fabsf(ptr_u[j]), fabsf(ptr_v[j]));
|
||||
|
||||
if (d > maxDisplacement)
|
||||
if (d > maxDisplacement)
|
||||
maxDisplacement = d;
|
||||
}
|
||||
}
|
||||
|
@@ -14,11 +14,11 @@
|
||||
class Runnable
|
||||
{
|
||||
public:
|
||||
explicit Runnable(const std::string& name): name_(name) {}
|
||||
explicit Runnable(const std::string& nameStr): name_(nameStr) {}
|
||||
virtual ~Runnable() {}
|
||||
|
||||
const std::string& name() const { return name_; }
|
||||
|
||||
|
||||
const std::string& name() const { return name_; }
|
||||
|
||||
virtual void run() = 0;
|
||||
|
||||
private:
|
||||
@@ -59,7 +59,7 @@ public:
|
||||
bool stop() const { return cur_iter_idx_ >= num_iters_; }
|
||||
|
||||
void cpuOn() { cpu_started_ = cv::getTickCount(); }
|
||||
void cpuOff()
|
||||
void cpuOff()
|
||||
{
|
||||
int64 delta = cv::getTickCount() - cpu_started_;
|
||||
cpu_times_.push_back(delta);
|
||||
@@ -73,7 +73,7 @@ public:
|
||||
}
|
||||
|
||||
void gpuOn() { gpu_started_ = cv::getTickCount(); }
|
||||
void gpuOff()
|
||||
void gpuOff()
|
||||
{
|
||||
int64 delta = cv::getTickCount() - gpu_started_;
|
||||
gpu_times_.push_back(delta);
|
||||
@@ -98,10 +98,10 @@ private:
|
||||
{
|
||||
cpu_times_.reserve(num_iters_);
|
||||
gpu_times_.reserve(num_iters_);
|
||||
}
|
||||
}
|
||||
|
||||
void finishCurrentSubtest();
|
||||
void resetCurrentSubtest()
|
||||
void resetCurrentSubtest()
|
||||
{
|
||||
cpu_elapsed_ = 0;
|
||||
gpu_elapsed_ = 0;
|
||||
@@ -180,7 +180,7 @@ private:
|
||||
} TestSystem::instance().gpuComplete()
|
||||
|
||||
// Generates a matrix
|
||||
void gen(cv::Mat& mat, int rows, int cols, int type, cv::Scalar low,
|
||||
void gen(cv::Mat& mat, int rows, int cols, int type, cv::Scalar low,
|
||||
cv::Scalar high);
|
||||
|
||||
// Returns abs path taking into account test system working dir
|
||||
|
@@ -74,7 +74,7 @@ struct DrawData
|
||||
GlArrays arr;
|
||||
};
|
||||
|
||||
void drawCallback(void* userdata)
|
||||
static void drawCallback(void* userdata)
|
||||
{
|
||||
DrawData* data = static_cast<DrawData*>(userdata);
|
||||
|
||||
|
@@ -136,8 +136,8 @@ Params Params::read(int argc, char** argv)
|
||||
}
|
||||
|
||||
|
||||
App::App(const Params& p)
|
||||
: p(p), running(false)
|
||||
App::App(const Params& params)
|
||||
: p(params), running(false)
|
||||
{
|
||||
cv::gpu::printShortCudaDeviceInfo(cv::gpu::getDevice());
|
||||
|
||||
|
Reference in New Issue
Block a user