[Bug 759055] baseparse: post tag list updates on percentage delta instead of fixed delta

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Dec 7 03:36:10 PST 2015


https://bugzilla.gnome.org/show_bug.cgi?id=759055

Sebastian Dröge (slomo) <slomo at coaxion.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #316800|none                        |needs-work
             status|                            |

--- Comment #2 from Sebastian Dröge (slomo) <slomo at coaxion.net> ---
Review of attachment 316800:
 --> (https://bugzilla.gnome.org/review?bug=759055&attachment=316800)

::: libs/gst/base/gstbaseparse.c
@@ +1759,3 @@
+    if (parse->priv->post_avg_bitrate && parse->priv->avg_bitrate) {
+      gint diffprev = (gint) 100 * (ABSDIFF (parse->priv->avg_bitrate,
+          parse->priv->posted_avg_bitrate)) / parse->priv->avg_bitrate;

That's not going to work. This will always be 0, 100 or an integer multiple of
100.

You first have to multiply, than divide. For example by using
gst_util_uint64_scale_int().

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list