ext/ogg/gstoggdemux.c: Implement SEEKING query in its most basic form, so that we can at least check if we're seekabl...

Original commit message from CVS:
* ext/ogg/gstoggdemux.c: (gst_ogg_pad_src_query):
Implement SEEKING query in its most basic form, so that we can
at least check if we're seekable or not (#350655).
This commit is contained in:
Tim-Philipp Müller 2006-08-10 08:56:22 +00:00
parent 7b292da697
commit cf602c2379
2 changed files with 20 additions and 0 deletions

View file

@ -1,3 +1,9 @@
2006-08-10 Tim-Philipp Müller <tim at centricular dot net>
* ext/ogg/gstoggdemux.c: (gst_ogg_pad_src_query):
Implement SEEKING query in its most basic form, so that we can
at least check if we're seekable or not (#350655).
2006-08-09 Tim-Philipp Müller <tim at centricular dot net>
* gst/typefind/gsttypefindfunctions.c: (mpeg2_sys_type_find):

View file

@ -416,6 +416,20 @@ gst_ogg_pad_src_query (GstPad * pad, GstQuery * query)
gst_query_set_duration (query, GST_FORMAT_TIME, ogg->total_time);
break;
}
case GST_QUERY_SEEKING:
{
GstFormat format;
gst_query_parse_seeking (query, &format, NULL, NULL, NULL);
if (format == GST_FORMAT_TIME) {
gst_query_set_seeking (query, GST_FORMAT_TIME, ogg->seekable,
0, ogg->total_time);
} else {
res = FALSE;
}
break;
}
default:
res = gst_pad_query_default (pad, query);
break;