import opencv 2.2.0

The Open Computer Vision Library is a collection of algorithms and sample
code for various computer vision problems.

initial port by me, finished by Andreas Bihlmaier and
Rafael Sadowski (MAINTAINER), ok sthen@
This commit is contained in:
jasper 2011-06-24 09:30:21 +00:00
parent 26b7f15949
commit 81bd58a879
12 changed files with 1687 additions and 0 deletions

96
graphics/opencv/Makefile Normal file
View File

@ -0,0 +1,96 @@
# $OpenBSD: Makefile,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
ONLY_FOR_ARCH= ${GCC4_ARCHS}
SHARED_ONLY= Yes
COMMENT-main= library of programming functions for real time cv
COMMENT-docs= documentation for OpenCV
V= 2.2.0
DISTNAME= OpenCV-$V
PKGNAME-main= opencv-$V
PKGNAME-docs= opencv-docs-$V
CATEGORIES= graphics devel
SHARED_LIBS += opencv_calib3d 0.0
SHARED_LIBS += opencv_contrib 0.0
SHARED_LIBS += opencv_core 0.0
SHARED_LIBS += opencv_features2d 0.0
SHARED_LIBS += opencv_flann 0.0
SHARED_LIBS += opencv_gpu 0.0
SHARED_LIBS += opencv_highgui 0.0
SHARED_LIBS += opencv_imgproc 0.0
SHARED_LIBS += opencv_legacy 0.0
SHARED_LIBS += opencv_ml 0.0
SHARED_LIBS += opencv_objdetect 0.0
SHARED_LIBS += opencv_video 0.0
HOMEPAGE= http://opencv.willowgarage.com/
MAINTAINER= Rafael Sadowski <rafael@sizeofvoid.org>
# BSD
PERMIT_PACKAGE_CDROM= Yes
PERMIT_PACKAGE_FTP= Yes
PERMIT_DISTFILES_CDROM= Yes
PERMIT_DISTFILES_FTP= Yes
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=opencvlibrary/}
EXTRACT_SUFX= .tar.bz2
WANTLIB += GL Half Iex IlmImf Imath X11 Xau Xcomposite Xcursor
WANTLIB += Xdamage Xdmcp Xext Xfixes Xi Xinerama Xrandr Xrender
WANTLIB += Xxf86vm atk-1.0 avcodec avformat avutil bz2 c cairo
WANTLIB += drm expat faac fontconfig freetype gdk-x11-2.0 gdk_pixbuf-2.0
WANTLIB += gio-2.0 glib-2.0 gmodule-2.0 gobject-2.0 gsm gstapp-0.10
WANTLIB += gstbase-0.10 gstreamer-0.10 gstvideo-0.10 gthread-2.0
WANTLIB += gtk-x11-2.0 jasper jpeg m mp3lame ogg orc-0.4 pango-1.0
WANTLIB += pangocairo-1.0 pangoft2-1.0 pixman-1 png pthread pthread-stubs
WANTLIB += schroedinger-1.0 speex stdc++ swscale theoradec theoraenc
WANTLIB += tiff vorbis vorbisenc vpx x264 xcb xcb-render xcb-shm
WANTLIB += xml2 z ${MODPY_WANTLIB}
MODULES= devel/cmake \
devel/gettext \
lang/python
MULTI_PACKAGES= -main -docs
CONFIGURE_STYLE= cmake
LIB_DEPENDS-main= multimedia/gstreamer-0.10/plugins-base \
x11/gtk+2 \
graphics/ilmbase \
graphics/openexr \
graphics/ffmpeg
WANTLIB-docs= # empty
LIB_DEPENDS-docs= # empty
RUN_DEPENDS-docs= # empty
PKG_ARCH-docs= *
USE_LIBTOOL= Yes
VMEM_WARNING= Yes
RUN_DEPENDS-main= math/py-numpy
BUILD_DEPENDS= devel/doxygen
# ATM opencv requires V4L1 compat, ask them to change it,
# then see WITH_V4L below.
CONFIGURE_ARGS+= -DBUILD_EXAMPLES:Bool=Off \
-DINSTALL_C_EXAMPLES:Bool=Off \
-DINSTALL_PYTHON_EXAMPLES:Bool=Off \
-DBUILD_PYTHON_SUPPORT:Bool=On \
-DBUILD_LATEX_DOCS:Bool=Off \
-DWITH_GTK:Bool=On \
-DWITH_V4L:Bool=Off \
-DWITH_GSTREAMER:Bool=On \
-DWITH_1394:Bool=Off \
-DWITH_FFMPEG:Bool=On
post-configure:
find ${WRKSRC} -type f -iname "*.make" -exec \
perl -pi -e 's/(CXX_DEFINES =).*/$1/' {} \;
.include <bsd.port.mk>

5
graphics/opencv/distinfo Normal file
View File

