GNOME Bugzilla – Bug 624173
[qtdemux] qt file with dimension data in tkhd does not get pixel-aspect-ratio in caps
Last modified: 2010-07-16 12:12:56 UTC
I have a file that has the dimension set to 1024x576 in the tkhd atom, pixel dimensions set to 720x576 in the stds atom and the pasp atom is not present. The major brand of the file is 'qt '. Some discussion on #gstreamer revealed, that QT files should have PAR data in the pasp atom, but in the case of this particular file (which I sadly cannot share) the correct PAR is 64/45 and it's exactly what 1024/720 is. Since apparently such files are appearing in the wild it would make sense to use the info from tkhd and stds to determine PAR in case there is no pasp atom. The only problem is that according to the spec the PAR data should be in the pasp atom only (for QT files), and so a compliant demuxer should not signal PAR if there is no pasp atom. I tend to think that in this case it's better to accept a common misinterpretation of the spec instead of standing strictly by it. Does anyone know a QT file that has no pasp and that would cause wrong PAR to be set, if it were done according to tkhd and stds?
Can we get the output of qtdump (or mp4dump) on this file? Also, what PAR do other players (most notably QT player) come up with?
Created attachment 165785 [details] qtdump output
QT player on MacOSX came up with 64/45, so did mplayer and vlc.
Created attachment 165788 [details] [review] qtdemux: also calculate PAR using track width and height for QT files Oh, well, by popular majority vote. So attached patch basically removes the 'if' and should then take care of this.
Yeah, that should do the trick.
commit 65fdbe68ecf67a5c4f7ea3a7cdf66628c8e42db5 Author: Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk> Date: Tue Jul 13 12:34:44 2010 +0200 qtdemux: also calculate PAR using track width and height for QT files (... as opposed to only for ISO style files). Fixes #624173.