Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
|
Thread Tools | Search this Thread | Display Modes |
7th May 2007, 14:57 | #1 | Link | |
Registered User
Join Date: Mar 2007
Posts: 27
|
Patch mp4box to make anamorphic PAR compatible with Quicktime (like NicMP4Box)
Hi!
I know that many people here don't like the "crap from Apple", but I'd like to create MP4/x264 files, that also work with Quicktime (Apple TV...), which supports AVC main profile. The only problem is anamorphic encoding. If I create a mp4 file with an anamorphic video-stream using x264.exe and mp4box (MeGUI), Quicktime does not use the correct PAR/DAR. There is a way to store the PAR in a MP4-container, to make Quicktime understand it. People from Handbrake have implemented it in their development-version: By adding an atom with a transformation matrix for the PAR to the mp4 container (AFAIK in moov.trak.tkhd.reserved3), Quicktime shows the video correctly (thread in the handbrake forum). The patch was based on the following information: http://sourceforge.net/forum/message.php?msg_id=2059542 http://developer.apple.com/documenta...39-CH204-33299 Handbrake uses mpeg4ipv2, there is also an updated patch for that: http://mpeg4ip.cvs.sourceforge.net/m...?r1=1.4&r2=1.5 I have looked at the source of NicMP4Box, which was very interesting, but does something different (it adds an uuid atom by patching mp4box). Looking at the source of MP4Box, there is a GF_TrackHeaderBox struct with a property reserved3 (u16). Perhaps there is an easier way since Quicktime 7.1, without such a transformation matrix: Quote:
Apple provides some details, about 'pasp' or 'pixel aspect ratio', but I have no idea how to use it with mp4box or something similar: http://www.devworld.apple.com./docum...nce/index.html Something else I've found about 'pasp' (but it seems to be older, not sure if it has something to do with 'pasp' mentioned above): http://developer.apple.com/quicktime...h019.html#pasp I'm new to mp4box, so I'm not sure how to implement the transformation marix or perhaps pasp into it. But looking at the patch for Handbrake, it should not be very complicated. Does someone have an idea for a patch, similar to NicMP4Box? Or can the pasp setting be changed without patching anything? best regards mcka |
|
12th May 2007, 13:05 | #2 | Link |
Registered User
Join Date: Nov 2001
Posts: 9,770
|
why dont you simply post a feature request on the gpac/mp4box project:
http://sourceforge.net/tracker/?atid...01&func=browse
__________________
Between the weak and the strong one it is the freedom which oppresses and the law that liberates (Jean Jacques Rousseau) I know, that I know nothing (Socrates) MPEG-4 ASP FAQ | AVC/H.264 FAQ | AAC FAQ | MP4 FAQ | MP4Menu stores DVD Menus in MP4 (guide) Ogg Theora | Ogg Vorbis use WM9 today and get Micro$oft controlling the A/V market tomorrow for free |
15th May 2007, 01:07 | #3 | Link | |
Registered User
Join Date: Mar 2007
Posts: 27
|
It has already been posted there more than 1 year ago:
http://sourceforge.net/tracker/index...01&atid=571741 https://sourceforge.net/tracker/inde...01&atid=571741 I'd probably forget what I've written about transformation matrix, but concentrate on the new "pasp" feature of MPEG standard ISO/IEC 14496-12 (AMENDMENT 1: Support for timed metadata, non-square pixels and improved sample groups). That seems to be what has been implemented in Quicktime 7.1. That's what the Paper from ISO states: Quote:
Code:
class VisualSampleEntry(codingname) extends SampleEntry (codingname){ [...] PixelAspectRatioBox pasp; // optional } Code:
class PixelAspectRatioBox extends Box(‘pasp’){ unsigned int(32) hSpacing; unsigned int(32) vSpacing; } I have looked at the source of mp4box, but I've no idea where to add the PixelAspectRatioBox and I'm not sure how to map the classes from ISO standard to the data structures in mp4box. best regards mcka Last edited by mcka; 15th May 2007 at 01:10. |
|
7th August 2007, 10:54 | #5 | Link |
Registered User
Join Date: Dec 2002
Location: Sydney, Australia
Posts: 252
|
3ivx MPEG-4 5.0.1 now supports Apple QuickTime compatible Aspect-Ratio muxing/demuxing etc.
http://3ivx.com/pr/pr20070730_501.html QuickTime compatible Aspect Ratio Signaling has been implemented within all components of the 3ivx MPEG-4 DirectShow Filter Suite, allowing Windows application developers to produce and handle Anamorphic content which is compatible with all Windows DirectShow players as well as Apple’s QuickTime and AppleTV. Its not 'pasp' support, but we found that QT never outputs PASP videos anyway, so we had to implemented the QT6 MP4 "transformation matrix" support. which is used by iPhones et al.
__________________
http://www.3ivx.com |
7th August 2007, 12:24 | #6 | Link | |
Life's clearer in 4K UHD
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
|
Quote:
Thanks for confirming this. As you know, QuickTime Pro offers quite a few other "Visual and Audio Settings" options. Do you have any plans to incorporate any of these too? Cheers
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
|
|
7th August 2007, 12:27 | #7 | Link | |||
Teetrinker
Join Date: Jan 2002
Posts: 258
|
Quote:
Quote:
Quote:
__________________
Play GO ( http://en.wikipedia.org/wiki/Go_(board_game)) |
|||
9th August 2007, 08:36 | #8 | Link |
Registered User
Join Date: Dec 2002
Location: Sydney, Australia
Posts: 252
|
Be more specific
__________________
http://www.3ivx.com |
11th August 2007, 12:29 | #9 | Link |
Life's clearer in 4K UHD
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
|
Hi Stux,
QT7 Pro offers the following "Visual Settings": - And "Audio Settings": - Obviously, adjustments to any of these settings are only effective when played in QT7 player or the embedded web player. Cheers
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
|
11th August 2007, 16:42 | #10 | Link |
Registered User
Join Date: Dec 2002
Location: Sydney, Australia
Posts: 252
|
The only one of those settings we will be respecting is the "Aspect Ratio" one. Not the scaling size, nor the volumes and balances.
I believe we do respect track disabled/enabled in the case of multiple audio tracks etc.
__________________
http://www.3ivx.com |
11th August 2007, 17:31 | #11 | Link |
Life's clearer in 4K UHD
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
|
Are you able to provide an (simple profile) example sample by any chance?
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
|
13th November 2007, 11:45 | #13 | Link |
Registered User
Join Date: Mar 2007
Posts: 27
|
Thank you so much!
Is there a compiled version available somwhere? If not I'll try to compile one, never done that on Windows before.... One question: is this feaure allways enabled when using anamorphic encoding, or is there a new command line switch? So is it combined with the old way to use anamorphic encoding (which works in other players), or is it an alternative, so I have to choose if I want to use PASP or the old way? Again, thank you very much for implementing it! |
13th November 2007, 12:15 | #14 | Link |
Life's clearer in 4K UHD
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,227
|
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
|
|
|