Merge branch 'master' into gpu-cuda-rename

Conflicts:
	modules/core/include/opencv2/core/cuda.hpp
	modules/cudacodec/src/thread.cpp
	modules/cudacodec/src/thread.hpp
	modules/superres/perf/perf_superres.cpp
	modules/superres/src/btv_l1_cuda.cpp
	modules/superres/src/optical_flow.cpp
	modules/videostab/src/global_motion.cpp
	modules/videostab/src/inpainting.cpp
	samples/cpp/stitching_detailed.cpp
	samples/cpp/videostab.cpp
	samples/gpu/stereo_multi.cpp
This commit is contained in:
Vladislav Vinogradov
2013-09-06 15:44:44 +04:00
parent f46b7fcf86
commit 0c7663eb3b
184 changed files with 2414 additions and 1467 deletions

View File

@@ -53,34 +53,34 @@ Stitcher Stitcher::createDefault(bool try_use_gpu)
stitcher.setPanoConfidenceThresh(1);
stitcher.setWaveCorrection(true);
stitcher.setWaveCorrectKind(detail::WAVE_CORRECT_HORIZ);
stitcher.setFeaturesMatcher(new detail::BestOf2NearestMatcher(try_use_gpu));
stitcher.setBundleAdjuster(new detail::BundleAdjusterRay());
stitcher.setFeaturesMatcher(makePtr<detail::BestOf2NearestMatcher>(try_use_gpu));
stitcher.setBundleAdjuster(makePtr<detail::BundleAdjusterRay>());
#ifdef HAVE_OPENCV_CUDA
if (try_use_gpu && cuda::getCudaEnabledDeviceCount() > 0)
{
#ifdef HAVE_OPENCV_NONFREE
stitcher.setFeaturesFinder(new detail::SurfFeaturesFinderGpu());
stitcher.setFeaturesFinder(makePtr<detail::SurfFeaturesFinderGpu>());
#else
stitcher.setFeaturesFinder(new detail::OrbFeaturesFinder());
stitcher.setFeaturesFinder(makePtr<detail::OrbFeaturesFinder>());
#endif
stitcher.setWarper(new SphericalWarperGpu());
stitcher.setSeamFinder(new detail::GraphCutSeamFinderGpu());
stitcher.setWarper(makePtr<SphericalWarperGpu>());
stitcher.setSeamFinder(makePtr<detail::GraphCutSeamFinderGpu>());
}
else
#endif
{
#ifdef HAVE_OPENCV_NONFREE
stitcher.setFeaturesFinder(new detail::SurfFeaturesFinder());
stitcher.setFeaturesFinder(makePtr<detail::SurfFeaturesFinder>());
#else
stitcher.setFeaturesFinder(new detail::OrbFeaturesFinder());
stitcher.setFeaturesFinder(makePtr<detail::OrbFeaturesFinder>());
#endif
stitcher.setWarper(new SphericalWarper());
stitcher.setSeamFinder(new detail::GraphCutSeamFinder(detail::GraphCutSeamFinderBase::COST_COLOR));
stitcher.setWarper(makePtr<SphericalWarper>());
stitcher.setSeamFinder(makePtr<detail::GraphCutSeamFinder>(detail::GraphCutSeamFinderBase::COST_COLOR));
}
stitcher.setExposureCompensator(new detail::BlocksGainCompensator());
stitcher.setBlender(new detail::MultiBandBlender(try_use_gpu));
stitcher.setExposureCompensator(makePtr<detail::BlocksGainCompensator>());
stitcher.setBlender(makePtr<detail::MultiBandBlender>(try_use_gpu));
return stitcher;
}