rpms/gstreamer-plugins-good/devel gst-plugins-good-0.10.9-libv4l.patch, NONE, 1.1 gstreamer-plugins-good.spec, 1.67, 1.68
Adam Jackson (ajax)
fedora-extras-commits at redhat.com
Mon Aug 11 03:01:44 UTC 2008
- Previous message (by thread): rpms/olpc-netutils/F-9 olpc-netutils-0.4-preserve-timestamps.patch, NONE, 1.1 olpc-netutils.spec, NONE, 1.1 sources, 1.1, 1.2
- Next message (by thread): rpms/xorg-x11-drv-mach64/devel mach64.xinf, NONE, 1.1 xorg-x11-drv-mach64.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: ajax
Update of /cvs/pkgs/rpms/gstreamer-plugins-good/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv8738
Modified Files:
gstreamer-plugins-good.spec
Added Files:
gst-plugins-good-0.10.9-libv4l.patch
Log Message:
* Sun Aug 10 2008 Adam Jackson <ajax at redhat.com> 0.10.9-2
- gst-plugins-good-0.10.9-libv4l.patch: Use libv4l. (#456825)
- Explicitly disable esd/caca/aalib plugins so the spec builds even if you
have their devel packages installed.
gst-plugins-good-0.10.9-libv4l.patch:
--- NEW FILE gst-plugins-good-0.10.9-libv4l.patch ---
Index: configure.ac
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/configure.ac,v
retrieving revision 1.759
diff -u -p -u -p -r1.759 configure.ac
--- configure.ac 28 Jul 2008 20:17:46 -0000 1.759
+++ configure.ac 30 Jul 2008 10:23:39 -0000
@@ -550,6 +550,12 @@ return 0;
fi
])
+if test x$HAVE_GST_V4L2 = xyes; then
+ PKG_CHECK_MODULES(LIBV4L2, libv4l2, [have_libv4l2=yes], [have_libv4l2=no])
+ AC_DEFINE([HAVE_LIBV4L2], test x$have_libv4l2 = xyes,
+ [Whether libv4l2 is available for video buffer conversion])
+fi
+
dnl Check for X11
translit(dnm, m, l) AM_CONDITIONAL(USE_X, true)
AG_GST_CHECK_FEATURE(X, [X libraries and plugins],
Index: sys/v4l2/Makefile.am
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/sys/v4l2/Makefile.am,v
retrieving revision 1.18
diff -u -p -u -p -r1.18 Makefile.am
--- sys/v4l2/Makefile.am 1 Nov 2006 19:48:26 -0000 1.18
+++ sys/v4l2/Makefile.am 30 Jul 2008 10:23:40 -0000
@@ -22,15 +22,17 @@ libgstvideo4linux2_la_SOURCES = gstv4l2.
libgstvideo4linux2_la_CFLAGS = $(GST_PLUGINS_BASE_CFLAGS) \
$(GST_BASE_CFLAGS) \
$(GST_CFLAGS) \
- $(X_CFLAGS)
-
+ $(X_CFLAGS) \
+ $(LIBV4L2_CFLAGS)
+
libgstvideo4linux2_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
libgstvideo4linux2_la_LIBADD = $(GST_PLUGINS_BASE_LIBS) \
$(GST_BASE_LIBS) \
-lgstinterfaces-$(GST_MAJORMINOR) \
$(GST_LIBS) \
- $(xv_libs)
+ $(xv_libs) \
+ $(LIBV4L2_LIBS)
noinst_HEADERS = gstv4l2object.h v4l2_calls.h \
gstv4l2src.h v4l2src_calls.h \
Index: sys/v4l2/gstv4l2src.c
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/sys/v4l2/gstv4l2src.c,v
retrieving revision 1.96
diff -u -p -u -p -r1.96 gstv4l2src.c
--- sys/v4l2/gstv4l2src.c 17 Jul 2008 13:54:38 -0000 1.96
+++ sys/v4l2/gstv4l2src.c 30 Jul 2008 10:23:40 -0000
@@ -1162,7 +1162,7 @@ gst_v4l2src_get_read (GstV4l2Src * v4l2s
do {
amount =
- read (v4l2src->v4l2object->video_fd, GST_BUFFER_DATA (*buf),
+ v4l2_read (v4l2src->v4l2object->video_fd, GST_BUFFER_DATA (*buf),
buffersize);
if (amount == buffersize) {
break;
Index: sys/v4l2/v4l2_calls.c
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/sys/v4l2/v4l2_calls.c,v
retrieving revision 1.46
diff -u -p -u -p -r1.46 v4l2_calls.c
--- sys/v4l2/v4l2_calls.c 26 Jun 2008 16:36:47 -0000 1.46
+++ sys/v4l2/v4l2_calls.c 30 Jul 2008 10:23:40 -0000
@@ -75,7 +75,7 @@ gst_v4l2_get_capabilities (GstV4l2Object
if (!GST_V4L2_IS_OPEN (v4l2object))
return FALSE;
- if (ioctl (v4l2object->video_fd, VIDIOC_QUERYCAP, &v4l2object->vcap) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_QUERYCAP, &v4l2object->vcap) < 0)
goto cap_failed;
GST_LOG_OBJECT (e, "driver: '%s'", v4l2object->vcap.driver);
@@ -124,7 +124,7 @@ gst_v4l2_fill_lists (GstV4l2Object * v4l
GstTunerChannel *channel;
input.index = n;
- if (ioctl (v4l2object->video_fd, VIDIOC_ENUMINPUT, &input) < 0) {
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_ENUMINPUT, &input) < 0) {
if (errno == EINVAL)
break; /* end of enumeration */
else {
@@ -157,7 +157,7 @@ gst_v4l2_fill_lists (GstV4l2Object * v4l
channel->flags |= GST_TUNER_CHANNEL_FREQUENCY;
vtun.index = input.tuner;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_TUNER, &vtun) < 0) {
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_TUNER, &vtun) < 0) {
GST_ELEMENT_ERROR (e, RESOURCE, SETTINGS,
(_("Failed to get setting of tuner %d on device '%s'."),
input.tuner, v4l2object->videodev), GST_ERROR_SYSTEM);
@@ -197,7 +197,7 @@ gst_v4l2_fill_lists (GstV4l2Object * v4l
standard.frameperiod.denominator = 0;
standard.index = n;
- if (ioctl (v4l2object->video_fd, VIDIOC_ENUMSTD, &standard) < 0) {
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_ENUMSTD, &standard) < 0) {
if (errno == EINVAL || errno == ENOTTY)
break; /* end of enumeration */
else {
@@ -242,7 +242,7 @@ gst_v4l2_fill_lists (GstV4l2Object * v4l
}
control.id = n;
- if (ioctl (v4l2object->video_fd, VIDIOC_QUERYCTRL, &control) < 0) {
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_QUERYCTRL, &control) < 0) {
if (errno == EINVAL) {
if (n < V4L2_CID_PRIVATE_BASE)
/* continue so that we also check private controls */
@@ -323,7 +323,7 @@ gst_v4l2_fill_lists (GstV4l2Object * v4l
menu.id = n;
for (i = 0;; i++) {
menu.index = i;
- if (ioctl (v4l2object->video_fd, VIDIOC_QUERYMENU, &menu) < 0) {
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_QUERYMENU, &menu) < 0) {
if (errno == EINVAL)
break; /* end of enumeration */
else {
@@ -398,6 +398,7 @@ gboolean
gst_v4l2_open (GstV4l2Object * v4l2object)
{
struct stat st;
+ int libv4l2_fd;
GST_DEBUG_OBJECT (v4l2object->element, "Trying to open device %s",
v4l2object->videodev);
@@ -423,6 +424,17 @@ gst_v4l2_open (GstV4l2Object * v4l2objec
if (!GST_V4L2_IS_OPEN (v4l2object))
goto not_open;
+ libv4l2_fd = v4l2_fd_open(v4l2object->video_fd,
+ V4L2_ENABLE_ENUM_FMT_EMULATION);
+ /* Note the v4l2_xxx functions are designed so that if they get passed an
+ unknown fd, the will behave exactly as their regular xxx counterparts, so
+ if v4l2_fd_open fails, we continue as normal (missing the libv4l2 custom
+ cam format to normal formats conversion). Chances are big we will still
+ fail then though, as normally v4l2_fd_open only fails if the device is not
+ a v4l2 device. */
+ if (libv4l2_fd != -1)
+ v4l2object->video_fd = libv4l2_fd;
+
/* get capabilities, error will be posted */
if (!gst_v4l2_get_capabilities (v4l2object))
goto error;
@@ -476,7 +488,7 @@ error:
{
if (GST_V4L2_IS_OPEN (v4l2object)) {
/* close device */
- close (v4l2object->video_fd);
+ v4l2_close (v4l2object->video_fd);
v4l2object->video_fd = -1;
}
/* empty lists */
@@ -502,7 +514,7 @@ gst_v4l2_close (GstV4l2Object * v4l2obje
GST_V4L2_CHECK_NOT_ACTIVE (v4l2object);
/* close device */
- close (v4l2object->video_fd);
+ v4l2_close (v4l2object->video_fd);
v4l2object->video_fd = -1;
/* empty lists */
@@ -525,7 +537,7 @@ gst_v4l2_get_norm (GstV4l2Object * v4l2o
if (!GST_V4L2_IS_OPEN (v4l2object))
return FALSE;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_STD, norm) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_STD, norm) < 0)
goto std_failed;
return TRUE;
@@ -553,7 +565,7 @@ gst_v4l2_set_norm (GstV4l2Object * v4l2o
if (!GST_V4L2_IS_OPEN (v4l2object))
return FALSE;
- if (ioctl (v4l2object->video_fd, VIDIOC_S_STD, &norm) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_S_STD, &norm) < 0)
goto std_failed;
return TRUE;
@@ -589,7 +601,7 @@ gst_v4l2_get_frequency (GstV4l2Object *
channel = gst_tuner_get_channel (GST_TUNER (v4l2object->element));
freq.tuner = tunernum;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_FREQUENCY, &freq) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_FREQUENCY, &freq) < 0)
goto freq_failed;
*frequency = freq.frequency * channel->freq_multiplicator;
@@ -630,10 +642,10 @@ gst_v4l2_set_frequency (GstV4l2Object *
freq.tuner = tunernum;
/* fill in type - ignore error */
- ioctl (v4l2object->video_fd, VIDIOC_G_FREQUENCY, &freq);
+ v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_FREQUENCY, &freq);
freq.frequency = frequency / channel->freq_multiplicator;
- if (ioctl (v4l2object->video_fd, VIDIOC_S_FREQUENCY, &freq) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_S_FREQUENCY, &freq) < 0)
goto freq_failed;
return TRUE;
@@ -665,7 +677,7 @@ gst_v4l2_signal_strength (GstV4l2Object
return FALSE;
tuner.index = tunernum;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_TUNER, &tuner) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_TUNER, &tuner) < 0)
goto tuner_failed;
*signal_strength = tuner.signal;
@@ -701,7 +713,7 @@ gst_v4l2_get_attribute (GstV4l2Object *
control.id = attribute_num;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_CTRL, &control) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_CTRL, &control) < 0)
goto ctrl_failed;
*value = control.value;
@@ -738,7 +750,7 @@ gst_v4l2_set_attribute (GstV4l2Object *
control.id = attribute_num;
control.value = value;
- if (ioctl (v4l2object->video_fd, VIDIOC_S_CTRL, &control) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_S_CTRL, &control) < 0)
goto ctrl_failed;
return TRUE;
@@ -763,7 +775,7 @@ gst_v4l2_get_input (GstV4l2Object * v4l2
if (!GST_V4L2_IS_OPEN (v4l2object))
return FALSE;
- if (ioctl (v4l2object->video_fd, VIDIOC_G_INPUT, &n) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_G_INPUT, &n) < 0)
goto input_failed;
*input = n;
@@ -789,7 +801,7 @@ gst_v4l2_set_input (GstV4l2Object * v4l2
if (!GST_V4L2_IS_OPEN (v4l2object))
return FALSE;
- if (ioctl (v4l2object->video_fd, VIDIOC_S_INPUT, &input) < 0)
+ if (v4l2_ioctl (v4l2object->video_fd, VIDIOC_S_INPUT, &input) < 0)
goto input_failed;
return TRUE;
Index: sys/v4l2/v4l2_calls.h
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/sys/v4l2/v4l2_calls.h,v
retrieving revision 1.18
diff -u -p -u -p -r1.18 v4l2_calls.h
--- sys/v4l2/v4l2_calls.h 26 Sep 2006 13:18:06 -0000 1.18
+++ sys/v4l2/v4l2_calls.h 30 Jul 2008 10:23:40 -0000
@@ -27,6 +27,17 @@
#include "gstv4l2object.h"
#include "gst/gst-i18n-plugin.h"
+#ifdef HAVE_LIBV4L2
+#include <libv4l2.h>
+#else
+#define v4l2_fd_open(fd, flags) (fd)
+#define v4l2_close close
+#define v4l2_dup dup
+#define v4l2_ioctl ioctl
+#define v4l2_read read
+#define v4l2_mmap mmap
+#define v4l2_munmap munmap
+#endif
/* simple check whether the device is open */
#define GST_V4L2_IS_OPEN(v4l2object) \
Index: sys/v4l2/v4l2src_calls.c
===================================================================
RCS file: /cvs/gstreamer/gst-plugins-good/sys/v4l2/v4l2src_calls.c,v
retrieving revision 1.84
diff -u -p -u -p -r1.84 v4l2src_calls.c
--- sys/v4l2/v4l2src_calls.c 8 Jul 2008 12:51:33 -0000 1.84
+++ sys/v4l2/v4l2src_calls.c 30 Jul 2008 10:23:40 -0000
@@ -87,7 +87,7 @@ gst_v4l2_buffer_finalize (GstV4l2Buffer
pool->num_live_buffers--;
if (pool->running) {
- if (ioctl (pool->video_fd, VIDIOC_QBUF, &buffer->vbuffer) < 0) {
+ if (v4l2_ioctl (pool->video_fd, VIDIOC_QBUF, &buffer->vbuffer) < 0) {
GST_WARNING ("could not requeue buffer %p %d", buffer, index);
} else {
/* FIXME: check that the caps didn't change */
@@ -105,7 +105,7 @@ gst_v4l2_buffer_finalize (GstV4l2Buffer
if (!resuscitated) {
GST_LOG ("buffer %p not recovered, unmapping", buffer);
gst_mini_object_unref (GST_MINI_OBJECT (pool));
- munmap ((void *) GST_BUFFER_DATA (buffer), buffer->vbuffer.length);
+ v4l2_munmap ((void *) GST_BUFFER_DATA (buffer), buffer->vbuffer.length);
GST_MINI_OBJECT_CLASS (v4l2buffer_parent_class)->finalize (GST_MINI_OBJECT
(buffer));
@@ -171,7 +171,7 @@ gst_v4l2_buffer_new (GstV4l2BufferPool *
ret->vbuffer.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
ret->vbuffer.memory = V4L2_MEMORY_MMAP;
- if (ioctl (pool->video_fd, VIDIOC_QUERYBUF, &ret->vbuffer) < 0)
+ if (v4l2_ioctl (pool->video_fd, VIDIOC_QUERYBUF, &ret->vbuffer) < 0)
goto querybuf_failed;
GST_LOG (" index: %u", ret->vbuffer.index);
@@ -185,7 +185,7 @@ gst_v4l2_buffer_new (GstV4l2BufferPool *
GST_LOG (" length: %u", ret->vbuffer.length);
GST_LOG (" input: %u", ret->vbuffer.input);
- data = (guint8 *) mmap (0, ret->vbuffer.length,
+ data = (guint8 *) v4l2_mmap (0, ret->vbuffer.length,
PROT_READ | PROT_WRITE, MAP_SHARED, pool->video_fd,
ret->vbuffer.m.offset);
@@ -235,7 +235,7 @@ gst_v4l2_buffer_pool_finalize (GstV4l2Bu
pool->lock = NULL;
if (pool->video_fd >= 0)
- close (pool->video_fd);
+ v4l2_close (pool->video_fd);
if (pool->buffers)
g_free (pool->buffers);
@@ -296,7 +296,7 @@ gst_v4l2_buffer_pool_new (GstV4l2Src * v
pool = (GstV4l2BufferPool *) gst_mini_object_new (GST_TYPE_V4L2_BUFFER_POOL);
- pool->video_fd = dup (fd);
+ pool->video_fd = v4l2_dup (fd);
if (pool->video_fd < 0)
goto dup_failed;
@@ -348,7 +348,7 @@ gst_v4l2_buffer_pool_activate (GstV4l2Bu
GST_LOG ("enqueue pool buffer %d", n);
- if (ioctl (pool->video_fd, VIDIOC_QBUF, buf) < 0)
+ if (v4l2_ioctl (pool->video_fd, VIDIOC_QBUF, buf) < 0)
goto queue_failed;
}
pool->running = TRUE;
@@ -509,7 +509,7 @@ gst_v4l2src_fill_format_list (GstV4l2Src
format->index = n;
format->type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
- if (ioctl (v4l2src->v4l2object->video_fd, VIDIOC_ENUM_FMT, format) < 0) {
+ if (v4l2_ioctl (v4l2src->v4l2object->video_fd, VIDIOC_ENUM_FMT, format) < 0) {
if (errno == EINVAL) {
g_free (format);
break; /* end of enumeration */
@@ -585,7 +585,7 @@ gst_v4l2src_probe_caps_for_format_and_si
/* keep in mind that v4l2 gives us frame intervals (durations); we invert the
* fraction to get framerate */
- if (ioctl (fd, VIDIOC_ENUM_FRAMEINTERVALS, &ival) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_ENUM_FRAMEINTERVALS, &ival) < 0)
goto enum_frameintervals_failed;
if (ival.type == V4L2_FRMIVAL_TYPE_DISCRETE) {
@@ -611,7 +611,7 @@ gst_v4l2src_probe_caps_for_format_and_si
gst_value_list_append_value (&rates, &rate);
ival.index++;
- } while (ioctl (fd, VIDIOC_ENUM_FRAMEINTERVALS, &ival) >= 0);
+ } while (v4l2_ioctl (fd, VIDIOC_ENUM_FRAMEINTERVALS, &ival) >= 0);
} else if (ival.type == V4L2_FRMIVAL_TYPE_STEPWISE) {
GValue min = { 0, };
GValue step = { 0, };
@@ -770,7 +770,7 @@ gst_v4l2src_probe_caps_for_format (GstV4
size.index = 0;
size.pixel_format = pixelformat;
- if (ioctl (fd, VIDIOC_ENUM_FRAMESIZES, &size) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_ENUM_FRAMESIZES, &size) < 0)
goto enum_framesizes_failed;
if (size.type == V4L2_FRMSIZE_TYPE_DISCRETE) {
@@ -787,7 +787,7 @@ gst_v4l2src_probe_caps_for_format (GstV4
results = g_list_prepend (results, tmp);
size.index++;
- } while (ioctl (fd, VIDIOC_ENUM_FRAMESIZES, &size) >= 0);
+ } while (v4l2_ioctl (fd, VIDIOC_ENUM_FRAMESIZES, &size) >= 0);
} else if (size.type == V4L2_FRMSIZE_TYPE_STEPWISE) {
for (w = size.stepwise.min_width, h = size.stepwise.min_height;
w < size.stepwise.max_width && h < size.stepwise.max_height;
@@ -940,7 +940,7 @@ gst_v4l2src_grab_frame (GstV4l2Src * v4l
buffer.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
buffer.memory = V4L2_MEMORY_MMAP;
- while (ioctl (v4l2src->v4l2object->video_fd, VIDIOC_DQBUF, &buffer) < 0) {
+ while (v4l2_ioctl (v4l2src->v4l2object->video_fd, VIDIOC_DQBUF, &buffer) < 0) {
GST_WARNING_OBJECT (v4l2src,
"problem grabbing frame %d (ix=%d), trials=%d, pool-ct=%d, buf.flags=%d",
@@ -1167,7 +1167,7 @@ gst_v4l2src_set_capture (GstV4l2Src * v4
memset (&format, 0x00, sizeof (struct v4l2_format));
format.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
- if (ioctl (fd, VIDIOC_G_FMT, &format) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_G_FMT, &format) < 0)
goto get_fmt_failed;
format.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
@@ -1179,7 +1179,7 @@ gst_v4l2src_set_capture (GstV4l2Src * v4
* combined, there are other modes for requesting fields individually) */
format.fmt.pix.field = V4L2_FIELD_INTERLACED;
- if (ioctl (fd, VIDIOC_S_FMT, &format) < 0) {
+ if (v4l2_ioctl (fd, VIDIOC_S_FMT, &format) < 0) {
if (errno != EINVAL)
goto set_fmt_failed;
@@ -1188,7 +1188,7 @@ gst_v4l2src_set_capture (GstV4l2Src * v4
format.fmt.pix.height = height;
format.fmt.pix.pixelformat = pixelformat;
format.fmt.pix.field = V4L2_FIELD_NONE;
- if (ioctl (fd, VIDIOC_S_FMT, &format) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_S_FMT, &format) < 0)
goto set_fmt_failed;
}
@@ -1203,7 +1203,7 @@ gst_v4l2src_set_capture (GstV4l2Src * v4
memset (&stream, 0x00, sizeof (struct v4l2_streamparm));
stream.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
- if (ioctl (fd, VIDIOC_G_PARM, &stream) < 0) {
+ if (v4l2_ioctl (fd, VIDIOC_G_PARM, &stream) < 0) {
GST_ELEMENT_WARNING (v4l2src, RESOURCE, SETTINGS,
(_("Could not get parameters on device '%s'"),
v4l2src->v4l2object->videodev), GST_ERROR_SYSTEM);
@@ -1231,7 +1231,7 @@ gst_v4l2src_set_capture (GstV4l2Src * v4
stream.parm.capture.timeperframe.denominator = fps_n;
/* some cheap USB cam's won't accept any change */
- if (ioctl (fd, VIDIOC_S_PARM, &stream) < 0) {
+ if (v4l2_ioctl (fd, VIDIOC_S_PARM, &stream) < 0) {
GST_ELEMENT_WARNING (v4l2src, RESOURCE, SETTINGS,
(_("Video input device did not accept new frame rate setting.")),
GST_ERROR_SYSTEM);
@@ -1313,7 +1313,7 @@ gst_v4l2src_capture_init (GstV4l2Src * v
breq.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
breq.memory = V4L2_MEMORY_MMAP;
- if (ioctl (fd, VIDIOC_REQBUFS, &breq) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_REQBUFS, &breq) < 0)
goto reqbufs_failed;
GST_LOG_OBJECT (v4l2src, " count: %u", breq.count);
@@ -1408,7 +1408,7 @@ gst_v4l2src_capture_start (GstV4l2Src *
if (!gst_v4l2_buffer_pool_activate (v4l2src->pool, v4l2src))
goto pool_activate_failed;
- if (ioctl (fd, VIDIOC_STREAMON, &type) < 0)
+ if (v4l2_ioctl (fd, VIDIOC_STREAMON, &type) < 0)
goto streamon_failed;
}
@@ -1453,7 +1453,7 @@ gst_v4l2src_capture_stop (GstV4l2Src * v
if (v4l2src->use_mmap) {
/* we actually need to sync on all queued buffers but not
* on the non-queued ones */
- if (ioctl (v4l2src->v4l2object->video_fd, VIDIOC_STREAMOFF, &type) < 0)
+ if (v4l2_ioctl (v4l2src->v4l2object->video_fd, VIDIOC_STREAMOFF, &type) < 0)
goto streamoff_failed;
}
@@ -1529,14 +1529,14 @@ gst_v4l2src_get_nearest_size (GstV4l2Src
fmt.fmt.pix.pixelformat = pixelformat;
fmt.fmt.pix.field = V4L2_FIELD_INTERLACED;
- r = ioctl (fd, VIDIOC_TRY_FMT, &fmt);
+ r = v4l2_ioctl (fd, VIDIOC_TRY_FMT, &fmt);
if (r < 0 && errno == EINVAL) {
/* try again with progressive video */
fmt.fmt.pix.width = *width;
fmt.fmt.pix.height = *height;
fmt.fmt.pix.pixelformat = pixelformat;
fmt.fmt.pix.field = V4L2_FIELD_NONE;
- r = ioctl (fd, VIDIOC_TRY_FMT, &fmt);
+ r = v4l2_ioctl (fd, VIDIOC_TRY_FMT, &fmt);
}
if (r < 0) {
@@ -1556,14 +1556,14 @@ gst_v4l2src_get_nearest_size (GstV4l2Src
fmt.fmt.pix.width = *width;
fmt.fmt.pix.height = *height;
- r = ioctl (fd, VIDIOC_S_FMT, &fmt);
+ r = v4l2_ioctl (fd, VIDIOC_S_FMT, &fmt);
if (r < 0 && errno == EINVAL) {
/* try again with progressive video */
fmt.fmt.pix.width = *width;
fmt.fmt.pix.height = *height;
fmt.fmt.pix.pixelformat = pixelformat;
fmt.fmt.pix.field = V4L2_FIELD_NONE;
- r = ioctl (fd, VIDIOC_S_FMT, &fmt);
+ r = v4l2_ioctl (fd, VIDIOC_S_FMT, &fmt);
}
if (r < 0)
Index: gstreamer-plugins-good.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gstreamer-plugins-good/devel/gstreamer-plugins-good.spec,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -r1.67 -r1.68
--- gstreamer-plugins-good.spec 6 Aug 2008 16:10:19 -0000 1.67
+++ gstreamer-plugins-good.spec 11 Aug 2008 03:01:13 -0000 1.68
@@ -6,7 +6,7 @@
Name: %{gstreamer}-plugins-good
Version: 0.10.9
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: GStreamer plug-ins with good code and licensing
Group: Applications/Multimedia
@@ -15,6 +15,8 @@
Source: http://gstreamer.freedesktop.org/src/gst-plugins-good/gst-plugins-good-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+Patch0: gst-plugins-good-0.10.9-libv4l.patch
+
Requires: %{gstreamer} >= %{_gst}
Requires(pre): GConf2
Requires(preun): GConf2
@@ -54,6 +56,7 @@
BuildRequires: libraw1394-devel
BuildRequires: libavc1394-devel
BuildRequires: libiec61883-devel
+BuildRequires: libv2l-devel
%endif
# documentation
@@ -93,6 +96,7 @@
%prep
%setup -q -n gst-plugins-good-%{version}
+%patch -p0 -b .libv4l
%build
@@ -102,6 +106,7 @@
--enable-gtk-doc \
--enable-experimental \
--enable-ladspa \
+ --disable-esd --disable-libcaca --disable-aalib \
--with-default-visualizer=autoaudiosink
make %{?_smp_mflags}
@@ -236,6 +241,11 @@
gconftool-2 --makefile-install-rule %{_sysconfdir}/gconf/schemas/gstreamer-%{majorminor}.schemas > /dev/null || :
%changelog
+* Sun Aug 10 2008 Adam Jackson <ajax at redhat.com> 0.10.9-2
+- gst-plugins-good-0.10.9-libv4l.patch: Use libv4l. (#456825)
+- Explicitly disable esd/caca/aalib plugins so the spec builds even if you
+ have their devel packages installed.
+
* Mon Aug 04 2008 Adam Jackson <ajax at redhat.com> 0.10.9-1
- Update to 0.10.9
- Previous message (by thread): rpms/olpc-netutils/F-9 olpc-netutils-0.4-preserve-timestamps.patch, NONE, 1.1 olpc-netutils.spec, NONE, 1.1 sources, 1.1, 1.2
- Next message (by thread): rpms/xorg-x11-drv-mach64/devel mach64.xinf, NONE, 1.1 xorg-x11-drv-mach64.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list