[FFmpeg-devel] [PATCH] avformat/oggparseopus: fix segmented timestamps

Mark Harris mark.hsj at gmail.com
Sat Jan 4 21:19:41 CET 2014


On Sat, Jan 4, 2014 at 11:59 AM, Michael Niedermayer <michaelni at gmx.at>wrote:

> On Tue, Dec 31, 2013 at 11:04:54AM -0800, Mark Harris wrote:
> > Fix timestamp calculation for code 3 Ogg Opus packets with less than
> > 2 bytes in the last segment (e.g. packet length 255 or 256).
> > A sample that would seek incorrectly in ffplay can be created with:
> >   ffmpeg -i in.wav -b:a 34k -vbr off -frame_duration 60 out.opus
>
> i dont seem to be able to reproduce the issue even though it seems
> i did have a in.wav file in my local directory. Or maybe iam trying
> the wrong things with the generated file
>
>
The input audio doesn't matter as long as you can distinguish beginning,
middle, and end (so don't use "sine" or a similar source).  It's the
particular Opus packet sizes that cause the problem; encoding anything
to 34kb/s CBR with 60ms frame duration will trigger the issue.
Without the patch, "ffplay out.opus" and clicking in the middle of the
window to seek to the middle will seek to the end instead, due to
incorrect timestamps.

 - Mark


More information about the ffmpeg-devel mailing list