[Bug 656412] vorbisdec: discard starting samples according to granpos
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Fri Dec 2 07:51:07 PST 2011
https://bugzilla.gnome.org/show_bug.cgi?id=656412
GStreamer | gst-plugins-base | unspecified
--- Comment #21 from Mark Nauwelaerts <mnauw at users.sourceforge.net> 2011-12-02 15:51:03 UTC ---
(In reply to comment #19)
> > So, trying to do this without segment stuff brings us back to Comment #6, with
> > some ts tricks/hacks, which can probably be thought of and might be
> > special-case handled in a vorbisdec pre_push method or so.
>
> Why ?
> As an idealized example, say you have a Vorbis stream, where the third page
> (which is the first data page, the first two being headers) consists of a
> single Vorbis packet. Let this stream be 48000 Hz, and contain 4800 samples.
> This packet will then be 0.1 seconds long, and that first page has a granpos
> 4800 if all samples have to be played. This will translate to a timestamp of
> 0.1 seconds.
Seems to be some confusion going here w.r.t "timestamp" and "notional
timestamp" whereas there is only 1 real ts and that's the one put on a buffer.
And in this case, this packet/buffer has ts 0.
>
> Now, if there's a sample perfect cut to remove the first 0.05 seconds (half
> that first packet), then the granpos of that first page will be set to 2400.
> This will transate to a timestamp of 0.05, such that the notional ts of the
> first half of the sampes will be negative.
So, the only real one would have to be -0.05, and I consider clamping this one
to 0 a (minor) ts trick/hack (to start with). Also, how does vorbisdec detect
it should drop these samples (preferably without introducing other problems or
having it work only with oggdemux) ?
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- 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