diff options
Diffstat (limited to 'src/gsttools')
-rw-r--r-- | src/gsttools/gsttools.pro | 2 | ||||
-rw-r--r-- | src/gsttools/qgstreamervideoinputdevicecontrol.cpp | 5 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/gsttools/gsttools.pro b/src/gsttools/gsttools.pro index 15edd04d2..7c809a777 100644 --- a/src/gsttools/gsttools.pro +++ b/src/gsttools/gsttools.pro @@ -100,6 +100,8 @@ config_gstreamer_appsrc { LIBS_PRIVATE += -lgstapp-0.10 } +config_linux_v4l: DEFINES += USE_V4L + HEADERS += $$PRIVATE_HEADERS DESTDIR = $$QT.multimedia.libs diff --git a/src/gsttools/qgstreamervideoinputdevicecontrol.cpp b/src/gsttools/qgstreamervideoinputdevicecontrol.cpp index e4e202caf..dc008712e 100644 --- a/src/gsttools/qgstreamervideoinputdevicecontrol.cpp +++ b/src/gsttools/qgstreamervideoinputdevicecontrol.cpp @@ -45,7 +45,10 @@ #include <QtCore/QDebug> #include <private/qcore_unix_p.h> + +#if defined(USE_V4L) #include <linux/videodev2.h> +#endif QGstreamerVideoInputDeviceControl::QGstreamerVideoInputDeviceControl(QObject *parent) :QVideoDeviceSelectorControl(parent), m_source(0), m_selectedDevice(0) @@ -118,6 +121,7 @@ void QGstreamerVideoInputDeviceControl::update() return; } +#if defined(USE_V4L) QDir devDir("/dev"); devDir.setFilter(QDir::System); @@ -158,4 +162,5 @@ void QGstreamerVideoInputDeviceControl::update() } qt_safe_close(fd); } +#endif } |