gst/multipart/multipartdemux.c: Fix documentation, it is not possible to control the framerate of jpegdec using filte...

Original commit message from CVS:
* gst/multipart/multipartdemux.c: (gst_multipart_demux_chain):
Fix documentation, it is not possible to control the framerate of jpegdec
using filtered caps yet. Fixes #355210.
Return the downstream GstFlowReturn instead of GST_FLOW_OK so that we
stop when there is an error.
This commit is contained in:
Wim Taymans 2006-09-15 16:01:48 +00:00
parent dcba7c77ef
commit 00256ae0a9
2 changed files with 19 additions and 4 deletions

View File

@ -1,3 +1,11 @@
2006-09-15 Wim Taymans <wim@fluendo.com>
* gst/multipart/multipartdemux.c: (gst_multipart_demux_chain):
Fix documentation, it is not possible to control the framerate of jpegdec
using filtered caps yet. Fixes #355210.
Return the downstream GstFlowReturn instead of GST_FLOW_OK so that we
stop when there is an error.
2006-09-14 Tim-Philipp Müller <tim at centricular dot net> 2006-09-14 Tim-Philipp Müller <tim at centricular dot net>
* gst/apetag/gsttagdemux.c: (gst_tag_demux_chain_parse_tag): * gst/apetag/gsttagdemux.c: (gst_tag_demux_chain_parse_tag):

View File

@ -36,9 +36,9 @@
* <title>Sample pipelines</title> * <title>Sample pipelines</title>
* <para> * <para>
* Here is a simple pipeline to demux a multipart file muxed with * Here is a simple pipeline to demux a multipart file muxed with
* #GstMultipartMux containing JPEG frames at a rate of 5 frames per second : * #GstMultipartMux containing JPEG frames:
* <programlisting> * <programlisting>
* gst-launch filesrc location=/tmp/test.multipart ! multipartdemux ! jpegdec ! video/x-raw-yuv, framerate=(fraction)5/1 ! ffmpegcolorspace ! ximagesink * gst-launch filesrc location=/tmp/test.multipart ! multipartdemux ! jpegdec ! ffmpegcolorspace ! ximagesink
* </programlisting> * </programlisting>
* </para> * </para>
* <para> * <para>
@ -477,10 +477,13 @@ gst_multipart_demux_chain (GstPad * pad, GstBuffer * buf)
GstMultipartDemux *multipart; GstMultipartDemux *multipart;
GstAdapter *adapter; GstAdapter *adapter;
gint size = 1; gint size = 1;
GstFlowReturn res;
multipart = GST_MULTIPART_DEMUX (gst_pad_get_parent (pad)); multipart = GST_MULTIPART_DEMUX (gst_pad_get_parent (pad));
adapter = multipart->adapter; adapter = multipart->adapter;
res = GST_FLOW_OK;
if (GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_DISCONT)) { if (GST_BUFFER_FLAG_IS_SET (buf, GST_BUFFER_FLAG_DISCONT)) {
gst_adapter_clear (adapter); gst_adapter_clear (adapter);
} }
@ -524,16 +527,20 @@ gst_multipart_demux_chain (GstPad * pad, GstBuffer * buf)
} else { } else {
GST_BUFFER_TIMESTAMP (outbuf) = -1; GST_BUFFER_TIMESTAMP (outbuf) = -1;
} }
gst_pad_push (srcpad->pad, outbuf); res = gst_pad_push (srcpad->pad, outbuf);
if (res != GST_FLOW_OK)
break;
} }
nodata: nodata:
gst_object_unref (multipart); gst_object_unref (multipart);
if (G_UNLIKELY (size == MULTIPART_DATA_ERROR)) if (G_UNLIKELY (size == MULTIPART_DATA_ERROR))
return GST_FLOW_ERROR; return GST_FLOW_ERROR;
if (G_UNLIKELY (size == MULTIPART_DATA_EOS)) if (G_UNLIKELY (size == MULTIPART_DATA_EOS))
return GST_FLOW_UNEXPECTED; return GST_FLOW_UNEXPECTED;
return GST_FLOW_OK;
return res;
} }
static GstStateChangeReturn static GstStateChangeReturn