Revert "Revert "Merge pull request #836 from jet47:gpu-modules""

This commit is contained in:
Vladislav Vinogradov
2013-06-04 13:32:35 +04:00
parent 10340fe234
commit 3eeaa9189c
472 changed files with 29894 additions and 23019 deletions

View File

@@ -52,8 +52,8 @@
#include "opencv2/videostab/motion_core.hpp"
#include "opencv2/videostab/outlier_rejection.hpp"
#ifdef HAVE_OPENCV_GPU
#include "opencv2/gpu.hpp"
#ifdef HAVE_OPENCV_GPUIMGPROC
# include "opencv2/gpuimgproc.hpp"
#endif
namespace cv
@@ -199,7 +199,8 @@ private:
std::vector<Point2f> pointsPrevGood_, pointsGood_;
};
#ifdef HAVE_OPENCV_GPU
#if defined(HAVE_OPENCV_GPUIMGPROC) && defined(HAVE_OPENCV_GPU) && defined(HAVE_OPENCV_GPUOPTFLOW)
class CV_EXPORTS KeypointBasedMotionEstimatorGpu : public ImageMotionEstimatorBase
{
public:
@@ -228,7 +229,8 @@ private:
std::vector<Point2f> hostPointsPrevTmp_, hostPointsTmp_;
std::vector<uchar> rejectionStatus_;
};
#endif
#endif // defined(HAVE_OPENCV_GPUIMGPROC) && defined(HAVE_OPENCV_GPU) && defined(HAVE_OPENCV_GPUOPTFLOW)
CV_EXPORTS Mat getMotion(int from, int to, const std::vector<Mat> &motions);

View File

@@ -46,8 +46,8 @@
#include "opencv2/core.hpp"
#include "opencv2/opencv_modules.hpp"
#ifdef HAVE_OPENCV_GPU
#include "opencv2/gpu.hpp"
#ifdef HAVE_OPENCV_GPUOPTFLOW
#include "opencv2/gpuoptflow.hpp"
#endif
namespace cv
@@ -99,7 +99,8 @@ public:
OutputArray status, OutputArray errors);
};
#ifdef HAVE_OPENCV_GPU
#ifdef HAVE_OPENCV_GPUOPTFLOW
class CV_EXPORTS SparsePyrLkOptFlowEstimatorGpu
: public PyrLkOptFlowEstimatorBase, public ISparseOptFlowEstimator
{
@@ -135,6 +136,7 @@ private:
gpu::PyrLKOpticalFlow optFlowEstimator_;
gpu::GpuMat frame0_, frame1_, flowX_, flowY_, errors_;
};
#endif
} // namespace videostab

View File

@@ -45,13 +45,10 @@
#include <vector>
#include "opencv2/core.hpp"
#include "opencv2/core/gpumat.hpp"
#include "opencv2/videostab/global_motion.hpp"
#include "opencv2/videostab/log.hpp"
#ifdef HAVE_OPENCV_GPU
#include "opencv2/gpu.hpp"
#endif
namespace cv
{
namespace videostab