gst/gstbin.c: Only care about latency min and max when the sink is actually a live sink.

Original commit message from CVS:
* gst/gstbin.c: (bin_query_latency_fold):
Only care about latency min and max when the sink is actually a live
sink.
This commit is contained in:
Wim Taymans 2008-06-25 11:50:06 +00:00
parent 23d8478698
commit 5335a8b34b
2 changed files with 16 additions and 8 deletions

View file

@ -1,3 +1,9 @@
2008-06-25 Wim Taymans <wim.taymans@collabora.co.uk>
* gst/gstbin.c: (bin_query_latency_fold):
Only care about latency min and max when the sink is actually a live
sink.
2008-06-25 Wim Taymans <wim.taymans@collabora.co.uk>
* docs/design/part-block.txt:

View file

@ -3029,14 +3029,16 @@ bin_query_latency_fold (GstElement * item, GValue * ret, QueryFold * fold)
/* for the combined latency we collect the MAX of all min latencies and
* the MIN of all max latencies */
if (min > fold->min)
fold->min = min;
if (fold->max == -1)
fold->max = max;
else if (max < fold->max)
fold->max = max;
if (fold->live == FALSE)
fold->live = live;
if (live) {
if (min > fold->min)
fold->min = min;
if (fold->max == -1)
fold->max = max;
else if (max < fold->max)
fold->max = max;
if (fold->live == FALSE)
fold->live = live;
}
} else {
g_value_set_boolean (ret, FALSE);
GST_DEBUG_OBJECT (item, "failed query");