mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
sys/v4l2/v4l2src_calls.c: but the corresponding ioctl() call fails even though the driver claims to support this form...
Original commit message from CVS: * sys/v4l2/v4l2src_calls.c: (gst_v4l2src_probe_caps_for_format): If VIDIOC_ENUM_FRAMESIZES is defined (= recent kernel), but the corresponding ioctl() call fails even though the driver claims to support this format, just fall back to the pre-2.6.19 kernel routine that creates caps with suitable height and width ranges (see #448278).
This commit is contained in:
parent
711afebc9f
commit
a597c1d4e3
2 changed files with 21 additions and 0 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
2007-11-13 Tim-Philipp Müller <tim at centricular dot net>
|
||||||
|
|
||||||
|
* sys/v4l2/v4l2src_calls.c: (gst_v4l2src_probe_caps_for_format):
|
||||||
|
If VIDIOC_ENUM_FRAMESIZES is defined (= recent kernel), but the
|
||||||
|
corresponding ioctl() call fails even though the driver claims to
|
||||||
|
support this format, just fall back to the pre-2.6.19 kernel
|
||||||
|
routine that creates caps with suitable height and width ranges
|
||||||
|
(see #448278).
|
||||||
|
|
||||||
2007-11-13 Tim-Philipp Müller <tim at centricular dot net>
|
2007-11-13 Tim-Philipp Müller <tim at centricular dot net>
|
||||||
|
|
||||||
Patch by: Mark Nauwelaerts <manauw skynet be>
|
Patch by: Mark Nauwelaerts <manauw skynet be>
|
||||||
|
|
|
@ -810,6 +810,9 @@ gst_v4l2src_probe_caps_for_format (GstV4l2Src * v4l2src, guint32 pixelformat,
|
||||||
results = g_list_delete_link (results, results);
|
results = g_list_delete_link (results, results);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (gst_caps_is_empty (ret))
|
||||||
|
goto enum_framesizes_no_results;
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
/* ERRORS */
|
/* ERRORS */
|
||||||
|
@ -821,6 +824,15 @@ enum_framesizes_failed:
|
||||||
" (%s)", GST_FOURCC_ARGS (pixelformat), g_strerror (errno));
|
" (%s)", GST_FOURCC_ARGS (pixelformat), g_strerror (errno));
|
||||||
goto default_frame_sizes;
|
goto default_frame_sizes;
|
||||||
}
|
}
|
||||||
|
enum_framesizes_no_results:
|
||||||
|
{
|
||||||
|
/* it's possible that VIDIOC_ENUM_FRAMESIZES is defined but the driver in
|
||||||
|
* question doesn't actually support it yet */
|
||||||
|
GST_DEBUG_OBJECT (v4l2src, "No results for pixelformat %" GST_FOURCC_FORMAT
|
||||||
|
" enumerating frame sizes, trying fallback",
|
||||||
|
GST_FOURCC_ARGS (pixelformat));
|
||||||
|
goto default_frame_sizes;
|
||||||
|
}
|
||||||
unknown_type:
|
unknown_type:
|
||||||
{
|
{
|
||||||
GST_WARNING_OBJECT (v4l2src,
|
GST_WARNING_OBJECT (v4l2src,
|
||||||
|
|
Loading…
Reference in a new issue