projects
/
platform
/
upstream
/
gstreamer.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9661a71
)
basesink: improve rate calculation
author
Wim Taymans
<wim.taymans@collabora.co.uk>
Mon, 14 Feb 2011 12:49:10 +0000
(13:49 +0100)
committer
Wim Taymans
<wim.taymans@collabora.co.uk>
Mon, 14 Feb 2011 14:17:44 +0000
(15:17 +0100)
When there is no duration on input buffers, assume the rate is 1.0
instead of (the undefined) 0.0.
libs/gst/base/gstbasesink.c
patch
|
blob
|
history
diff --git
a/libs/gst/base/gstbasesink.c
b/libs/gst/base/gstbasesink.c
index
cc5a99f
..
ede235b
100644
(file)
--- a/
libs/gst/base/gstbasesink.c
+++ b/
libs/gst/base/gstbasesink.c
@@
-2706,7
+2706,7
@@
gst_base_sink_perform_qos (GstBaseSink * sink, gboolean dropped)
gst_guint64_to_gdouble (priv->avg_pt) /
gst_guint64_to_gdouble (priv->avg_duration);
else
- rate =
0
.0;
+ rate =
1
.0;
if (GST_CLOCK_TIME_IS_VALID (priv->last_left)) {
if (dropped || priv->avg_rate < 0.0) {