mirror of
https://github.com/opencv/opencv.git
synced 2026-07-30 15:53:03 +04:00
Merge pull request #13126 from mshabunin:remove_libv4l
This commit is contained in:
@@ -105,9 +105,7 @@ if(HAVE_GSTREAMER)
|
||||
list(APPEND videoio_srcs ${CMAKE_CURRENT_LIST_DIR}/src/cap_gstreamer.cpp)
|
||||
endif(HAVE_GSTREAMER)
|
||||
|
||||
if(HAVE_LIBV4L)
|
||||
list(APPEND videoio_srcs ${CMAKE_CURRENT_LIST_DIR}/src/cap_libv4l.cpp)
|
||||
elseif(HAVE_CAMV4L2 OR HAVE_VIDEOIO)
|
||||
if(HAVE_CAMV4L2 OR HAVE_VIDEOIO)
|
||||
list(APPEND videoio_srcs ${CMAKE_CURRENT_LIST_DIR}/src/cap_v4l.cpp)
|
||||
endif()
|
||||
|
||||
|
||||
@@ -89,7 +89,7 @@ See @ref videoio_overview for more information.
|
||||
enum VideoCaptureAPIs {
|
||||
CAP_ANY = 0, //!< Auto detect == 0
|
||||
CAP_VFW = 200, //!< Video For Windows (obsolete, removed)
|
||||
CAP_V4L = 200, //!< V4L/V4L2 capturing support via libv4l
|
||||
CAP_V4L = 200, //!< V4L/V4L2 capturing support
|
||||
CAP_V4L2 = CAP_V4L, //!< Same as CAP_V4L
|
||||
CAP_FIREWIRE = 300, //!< IEEE 1394 drivers
|
||||
CAP_FIREWARE = CAP_FIREWIRE, //!< Same value as CAP_FIREWIRE
|
||||
|
||||
@@ -28,7 +28,7 @@ Install dc1394 raw1394 - coriander should work with your camera
|
||||
The build is controlled by the following entries in the videoio Makefile:
|
||||
|
||||
libvideoio_la_LIBADD = -L/usr/X11R6/lib -lXm -lMrm -lUil -lpng -ljpeg -lz -ltiff -lavcodec -lraw1394 -ldc1394_control
|
||||
DEFS = -DHAVE_CONFIG_H -DHAVE_DC1394 HAVE_CAMV4L
|
||||
DEFS = -DHAVE_CONFIG_H -DHAVE_DC1394
|
||||
|
||||
|
||||
Now it should be possible to use videoio camera functions, works for me.
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -82,8 +82,8 @@ static const struct VideoBackendInfo builtin_backends[] =
|
||||
// Linux, some Unix
|
||||
#if defined HAVE_CAMV4L2
|
||||
DECLARE_BACKEND(CAP_V4L2, "V4L2", MODE_CAPTURE_ALL),
|
||||
#elif defined HAVE_LIBV4L || defined HAVE_CAMV4L
|
||||
DECLARE_BACKEND(CAP_V4L, "V4L", MODE_CAPTURE_ALL),
|
||||
#elif defined HAVE_VIDEOIO
|
||||
DECLARE_BACKEND(CAP_V4L, "V4L_BSD", MODE_CAPTURE_ALL),
|
||||
#endif
|
||||
|
||||
|
||||
@@ -433,6 +433,11 @@ void VideoCapture_create(CvCapture*& capture, Ptr<IVideoCapture>& icap, VideoCap
|
||||
case CAP_GPHOTO2:
|
||||
TRY_OPEN(createGPhoto2Capture(index));
|
||||
break;
|
||||
#endif
|
||||
#if defined HAVE_CAMV4L2 || defined HAVE_VIDEOIO
|
||||
case CAP_V4L:
|
||||
TRY_OPEN_LEGACY(cvCreateCameraCapture_V4L(index))
|
||||
break;
|
||||
#endif
|
||||
case CAP_FIREWIRE:
|
||||
#ifdef HAVE_DC1394_2
|
||||
@@ -493,7 +498,7 @@ void VideoCapture_create(CvCapture*& capture, Ptr<IVideoCapture>& icap, VideoCap
|
||||
default:
|
||||
CV_LOG_WARNING(NULL, "VideoCapture(filename=" << filename << ") was built without support of requested backendID=" << (int)api);
|
||||
break;
|
||||
#if defined HAVE_LIBV4L || defined HAVE_CAMV4L || defined HAVE_CAMV4L2 || defined HAVE_VIDEOIO
|
||||
#if defined HAVE_CAMV4L2 || defined HAVE_VIDEOIO
|
||||
case CAP_V4L:
|
||||
TRY_OPEN_LEGACY(cvCreateCameraCapture_V4L(filename.c_str()))
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user