[FFmpeg-devel] [PATCH] Support for Dirac in ogg

David Conrad lessen42
Thu Nov 13 04:57:19 CET 2008


On Nov 11, 2008, at 8:13 PM, Anuradha Suraparaju wrote:

> Hi,
>
> On Fri, 2008-11-07 at 04:04 -0500, David Conrad wrote:
>
> [...]
>
>
>>> Try using ffmpeg2dirac to transcode files to Dirac wrapped in Ogg.
>>> It is
>>> basically a clone of ffmpeg2theora that replaces Theora with Dirac.
>>> The
>>> files created by it seem to play back okay with VLC (Schroedinge
>>> support
>>> enabled) and my local FFmpeg tree which was patched to support Dirac
>>> in
>>> Ogg. Seeking doesn't appear to be a problem either. The source can  
>>> be
>>> found in the Git repository on diracvideo.org.
>>>
>>> git clone git://diracvideo.org/git/ffmpeg2dirac.git
>>>
>>> If you want a sample file generated by ffmpeg2dirac just let me know
>>> where to upload it to.
>>
>> Playback works, the problem is that remuxing to another container
>> requires accurate timestamps. I already tried ffmpeg2dirac but the
>> timestamps it generates aren't correct. The most correct I've seen so
>> far is http://diracvideo.org/download/test-streams/ogg/
>> sage-640x360.ogg but it seems to me that delay should be half of what
>> it is in that file.
>>
>
> Can you provide more specifics as to why you think the timestamps
> generated by ffmpeg2dirac are wrong? I used the guidelines provided in
> the Ogg Dirac mapping specification so can't think why the timestamps
> are incorrect.

Looking at it again, it seems I was wrong and the only timestamp issue  
w/ the ffmpeg2dirac file I have is that there are multiple frames  
ending on the same page (thus only the last frame has a timestamp),  
which while isn't banned, the mapping does recommend you not do that.

> The delay, dts and pts in the time stamps are in increments of two for
> progressive streams. So the corrected delay would be half the  
> calculated
> value.

This is where the spec doesn't make sense to me given real files.  
Ignoring the delay, the dts for all files I have increases by one for  
each each frame, not two. All the samples I have are progressive, not  
interlaced.

Anyways, updated patch attached. It gives correct pts for the files I  
have, but depends on my pending patch to fix granulepos, and ffplay  
doesn't work correctly without your pending patch for to set  
has_b_frames.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: oggdirac.txt
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20081112/7288a54d/attachment.txt>
-------------- next part --------------




More information about the ffmpeg-devel mailing list