2006-02-06 Tim-Philipp Müller <tim at centricular dot net>
+ * ext/dv/gstdvdemux.c: (gst_dvdemux_src_query),
+ (gst_dvdemux_sink_query):
+ * ext/flac/gstflacdec.c: (gst_flac_dec_src_query):
+ * ext/speex/gstspeexdec.c: (speex_get_query_types),
+ (speex_dec_src_query):
+ * ext/speex/gstspeexenc.c: (gst_speexenc_src_query),
+ (gst_speexenc_sink_query):
+ * gst/avi/gstavidemux.c: (gst_avi_demux_handle_src_query):
+ * gst/matroska/matroska-demux.c:
+ (gst_matroska_demux_get_src_query_types),
+ (gst_matroska_demux_handle_src_query):
+ * gst/wavparse/gstwavparse.c: (gst_wavparse_get_query_types),
+ (gst_wavparse_pad_query):
+ Pass unhandled queries upstream instead of just dropping
+ them (#326446). Update query type arrays here and there.
+
+2006-02-06 Tim-Philipp Müller <tim at centricular dot net>
+
* tests/check/elements/matroskamux.c: (setup_src_pad):
Collectpads in core got changed and now also holds a
reference to any pad that is part of it. Fix refcount
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
gst_object_unref (dvdemux);
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
gst_object_unref (dvdemux);
}
default:{
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
}
{
static const GstQueryType speex_dec_src_query_types[] = {
GST_QUERY_POSITION,
+ GST_QUERY_DURATION,
0
};
speex_dec_src_query (GstPad * pad, GstQuery * query)
{
GstSpeexDec *dec = GST_SPEEXDEC (GST_OBJECT_PARENT (pad));
+ gboolean res = FALSE;
switch (GST_QUERY_TYPE (query)) {
case GST_QUERY_POSITION:
gst_query_parse_position (query, &format, NULL);
- speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT, dec->samples_out,
- &format, &cur);
-
- gst_query_set_position (query, format, cur);
+ if ((res = speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT,
+ dec->samples_out, &format, &cur))) {
+ gst_query_set_position (query, format, cur);
+ }
break;
}
case GST_QUERY_DURATION:
gint64 total_samples;
if (!(peer = gst_pad_get_peer (dec->sinkpad)))
- return FALSE;
+ break;
gst_pad_query_duration (peer, &my_format, &total_samples);
gst_object_unref (peer);
- speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT, total_samples,
- &my_format, &total_samples);
-
- gst_query_set_duration (query, GST_FORMAT_TIME, total_samples);
+ if ((res = speex_dec_convert (dec->srcpad, GST_FORMAT_DEFAULT,
+ total_samples, &my_format, &total_samples))) {
+ gst_query_set_duration (query, GST_FORMAT_TIME, total_samples);
+ }
break;
}
default:
- return FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
{
static const GstQueryType query_types[] = {
GST_QUERY_POSITION,
+ GST_QUERY_DURATION,
0
};
}
default:
+ res = gst_pad_query_default (pad, query);
break;
}
{
static const GstQueryType types[] = {
GST_QUERY_POSITION,
+ GST_QUERY_DURATION,
+ GST_QUERY_CONVERT,
0
};
break;
}
default:
- res = FALSE;
+ res = gst_pad_query_default (pad, query);
break;
}
return res;