From 63693a682a2b6412a78da59a2f486d1459ee2843 Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Sat, 13 Jan 2007 10:33:41 +0000 Subject: [PATCH] gst/gstpad.c (gst_pad_get_range, gst_pad_pull_range): Allow getrange() to return buffers with other caps, while we fi... Original commit message from CVS: 2007-01-13 Andy Wingo * gst/gstpad.c (gst_pad_get_range, gst_pad_pull_range): Allow getrange() to return buffers with other caps, while we fix demuxers and typefind, or otherwise change part-negotiation.txt. --- ChangeLog | 6 ++++++ gst/gstpad.c | 20 ++++++++++++++++++++ 2 files changed, 26 insertions(+) diff --git a/ChangeLog b/ChangeLog index 0f14d77..b616864 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-01-13 Andy Wingo + + * gst/gstpad.c (gst_pad_get_range, gst_pad_pull_range): Allow + getrange() to return buffers with other caps, while we fix + demuxers and typefind, or otherwise change part-negotiation.txt. + 2007-01-12 Andy Wingo * libs/gst/base/gstbasetransform.c (gst_base_transform_activate): diff --git a/gst/gstpad.c b/gst/gstpad.c index 1db9f60..ae6333c 100644 --- a/gst/gstpad.c +++ b/gst/gstpad.c @@ -3793,11 +3793,21 @@ dropping: } not_negotiated: { + /* ideally we want to use the commented-out code, but currently demuxers and + * typefind do not follow part-negotiation.txt. When switching into pull + * mode, typefind should probably return the found caps from getcaps(), and + * demuxers should do the setcaps(). */ + +#if 0 gst_buffer_unref (*buffer); *buffer = NULL; GST_CAT_WARNING_OBJECT (GST_CAT_SCHEDULING, pad, "getrange returned buffer of different caps"); return GST_FLOW_NOT_NEGOTIATED; +#endif + GST_CAT_DEBUG_OBJECT (GST_CAT_SCHEDULING, pad, + "getrange returned buffer of different caps"); + return ret; } } @@ -3904,11 +3914,21 @@ dropping: } not_negotiated: { + /* ideally we want to use the commented-out code, but currently demuxers and + * typefind do not follow part-negotiation.txt. When switching into pull + * mode, typefind should probably return the found caps from getcaps(), and + * demuxers should do the setcaps(). */ + +#if 0 gst_buffer_unref (*buffer); *buffer = NULL; GST_CAT_WARNING_OBJECT (GST_CAT_SCHEDULING, pad, "pullrange returned buffer of different caps"); return GST_FLOW_NOT_NEGOTIATED; +#endif + GST_CAT_DEBUG_OBJECT (GST_CAT_SCHEDULING, pad, + "pullrange returned buffer of different caps"); + return ret; } } -- 2.7.4