Import of pkgsrc-2013Q2

This commit is contained in:
2013-09-26 17:14:40 +02:00
commit 785076ae39
74991 changed files with 4380255 additions and 0 deletions
+12
View File
@@ -0,0 +1,12 @@
OpenCV means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
OpenCV provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are Python
bindings to OpenCV. OpenCV has no strict dependencies on external
libraries, though it can use some (such as libjpeg, ffmpeg, GTK+ etc.)
OpenCV provides transparent interface to Intel(R) Integrated Performance
Primitives (IPP). That is, it loads automatically IPP libraries optimized
for specific processor at runtime, if they are available.
+47
View File
@@ -0,0 +1,47 @@
# $NetBSD: Makefile,v 1.40 2013/06/14 21:28:42 wiz Exp $
DISTNAME= opencv-2.4.5
CATEGORIES= graphics devel
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=opencvlibrary/}
MAINTAINER= anthony.mallet@laas.fr
HOMEPAGE= http://code.opencv.org/projects/OpenCV/wiki/WikiStart
COMMENT= Library for computer vision problems
LICENSE= modified-bsd
USE_CMAKE= yes
USE_LANGUAGES= c c++
USE_LIBTOOL= yes
USE_PKGLOCALEDIR= yes
USE_TOOLS+= gmake pkg-config
INSTALLATION_DIRS+= share/doc/opencv/papers
INSTALLATION_DIRS+= share/doc/opencv/ref/pics
INSTALLATION_DIRS+= share/OpenCV/haarcascades
PKGCONFIG_OVERRIDE+= opencv.pc.cmake.in
REPLACE_PYTHON+= samples/python/*.py
WRKSRC= ${WRKDIR}/${DISTNAME:S/a$//}
# includes configure output and paths to gmake etc.
CHECK_WRKREF_SKIP= ${PREFIX}/lib/libopencv_core.*
.include "options.mk"
.include "../../mk/compiler.mk"
.if !empty(PKGSRC_COMPILER:Mclang)
CXXFLAGS+= -std=c++11
.endif
.include "../../devel/zlib/buildlink3.mk"
.include "../../graphics/jasper/buildlink3.mk"
.include "../../graphics/openexr/buildlink3.mk"
.include "../../graphics/png/buildlink3.mk"
.include "../../graphics/tiff/buildlink3.mk"
.if ${OPSYS} != "Darwin"
.include "../../x11/gtk2/buildlink3.mk"
.endif
.include "../../mk/jpeg.buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
+248
View File
@@ -0,0 +1,248 @@
@comment $NetBSD: PLIST,v 1.10 2013/06/14 21:28:42 wiz Exp $
bin/opencv_createsamples
bin/opencv_haartraining
bin/opencv_performance
bin/opencv_traincascade
include/opencv/cv.h
include/opencv/cv.hpp
include/opencv/cvaux.h
include/opencv/cvaux.hpp
include/opencv/cvwimage.h
include/opencv/cxcore.h
include/opencv/cxcore.hpp
include/opencv/cxeigen.hpp
include/opencv/cxmisc.h
include/opencv/highgui.h
include/opencv/ml.h
include/opencv2/calib3d/calib3d.hpp
include/opencv2/contrib/contrib.hpp
include/opencv2/contrib/detection_based_tracker.hpp
include/opencv2/contrib/hybridtracker.hpp
include/opencv2/contrib/openfabmap.hpp
include/opencv2/contrib/retina.hpp
include/opencv2/core/core.hpp
include/opencv2/core/core_c.h
include/opencv2/core/cuda_devptrs.hpp
include/opencv2/core/devmem2d.hpp
include/opencv2/core/eigen.hpp
include/opencv2/core/gpumat.hpp
include/opencv2/core/internal.hpp
include/opencv2/core/mat.hpp
include/opencv2/core/opengl_interop.hpp
include/opencv2/core/opengl_interop_deprecated.hpp
include/opencv2/core/operations.hpp
include/opencv2/core/types_c.h
include/opencv2/core/version.hpp
include/opencv2/core/wimage.hpp
include/opencv2/features2d/features2d.hpp
include/opencv2/flann/all_indices.h
include/opencv2/flann/allocator.h
include/opencv2/flann/any.h
include/opencv2/flann/autotuned_index.h
include/opencv2/flann/composite_index.h
include/opencv2/flann/config.h
include/opencv2/flann/defines.h
include/opencv2/flann/dist.h
include/opencv2/flann/dummy.h
include/opencv2/flann/dynamic_bitset.h
include/opencv2/flann/flann.hpp
include/opencv2/flann/flann_base.hpp
include/opencv2/flann/general.h
include/opencv2/flann/ground_truth.h
include/opencv2/flann/hdf5.h
include/opencv2/flann/heap.h
include/opencv2/flann/hierarchical_clustering_index.h
include/opencv2/flann/index_testing.h
include/opencv2/flann/kdtree_index.h
include/opencv2/flann/kdtree_single_index.h
include/opencv2/flann/kmeans_index.h
include/opencv2/flann/linear_index.h
include/opencv2/flann/logger.h
include/opencv2/flann/lsh_index.h
include/opencv2/flann/lsh_table.h
include/opencv2/flann/matrix.h
include/opencv2/flann/miniflann.hpp
include/opencv2/flann/nn_index.h
include/opencv2/flann/object_factory.h
include/opencv2/flann/params.h
include/opencv2/flann/random.h
include/opencv2/flann/result_set.h
include/opencv2/flann/sampling.h
include/opencv2/flann/saving.h
include/opencv2/flann/simplex_downhill.h
include/opencv2/flann/timer.h
include/opencv2/gpu/device/block.hpp
include/opencv2/gpu/device/border_interpolate.hpp
include/opencv2/gpu/device/color.hpp
include/opencv2/gpu/device/common.hpp
include/opencv2/gpu/device/datamov_utils.hpp
include/opencv2/gpu/device/detail/color_detail.hpp
include/opencv2/gpu/device/detail/reduce.hpp
include/opencv2/gpu/device/detail/reduce_key_val.hpp
include/opencv2/gpu/device/detail/transform_detail.hpp
include/opencv2/gpu/device/detail/type_traits_detail.hpp
include/opencv2/gpu/device/detail/vec_distance_detail.hpp
include/opencv2/gpu/device/dynamic_smem.hpp
include/opencv2/gpu/device/emulation.hpp
include/opencv2/gpu/device/filters.hpp
include/opencv2/gpu/device/funcattrib.hpp
include/opencv2/gpu/device/functional.hpp
include/opencv2/gpu/device/limits.hpp
include/opencv2/gpu/device/reduce.hpp
include/opencv2/gpu/device/saturate_cast.hpp
include/opencv2/gpu/device/scan.hpp
include/opencv2/gpu/device/simd_functions.hpp
include/opencv2/gpu/device/static_check.hpp
include/opencv2/gpu/device/transform.hpp
include/opencv2/gpu/device/type_traits.hpp
include/opencv2/gpu/device/utility.hpp
include/opencv2/gpu/device/vec_distance.hpp
include/opencv2/gpu/device/vec_math.hpp
include/opencv2/gpu/device/vec_traits.hpp
include/opencv2/gpu/device/warp.hpp
include/opencv2/gpu/device/warp_reduce.hpp
include/opencv2/gpu/device/warp_shuffle.hpp
include/opencv2/gpu/devmem2d.hpp
include/opencv2/gpu/gpu.hpp
include/opencv2/gpu/gpumat.hpp
include/opencv2/gpu/stream_accessor.hpp
include/opencv2/highgui/cap_ios.h
include/opencv2/highgui/highgui.hpp
include/opencv2/highgui/highgui_c.h
include/opencv2/imgproc/imgproc.hpp
include/opencv2/imgproc/imgproc_c.h
include/opencv2/imgproc/types_c.h
include/opencv2/legacy/blobtrack.hpp
include/opencv2/legacy/compat.hpp
include/opencv2/legacy/legacy.hpp
include/opencv2/legacy/streams.hpp
include/opencv2/ml/ml.hpp
include/opencv2/nonfree/features2d.hpp
include/opencv2/nonfree/gpu.hpp
include/opencv2/nonfree/nonfree.hpp
include/opencv2/nonfree/ocl.hpp
include/opencv2/objdetect/objdetect.hpp
include/opencv2/opencv.hpp
include/opencv2/opencv_modules.hpp
include/opencv2/photo/photo.hpp
include/opencv2/photo/photo_c.h
include/opencv2/stitching/detail/autocalib.hpp
include/opencv2/stitching/detail/blenders.hpp
include/opencv2/stitching/detail/camera.hpp
include/opencv2/stitching/detail/exposure_compensate.hpp
include/opencv2/stitching/detail/matchers.hpp
include/opencv2/stitching/detail/motion_estimators.hpp
include/opencv2/stitching/detail/seam_finders.hpp
include/opencv2/stitching/detail/util.hpp
include/opencv2/stitching/detail/util_inl.hpp
include/opencv2/stitching/detail/warpers.hpp
include/opencv2/stitching/detail/warpers_inl.hpp
include/opencv2/stitching/stitcher.hpp
include/opencv2/stitching/warpers.hpp
include/opencv2/superres/optical_flow.hpp
include/opencv2/superres/superres.hpp
include/opencv2/ts/gpu_perf.hpp
include/opencv2/ts/gpu_test.hpp
include/opencv2/ts/ts.hpp
include/opencv2/ts/ts_gtest.h
include/opencv2/ts/ts_perf.hpp
include/opencv2/video/background_segm.hpp
include/opencv2/video/tracking.hpp
include/opencv2/video/video.hpp
include/opencv2/videostab/deblurring.hpp
include/opencv2/videostab/fast_marching.hpp
include/opencv2/videostab/fast_marching_inl.hpp
include/opencv2/videostab/frame_source.hpp
include/opencv2/videostab/global_motion.hpp
include/opencv2/videostab/inpainting.hpp
include/opencv2/videostab/log.hpp
include/opencv2/videostab/motion_stabilizing.hpp
include/opencv2/videostab/optical_flow.hpp
include/opencv2/videostab/stabilizer.hpp
include/opencv2/videostab/videostab.hpp
lib/libopencv_calib3d.so
lib/libopencv_calib3d.so.2.4
lib/libopencv_calib3d.so.${PKGVERSION}
lib/libopencv_contrib.so
lib/libopencv_contrib.so.2.4
lib/libopencv_contrib.so.${PKGVERSION}
lib/libopencv_core.so
lib/libopencv_core.so.2.4
lib/libopencv_core.so.${PKGVERSION}
lib/libopencv_features2d.so
lib/libopencv_features2d.so.2.4
lib/libopencv_features2d.so.${PKGVERSION}
lib/libopencv_flann.so
lib/libopencv_flann.so.2.4
lib/libopencv_flann.so.${PKGVERSION}
lib/libopencv_gpu.so
lib/libopencv_gpu.so.2.4
lib/libopencv_gpu.so.${PKGVERSION}
lib/libopencv_highgui.so
lib/libopencv_highgui.so.2.4
lib/libopencv_highgui.so.${PKGVERSION}
lib/libopencv_imgproc.so
lib/libopencv_imgproc.so.2.4
lib/libopencv_imgproc.so.${PKGVERSION}
lib/libopencv_legacy.so
lib/libopencv_legacy.so.2.4
lib/libopencv_legacy.so.${PKGVERSION}
lib/libopencv_ml.so
lib/libopencv_ml.so.2.4
lib/libopencv_ml.so.${PKGVERSION}
lib/libopencv_nonfree.so
lib/libopencv_nonfree.so.2.4
lib/libopencv_nonfree.so.${PKGVERSION}
lib/libopencv_objdetect.so
lib/libopencv_objdetect.so.2.4
lib/libopencv_objdetect.so.${PKGVERSION}
lib/libopencv_photo.so
lib/libopencv_photo.so.2.4
lib/libopencv_photo.so.${PKGVERSION}
lib/libopencv_stitching.so
lib/libopencv_stitching.so.2.4
lib/libopencv_stitching.so.${PKGVERSION}
lib/libopencv_superres.so
lib/libopencv_superres.so.2.4
lib/libopencv_superres.so.${PKGVERSION}
lib/libopencv_ts.so
lib/libopencv_ts.so.2.4
lib/libopencv_ts.so.${PKGVERSION}
lib/libopencv_video.so
lib/libopencv_video.so.2.4
lib/libopencv_video.so.${PKGVERSION}
lib/libopencv_videostab.so
lib/libopencv_videostab.so.2.4
lib/libopencv_videostab.so.${PKGVERSION}
lib/pkgconfig/opencv.pc
${PLIST.python}${PYSITELIB}/cv.py
${PLIST.python}${PYSITELIB}/cv2.so
share/OpenCV/OpenCVConfig-version.cmake
share/OpenCV/OpenCVConfig.cmake
share/OpenCV/haarcascades/haarcascade_eye.xml
share/OpenCV/haarcascades/haarcascade_eye_tree_eyeglasses.xml
share/OpenCV/haarcascades/haarcascade_frontalface_alt.xml
share/OpenCV/haarcascades/haarcascade_frontalface_alt2.xml
share/OpenCV/haarcascades/haarcascade_frontalface_alt_tree.xml
share/OpenCV/haarcascades/haarcascade_frontalface_default.xml
share/OpenCV/haarcascades/haarcascade_fullbody.xml
share/OpenCV/haarcascades/haarcascade_lefteye_2splits.xml
share/OpenCV/haarcascades/haarcascade_lowerbody.xml
share/OpenCV/haarcascades/haarcascade_mcs_eyepair_big.xml
share/OpenCV/haarcascades/haarcascade_mcs_eyepair_small.xml
share/OpenCV/haarcascades/haarcascade_mcs_leftear.xml
share/OpenCV/haarcascades/haarcascade_mcs_lefteye.xml
share/OpenCV/haarcascades/haarcascade_mcs_mouth.xml
share/OpenCV/haarcascades/haarcascade_mcs_nose.xml
share/OpenCV/haarcascades/haarcascade_mcs_rightear.xml
share/OpenCV/haarcascades/haarcascade_mcs_righteye.xml
share/OpenCV/haarcascades/haarcascade_mcs_upperbody.xml
share/OpenCV/haarcascades/haarcascade_profileface.xml
share/OpenCV/haarcascades/haarcascade_righteye_2splits.xml
share/OpenCV/haarcascades/haarcascade_smile.xml
share/OpenCV/haarcascades/haarcascade_upperbody.xml
share/OpenCV/lbpcascades/lbpcascade_frontalface.xml
share/OpenCV/lbpcascades/lbpcascade_profileface.xml
share/OpenCV/lbpcascades/lbpcascade_silverware.xml
@pkgdir share/doc/opencv/ref/pics
@pkgdir share/doc/opencv/papers
+13
View File
@@ -0,0 +1,13 @@
# $NetBSD: buildlink3.mk,v 1.1 2009/11/18 23:08:48 wiz Exp $
BUILDLINK_TREE+= opencv
.if !defined(OPENCV_BUILDLINK3_MK)
OPENCV_BUILDLINK3_MK:=
BUILDLINK_API_DEPENDS.opencv+= opencv>=1.0.0nb3
BUILDLINK_PKGSRCDIR.opencv?= ../../graphics/opencv
.endif # OPENCV_BUILDLINK3_MK
BUILDLINK_TREE+= -opencv
+13
View File
@@ -0,0 +1,13 @@
$NetBSD: distinfo,v 1.22 2013/06/19 11:54:04 fhajny Exp $
SHA1 (opencv-2.4.5.tar.gz) = 9e25f821db9e25aa454a31976ba6b5a3a50b6fa4
RMD160 (opencv-2.4.5.tar.gz) = 3b7dc9da2e0b616a19e50ed5999ca0dd65c45d5f
Size (opencv-2.4.5.tar.gz) = 81884985 bytes
SHA1 (patch-modules_contrib_src_inputoutput.cpp) = dc3413182c94b670823d509ab38f21ce36d4f432
SHA1 (patch-modules_contrib_src_spinimages.cpp) = b3e465700059616be991d597230bc8dc42f15be1
SHA1 (patch-modules_core_include_opencv2_core_types_c.h) = c056068c01c417dc262f21c00324da7f86c0cd8e
SHA1 (patch-modules_core_src_system.cpp) = 3b7ac545585a430d28c7077f360357079f127580
SHA1 (patch-modules_flann_include_opencv2_flann_defines.h) = ab848e67c4e03219670598ac2d21071a617a5c33
SHA1 (patch-modules_legacy_src_dpstereo.cpp) = da9955fb6cc81054427b69efb97a58160b64f262
SHA1 (patch-modules_ts_include_opencv2_ts_ts__perf.hpp) = 8a7f08b176cedec85fd613e715d7b12d666a3e45
SHA1 (patch-modules_ts_src_ts.cpp) = 61e4ab59f2ca57f75212743bf869616dfc9e5f13
+19
View File
@@ -0,0 +1,19 @@
# $NetBSD: hacks.mk,v 1.1 2012/10/10 18:11:08 wiz Exp $
.if !defined(OPENCV_HACKS_MK)
OPENCV_HACKS_MK= defined
.include "../../mk/bsd.fast.prefs.mk"
.include "../../mk/compiler.mk"
# PR toolchain/47051: gcc-4.5.4 breaks opencv on amd64
.if !empty(PKGSRC_COMPILER:Mgcc) && !empty(CC_VERSION:Mgcc-4.5.4*) && !empty(MACHINE_PLATFORM:M*-*-x86_64)
PKG_HACKS+= tree-pre
SUBST_CLASSES+= opt-hack
SUBST_STAGE.opt-hack= post-configure
SUBST_MESSAGE.opt-hack= Working around gcc-4.5.4 bug.
SUBST_FILES.opt-hack= ${WRKSRC}/modules/calib3d/CMakeFiles/opencv_calib3d.dir/build.make
SUBST_SED.opt-hack= -e '/stereosgbm.cpp.o/s/-o/-fno-tree-pre -o/'
.endif
.endif # OPENCV_HACKS_MK
+21
View File
@@ -0,0 +1,21 @@
# $NetBSD: options.mk,v 1.3 2012/12/07 21:01:29 adam Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.opencv
PKG_SUPPORTED_OPTIONS= python
.include "../../mk/bsd.options.mk"
PLIST_VARS+= python
.if !empty(PKG_OPTIONS:Mpython)
CMAKE_ARGS+= -DPYTHON_EXECUTABLE:FILEPATH=${PYTHONBIN}
PY_PATCHPLIST= yes
.include "../../lang/python/extension.mk"
.include "../../math/py-numpy/buildlink3.mk"
PLIST.python= yes
.else
CMAKE_ARGS+= -D BUILD_NEW_PYTHON_SUPPORT=OFF
.endif
# FIXME: should be option.mk'ed instead
CMAKE_ARGS+= -D BUILD_DOXYGEN_DOCS=OFF
CMAKE_ARGS+= -D WITH_FFMPEG=OFF
@@ -0,0 +1,66 @@
$NetBSD: patch-modules_contrib_src_inputoutput.cpp,v 1.1 2013/06/12 10:13:58 jperkin Exp $
SunOS does not have dirent d_type.
--- modules/contrib/src/inputoutput.cpp.orig 2012-10-17 22:55:38.000000000 +0000
+++ modules/contrib/src/inputoutput.cpp
@@ -5,6 +5,9 @@
#include <windows.h>
#include <tchar.h>
#else
+#ifdef __sun
+ #include <sys/stat.h>
+#endif
#include <dirent.h>
#endif
@@ -47,6 +50,10 @@ namespace cv
(void)addPath;
DIR *dp;
struct dirent *dirp;
+#ifdef __sun
+ struct stat sb;
+ char buf[PATH_MAX];
+#endif
if((dp = opendir(path.c_str())) == NULL)
{
return list;
@@ -54,7 +61,13 @@ namespace cv
while ((dirp = readdir(dp)) != NULL)
{
+#ifdef __sun
+ snprintf(buf, PATH_MAX, "%s/%s", path.c_str(), dirp->d_name);
+ stat(buf, &sb);
+ if (S_ISREG(sb.st_mode))
+#else
if (dirp->d_type == DT_REG)
+#endif
{
if (exten.compare("*") == 0)
list.push_back(static_cast<std::string>(dirp->d_name));
@@ -105,6 +118,10 @@ namespace cv
(void)addPath;
DIR *dp;
struct dirent *dirp;
+#ifdef __sun
+ struct stat sb;
+ char buf[PATH_MAX];
+#endif
if((dp = opendir(path_f.c_str())) == NULL)
{
return list;
@@ -112,7 +129,13 @@ namespace cv
while ((dirp = readdir(dp)) != NULL)
{
+#ifdef __sun
+ snprintf(buf, PATH_MAX, "%s/%s", path.c_str(), dirp->d_name);
+ stat(buf, &sb);
+ if (S_ISDIR(sb.st_mode) &&
+#else
if (dirp->d_type == DT_DIR &&
+#endif
strcmp(dirp->d_name, ".") != 0 &&
strcmp(dirp->d_name, "..") != 0 )
{
@@ -0,0 +1,12 @@
$NetBSD: patch-modules_contrib_src_spinimages.cpp,v 1.1 2013/05/06 14:48:22 joerg Exp $
--- modules/contrib/src/spinimages.cpp.orig 2013-05-05 18:32:00.000000000 +0000
+++ modules/contrib/src/spinimages.cpp
@@ -46,6 +46,7 @@
#include <functional>
#include <fstream>
#include <limits>
+#include <numeric>
#include <set>
using namespace cv;
@@ -0,0 +1,15 @@
$NetBSD: patch-modules_core_include_opencv2_core_types_c.h,v 1.1 2012/12/07 21:37:10 adam Exp $
Define 'depth' as unsigned int, or IPL_DEPTH_SIGN=0x8000000 won't fit in int.
--- modules/core/include/opencv2/core/types_c.h.orig 2012-12-07 21:15:58.000000000 +0000
+++ modules/core/include/opencv2/core/types_c.h
@@ -473,7 +473,7 @@ typedef struct _IplImage
int ID; /* version (=0)*/
int nChannels; /* Most of OpenCV functions support 1,2,3 or 4 channels */
int alphaChannel; /* Ignored by OpenCV */
- int depth; /* Pixel depth in bits: IPL_DEPTH_8U, IPL_DEPTH_8S, IPL_DEPTH_16S,
+ unsigned int depth; /* Pixel depth in bits: IPL_DEPTH_8U, IPL_DEPTH_8S, IPL_DEPTH_16S,
IPL_DEPTH_32S, IPL_DEPTH_32F and IPL_DEPTH_64F are supported. */
char colorModel[4]; /* Ignored by OpenCV */
char channelSeq[4]; /* ditto */
@@ -0,0 +1,12 @@
$NetBSD: patch-modules_core_src_system.cpp,v 1.1 2013/04/29 21:31:12 joerg Exp $
--- modules/core/src/system.cpp.orig 2013-04-28 15:15:06.000000000 +0000
+++ modules/core/src/system.cpp
@@ -79,6 +79,7 @@
#include <pthread.h>
#include <sys/time.h>
#include <time.h>
+#include <unistd.h>
#if defined __MACH__ && defined __APPLE__
#include <mach/mach.h>
@@ -0,0 +1,16 @@
$NetBSD: patch-modules_flann_include_opencv2_flann_defines.h,v 1.1 2013/06/12 10:13:58 jperkin Exp $
Avoid CS conflict on SunOS.
--- modules/flann/include/opencv2/flann/defines.h.orig 2012-09-27 22:55:06.000000000 +0000
+++ modules/flann/include/opencv2/flann/defines.h
@@ -71,6 +71,9 @@
#define FLANN_PLATFORM_32_BIT
#endif
+#ifdef __sun
+#undef CS
+#endif
#undef FLANN_ARRAY_LEN
#define FLANN_ARRAY_LEN(a) (sizeof(a)/sizeof(a[0]))
@@ -0,0 +1,24 @@
$NetBSD: patch-modules_legacy_src_dpstereo.cpp,v 1.1 2013/02/26 23:38:08 joerg Exp $
--- modules/legacy/src/dpstereo.cpp.orig 2012-10-22 22:55:11.000000000 +0000
+++ modules/legacy/src/dpstereo.cpp
@@ -65,6 +65,8 @@
#define ICV_MAX_DP_SUM_VAL (INT_MAX/4)
+#include <algorithm>
+
typedef struct _CvDPCell
{
uchar step; //local-optimal step
@@ -76,8 +78,8 @@ typedef struct _CvRightImData
uchar min_val, max_val;
} _CvRightImData;
-#define CV_IMAX3(a,b,c) ((temp3 = (a) >= (b) ? (a) : (b)),(temp3 >= (c) ? temp3 : (c)))
-#define CV_IMIN3(a,b,c) ((temp3 = (a) <= (b) ? (a) : (b)),(temp3 <= (c) ? temp3 : (c)))
+#define CV_IMAX3(a,b,c) std::max((a), std::max((b), (c)))
+#define CV_IMIN3(a,b,c) std::min((a), std::min((b), (c)))
static void icvFindStereoCorrespondenceByBirchfieldDP( uchar* src1, uchar* src2,
uchar* disparities,
@@ -0,0 +1,12 @@
$NetBSD: patch-modules_ts_include_opencv2_ts_ts__perf.hpp,v 1.1 2013/02/26 23:38:08 joerg Exp $
--- modules/ts/include/opencv2/ts/ts_perf.hpp.orig 2013-02-26 16:47:16.000000000 +0000
+++ modules/ts/include/opencv2/ts/ts_perf.hpp
@@ -478,7 +478,6 @@ CV_EXPORTS void PrintTo(const Size& sz,
#define CV_PERF_TEST_MAIN(testsuitname, ...) \
int main(int argc, char **argv)\
{\
- while (++argc >= (--argc,-1)) {__VA_ARGS__; break;} /*this ugly construction is needed for VS 2005*/\
::perf::Regression::Init(#testsuitname);\
::perf::TestBase::Init(argc, argv);\
::testing::InitGoogleTest(&argc, argv);\
@@ -0,0 +1,24 @@
$NetBSD: patch-modules_ts_src_ts.cpp,v 1.2 2013/06/19 11:54:04 fhajny Exp $
Avoid std::foo conflict.
--- modules/ts/src/ts.cpp.orig 2013-04-05 09:00:20.000000000 +0000
+++ modules/ts/src/ts.cpp
@@ -562,7 +562,7 @@ void TS::vprintf( int streams, const cha
for( int i = 0; i < MAX_IDX; i++ )
if( (streams & (1 << i)) )
{
- output_buf[i] += std::string(str);
+ output_buf[i] += ::std::string(str);
// in the new GTest-based framework we do not use
// any output files (except for the automatically generated xml report).
// if a test fails, all the buffers are printed, so we do not want to duplicate the information and
@@ -617,7 +617,7 @@ void smoothBorder(Mat& img, const Scalar
Scalar s;
uchar *p = NULL;
int n = 100/delta;
- int nR = std::min(n, (img.rows+1)/2), nC = std::min(n, (img.cols+1)/2);
+ int nR = ::std::min(n, (img.rows+1)/2), nC = ::std::min(n, (img.cols+1)/2);
int r, c, i;
for(r=0; r<nR; r++)