[MPlayer-dev-eng] [PATCH] (partially) support QuickTime sound atom version 2

Corey Hickey bugfood-ml at fatooh.org
Thu Dec 29 08:42:46 CET 2005


This fixes a bug I reported to -advusers a couple days ago and makes
sound play for many (if not all) recent Apple trailers. For example:

http://movies.apple.com/movies/disney/thechroniclesofnarnia/chroniclesofnarnia-pre_h1080p.mov

I was unable to find any current documentation from Apple; the most
recent I got was from 2001-03-01:
http://developer.apple.com/documentation/QuickTime/QTFF/QTFFChap3/chapter_4_section_3.html

So, I am unable to write any code to parse the sound atom itself, and
some if it is still parsed incorrectly. Nevertheless, the pertinent part
seems to be the ESDS atom that follows. In version 2, it seems, the ESDS
atom starts 20 bytes later.


Also, the old code assumes that the number in the channels field is
actually the number of channels, whereas it actually appears to be like
this:
1 --> 1
2 --> 2
3 --> 6

I used QuickTime to verify that my test file (listed above) does indeed
have six channels.


I have tested this patch on a variety of files with version 1 and
version 2 sound atoms. As far as I know I don't have any with version 0,
but I don't think I messed that up.

-Corey
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: fix-mov-sound-v2.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20051228/2da4bf5a/attachment.txt>


More information about the MPlayer-dev-eng mailing list