[Bug 767507] New: gstaudiovisualizer timestamp adjustment seems wrong.
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Fri Jun 10 18:42:05 UTC 2016
https://bugzilla.gnome.org/show_bug.cgi?id=767507
Bug ID: 767507
Summary: gstaudiovisualizer timestamp adjustment seems wrong.
Classification: Platform
Product: GStreamer
Version: git master
OS: Linux
Status: NEW
Severity: normal
Priority: Normal
Component: gst-plugins-base
Assignee: gstreamer-bugs at lists.freedesktop.org
Reporter: thomas.jones at utoronto.ca
QA Contact: gstreamer-bugs at lists.freedesktop.org
GNOME version: ---
Currently it does this:
ts = gst_adapter_prev_pts (scope->priv->adapter, &dist);
if (GST_CLOCK_TIME_IS_VALID (ts)) {
dist /= bps;
ts += gst_util_uint64_scale_int (dist, GST_SECOND, rate);
}
where bps is GST_AUDIO_INFO_BPS (&scope->ainfo) which I *think* is bytes per
sample, but that means this calculation is ignoring the number of channels, and
if I'm reading the docs for gst_util_uint64_scale_int().
So the calculation probably ought to be:
ts = gst_adapter_prev_pts (scope->priv->adapter, &dist);
if (GST_CLOCK_TIME_IS_VALID (ts)) {
dist /= bps;
ts += gst_util_uint64_scale_int (dist, GST_SECOND,
rate * GST_AUDIO_INFO_BPF (&scope->ainfo));
}
because that will ACTUALLY give us bytes per second.
--
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