@ -0,0 +1,5 @@
MD5 (OpenCV-2.2.0.tar.bz2) = Eiyax5OkaFTvKBn+271rGw==
RMD160 (OpenCV-2.2.0.tar.bz2) = V67bdniWT0OvPxyDioJmx7SGmwE=
SHA1 (OpenCV-2.2.0.tar.bz2) = mE7XFnLVA5HQYX/OLvWOdZDsD9c=
SHA256 (OpenCV-2.2.0.tar.bz2) = JZmCKT254ec9yiypCfwzKskjvsZFeKZX2LuKtszeuI4=
SIZE (OpenCV-2.2.0.tar.bz2) = 19800873

View File

@ -0,0 +1,31 @@
$OpenBSD: patch-CMakeLists_txt,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- CMakeLists.txt.orig Sun Dec 5 04:35:23 2010
+++ CMakeLists.txt Fri May 6 20:34:46 2011
@@ -430,7 +430,7 @@ if(UNIX)
if(WITH_V4L)
CHECK_MODULE(libv4l1 HAVE_LIBV4L)
CHECK_INCLUDE_FILE(linux/videodev.h HAVE_CAMV4L)
- CHECK_INCLUDE_FILE(linux/videodev2.h HAVE_CAMV4L2)
+ CHECK_INCLUDE_FILE(sys/videoio.h HAVE_CAMV4L2)
else()
set(HAVE_LIBV4L FALSE)
set(HAVE_CAMV4L FALSE)
@@ -464,7 +464,8 @@ if(UNIX)
endif()
endif()
- if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD" OR ${CMAKE_SYSTEM_NAME} MATCHES "NetBSD")
+ if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD" OR ${CMAKE_SYSTEM_NAME}
+ MATCHES "NetBSD" OR ${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD")
set(OPENCV_LINKER_LIBS m pthread)
else()
set(OPENCV_LINKER_LIBS dl m pthread rt)
@@ -865,7 +866,7 @@ include_directories("."
# Should be set to true for development
set(OPENCV_WARNINGS_ARE_ERRORS OFF CACHE BOOL "Treat warnings as errors")
-set(EXTRA_C_FLAGS "")
+set(EXTRA_C_FLAGS "-DHAVE_JPEG -DHAVE_TIFF -DHAVE_PNG -DHAVE_JASPER -DHAVE_OPENEXR")
set(EXTRA_C_FLAGS_RELEASE "")
set(EXTRA_C_FLAGS_DEBUG "")
set(EXTRA_EXE_LINKER_FLAGS "")

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-doc_CMakeLists_txt,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- doc/CMakeLists.txt.orig Tue Jun 14 12:46:05 2011
+++ doc/CMakeLists.txt Tue Jun 14 12:46:37 2011
@@ -157,7 +157,7 @@ add_custom_target(${HTML_TARGET} ALL
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile ${doxy_html_dep_list})
exec_program(mkdir ARGS "-p \"${CMAKE_CURRENT_BINARY_DIR}/html/\"")
-install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" DESTINATION "${OPENCV_DOC_INSTALL_PATH}/html" COMPONENT main)
+install(DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" DESTINATION "${OPENCV_DOC_INSTALL_PATH}/" COMPONENT main)
endif()

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-modules_highgui_src_cap_ffmpeg_cpp,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- modules/highgui/src/cap_ffmpeg.cpp.orig Sun Dec 5 04:35:25 2010
+++ modules/highgui/src/cap_ffmpeg.cpp Fri May 6 16:14:32 2011
@@ -610,7 +610,7 @@ IplImage* CvCapture_FFMPEG::retrieveFrame(int)
return &frame;
}
-#if defined(__APPLE__)
+#if defined(__APPLE__) || defined(__OpenBSD__)
#define AV_NOPTS_VALUE_ ((int64_t)0x8000000000000000LL)
#else
#define AV_NOPTS_VALUE_ ((int64_t)AV_NOPTS_VALUE)

View File

@ -0,0 +1,13 @@
$OpenBSD: patch-modules_highgui_src_cap_libv4l_cpp,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- modules/highgui/src/cap_libv4l.cpp.orig Sun Dec 5 04:35:25 2010
+++ modules/highgui/src/cap_libv4l.cpp Fri May 6 08:43:02 2011
@@ -241,8 +241,7 @@ make & enjoy!
#include <sys/stat.h>
#include <sys/ioctl.h>
-#include <linux/videodev.h>
-#include <linux/videodev2.h>
+#include <sys/videoio.h>
#include <libv4l1.h>
#include <libv4l2.h>

View File

@ -0,0 +1,24 @@
$OpenBSD: patch-modules_highgui_src_cap_v4l_cpp,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- modules/highgui/src/cap_v4l.cpp.orig Sun Dec 5 04:35:25 2010
+++ modules/highgui/src/cap_v4l.cpp Fri May 6 08:52:24 2011
@@ -214,17 +214,17 @@ make & enjoy!
#include <sys/types.h>
#include <sys/mman.h>
-#include <linux/videodev.h>
+#include <sys/videoio.h>
#include <string.h>
#include <stdlib.h>
-#include <asm/types.h> /* for videodev2.h */
+#include <sys/types.h> /* for videodev2.h */
#include <assert.h>
#include <sys/stat.h>
#include <sys/ioctl.h>
#ifdef HAVE_CAMV4L2
-#include <linux/videodev2.h>
+#include <sys/videoio.h>
#endif
/* Defaults - If your board can do better, set it here. Set for the most common type inputs. */

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-modules_ml_src_gbt_cpp,v 1.1.1.1 2011/06/24 09:30:21 jasper Exp $
--- modules/ml/src/gbt.cpp.orig Sat May 14 12:36:21 2011
+++ modules/ml/src/gbt.cpp Sat May 14 12:35:56 2011
@@ -11,7 +11,7 @@
#define CV_CMP_FLOAT(a,b) ((a) < (b))
static CV_IMPLEMENT_QSORT_EX( icvSortFloat, float, CV_CMP_FLOAT, float)
-#if ANDROID
+#if defined(ANDROID) || defined(__OpenBSD__)
#define expl(x) exp(x)
#endif

View File

@ -0,0 +1 @@
Documentation for OpenCV.

View File

@ -0,0 +1,2 @@
The Open Computer Vision Library is a collection of algorithms and sample
code for various computer vision problems.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,123 @@
@comment $OpenBSD: PLIST-main,v 1.1.1.1 2011/06/24 09:30:22 jasper Exp $
@bin bin/opencv_createsamples
@bin bin/opencv_haartraining
@bin bin/opencv_performance
@bin bin/opencv_traincascade
include/opencv/
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/
include/opencv2/calib3d/
include/opencv2/calib3d/calib3d.hpp
include/opencv2/contrib/
include/opencv2/contrib/contrib.hpp
include/opencv2/core/
include/opencv2/core/core.hpp
include/opencv2/core/core_c.h
include/opencv2/core/eigen.hpp
include/opencv2/core/internal.hpp
include/opencv2/core/mat.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/
include/opencv2/features2d/features2d.hpp
include/opencv2/flann/
include/opencv2/flann/all_indices.h
include/opencv2/flann/allocator.h
include/opencv2/flann/autotuned_index.h
include/opencv2/flann/composite_index.h
include/opencv2/flann/dist.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/index_testing.h
include/opencv2/flann/kdtree_index.h
include/opencv2/flann/kmeans_index.h
include/opencv2/flann/linear_index.h
include/opencv2/flann/logger.h
include/opencv2/flann/matrix.h
include/opencv2/flann/nn_index.h
include/opencv2/flann/object_factory.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/
include/opencv2/gpu/devmem2d.hpp
include/opencv2/gpu/gpu.hpp
include/opencv2/gpu/matrix_operations.hpp
include/opencv2/gpu/stream_accessor.hpp
include/opencv2/highgui/
include/opencv2/highgui/highgui.hpp
include/opencv2/highgui/highgui_c.h
include/opencv2/imgproc/
include/opencv2/imgproc/imgproc.hpp
include/opencv2/imgproc/imgproc_c.h
include/opencv2/imgproc/types_c.h
include/opencv2/legacy/
include/opencv2/legacy/blobtrack.hpp
include/opencv2/legacy/compat.hpp
include/opencv2/legacy/legacy.hpp
include/opencv2/legacy/streams.hpp
include/opencv2/ml/
include/opencv2/ml/ml.hpp
include/opencv2/objdetect/
include/opencv2/objdetect/objdetect.hpp
include/opencv2/opencv.hpp
include/opencv2/video/
include/opencv2/video/background_segm.hpp
include/opencv2/video/tracking.hpp
@lib lib/libopencv_calib3d.so.${LIBopencv_calib3d_VERSION}
@lib lib/libopencv_contrib.so.${LIBopencv_contrib_VERSION}
@lib lib/libopencv_core.so.${LIBopencv_core_VERSION}
@lib lib/libopencv_features2d.so.${LIBopencv_features2d_VERSION}
@lib lib/libopencv_flann.so.${LIBopencv_flann_VERSION}
@lib lib/libopencv_gpu.so.${LIBopencv_gpu_VERSION}
@lib lib/libopencv_highgui.so.${LIBopencv_highgui_VERSION}
@lib lib/libopencv_imgproc.so.${LIBopencv_imgproc_VERSION}
@lib lib/libopencv_legacy.so.${LIBopencv_legacy_VERSION}
@lib lib/libopencv_ml.so.${LIBopencv_ml_VERSION}
@lib lib/libopencv_objdetect.so.${LIBopencv_objdetect_VERSION}
@lib lib/libopencv_video.so.${LIBopencv_video_VERSION}
lib/pkgconfig/opencv.pc
lib/python${MODPY_VERSION}/site-packages/cv.so
share/opencv/
share/opencv/OpenCVConfig.cmake
share/opencv/haarcascades/
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_lefteye.xml
share/opencv/haarcascades/haarcascade_mcs_mouth.xml
share/opencv/haarcascades/haarcascade_mcs_nose.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_upperbody.xml
share/opencv/lbpcascades/
share/opencv/lbpcascades/lbpcascade_frontalface.xml