mirror of
https://git.FreeBSD.org/ports.git
synced 2024-12-21 04:06:46 +00:00
gstreamer1-plugins-v4l2: fix for (some) webcams
The gstreamer v4l2 plugin probes the DMA capabilities of the webcam device via ioctl VIDIOC_EXPBUF, expecting ENOTTY in case that's not implemented (and will act accordingly). On our cuse, we get EINVAL for that case (which, from my reading of ioctl(2) woulndn't be correct here), which gstreamer neither expects nor handles and thus cannot use this device as a video source. As we cannot fix the kernel on short notice (cuse is part of the base system), the workaround is to handle EINVAL like ENOTTY in this specific place. (Tested with an old Logitech camera). PR: 236673 Approved by: maintainer-timeout (multimedia)
This commit is contained in:
parent
be76faf785
commit
fd80676dbd
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=534176
@ -0,0 +1,13 @@
|
||||
--- sys/v4l2/gstv4l2object.c.orig 2020-04-06 14:45:19 UTC
|
||||
+++ sys/v4l2/gstv4l2object.c
|
||||
@@ -2891,8 +2891,9 @@ gst_v4l2_object_is_dmabuf_supported (GstV4l2Object * v
|
||||
}
|
||||
|
||||
/* Expected to fail, but ENOTTY tells us that it is not implemented. */
|
||||
+ /* FreeBSD cuse sends EINVAL? */
|
||||
v4l2object->ioctl (v4l2object->video_fd, VIDIOC_EXPBUF, &expbuf);
|
||||
- if (errno == ENOTTY)
|
||||
+ if (errno == ENOTTY || errno == EINVAL)
|
||||
ret = FALSE;
|
||||
|
||||
return ret;
|
@ -1,6 +1,6 @@
|
||||
# $FreeBSD$
|
||||
|
||||
PORTREVISION= 0
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= multimedia
|
||||
PKGNAMESUFFIX= 1-plugins-v4l2
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user