After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 351742 - [vorbisenc] discontinuity detection too sensitive, might garble output
[vorbisenc] discontinuity detection too sensitive, might garble output
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Linux
: Normal normal
: 0.10.10
Assigned To: GStreamer Maintainers
GStreamer Maintainers
: 511543 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-08-17 11:28 UTC by Tim-Philipp Müller
Modified: 2011-05-19 06:25 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proposed patch (2.14 KB, patch)
2006-08-25 09:19 UTC, Michael Smith
none Details | Review

Description Tim-Philipp Müller 2006-08-17 11:28:18 UTC
The newly-added discontinuity detection based on previous_timestamp + previous_duration vs. current_timestamp is too sensitive. It will trigger even for minor stream imperfections or rounding errors in timestamps/durations, leading to unusuble output. Case in point: recent cddabasesrc fix, where

  0.0233333333 + 0.0166666666 added up to 0.0399999999 which was != 0.0400000000

and a discontinuity was assumed, the decoder reset etc. The resulting .ogg was pretty much broken, with 'stuttering' multiple times per second.

Don't know if this is a problem with how the decoder is reset/data flushed or not, but I think vorbisenc should be a bit less sensitive to such errors.
Comment 1 Jan Schmidt 2006-08-17 11:36:38 UTC
Let's pick a threshold. How does anything greater than 1 sample sound?
Comment 2 Michael Smith 2006-08-17 13:34:10 UTC
Other elements _should_ be providing 'perfect' streams if there isn't a discontinuity - if they aren't, they ARE buggy.

That said, there are a lot of such buggy elements, and it's not a particularly major bug.

So if you fix cddabasesrc, I'll fix this in vorbisenc :-)

Yeah, I agree with Jan: a threshold is a good idea. 1 sample? Maybe; maybe I'll use half a sample.

Comment 3 Tim-Philipp Müller 2006-08-17 13:48:09 UTC
> So if you fix cddabasesrc, I'll fix this in vorbisenc :-)

Already fixed ;-)

 
> Yeah, I agree with Jan: a threshold is a good idea. 1 sample? Maybe; maybe I'll
> use half a sample.

I vote for 2/3 of a sample!
Comment 4 Michael Smith 2006-08-25 09:19:22 UTC
Created attachment 71574 [details] [review]
Proposed patch

This patch should fix things, I think. Not well tested (but passes existing tests).

It's longer than it should be because on looking at the code already there, it looked pretty bogus in all sorts of cases.

I'll commit this if nobody has a problem with it.
Comment 5 Tim-Philipp Müller 2006-08-25 09:49:34 UTC
Seems to work great, at least with the previous cddabasesrc version that produced non-perfect streams.
Comment 6 Michael Smith 2006-08-25 09:55:34 UTC
Thanks. Committed; closing.
Comment 7 Sebastian Dröge (slomo) 2011-05-19 06:25:40 UTC
*** Bug 511543 has been marked as a duplicate of this bug. ***