Whenever I have an mp4 file with the wrong aspect ratio, I use mkvtoolnix to create a new file with the correct AR. This has always worked beautifully until today. After processing the mp4 file, mkvtoolnix had an error message: “The AVC video track is missing the 'CTTS' atom for frame timecode offsets. However, AVC/h.264 allows frames to have more than the traditional one (for P frames) or two (for B frames) references to other frames. The timecodes for such frames will be out-of-order, and the 'CTTS' atom is needed for getting the timecodes right. As it is missing the timecodes for this track might be wrong. You should watch the resulting file and make sure that it looks like you expected it to.”
I'm sure I've had similar warnings before where the new file was OK. Not today – the new mkv file still plays 16:9 despite me specifying 4:3. What I find particularly odd is that mediainfo shows the file as 4:3 which is what I want but that's not how it plays...
I read that YAMB might help so I've installed it (v1.6). Nowhere in the GUI can I see an option for changing the AR. Thinking it might be the mp4box part of YAMB that I need, I installed 'MyMP4Box GUI' but, again, I don't see an option for AR changing.
Can anyone suggest why my mkvtoolnix file still plays 16:9 despite it reading 4:3 with mediainfo?
And can someone please instruct me on how to change an mp4(AVC) file's AR using either YAMB or MyMP4Box GUI?
Many thanks for all help offered.
+ Reply to Thread
Results 1 to 11 of 11
-
-
In Mymp4boxgui add the mp4, under the tab Mux right click on the video track and choose PAR and 4:3 or try 1:1. Click Save as and last Mux.
-
Hi Baldrick. Many thanks for that, I'd never have sussed that 'right click' on my own.
Sadly, none of the PAR options do the job. '4:3 NTSC' brings the picture in a little but it's still closer to 16:9. I can only imagine there's a stubborn gremlin in the source file preventing the AR being changed.
I've found a fix, though. Although I wanted to avoid re-encoding, that's what I've done (using avidemux set to x264). Putting the resultant file through mkvtoolnix gives me a 4:3 file. (I tried the same trick with MyMP4Box but it wouldn't work.)
Thanks again.
PS: Could I have used avidemux to change the AR at the same time I was converting? I don't think so...Last edited by pooksahib; 15th Sep 2015 at 07:11. Reason: PS added
-
Did you try use copy mode in avidemux? Under the video dropdown. To avoid reconversion.
-
Your source is likely square pixel (PAR=1:1). Set a Custom PAR: 3:4 to force 4:3 DAR.
-
Baldrick - no I didn't but it doesn't matter now.
jagabo - excellent, thank you. So why should 3:4 work when the entire world would call the resulting picture 4:3? Very odd. But thank you again, I'm chuffed. -
Because you're setting the pixel aspect ratio (the shape of individual pixels*) not the display aspect ratio (the shape of the final displayed picture). The relationship between DAR, PAR and FAR:
Code:DAR = FAR * PAR DAR = display aspect ratio, the final shape of the displayed picture FAR = frame aspect ratio, the frame dimensions PAR = pixel aspect ratio, the shape of individual pixels.
Code:DAR = FAR * PAR DAR = 1280 / 720 * 1 / 1 DAR = 1.777... DAR = 16/9
Code:DAR = FAR * PAR DAR / FAR = PAR 4 / 3 / (1280 / 720) = PAR 4 / 3 * 720 / 1280 = PAR 0.75 = PAR 3:4 = PAR
* In theory pixels are points with no dimensions. What you are really setting isn't the shape of the pixels but the spacing between them (horizontally and vertically). So modern codecs refer to the SAR (sampling aspect ratio) not PAR to be more technically correct. In realty, when pixels are instantiated (displayed) they take on a shape. They aren't displayed as a bunch of dots with blank space in between. -
That warning can usually be ignored and is probably unrelated to the problem.
Does MediaInfo show two different aspect ratios? ("Display aspect ratio" and "Original display aspect ratio")
Basically, in such an mkv file there can be two different aspect ratios stored. One in the mkv container and one in the AVC bitstream. It depends on the player on which info it uses. Mkvtoolnix does not change AVC bitstream info to e.g. "16/9", only the container info. If your player prefers the AVC bitstream info this means you will have problems if you try to change in mkvtoolnix. One thing mkvtoolnix can do, though, is removing the AVC bitstream info completely. Add the following command for that: "--engage remove_bitstream_ar_info"
Ideally, you already set the correct aspect ratio when encoding. Mkvtoolnix will then copy that info to the container as well and both agree and will thus work in any player, not matter what the player prefers to read. -
Just the one AR, if I recall. I've deleted the file now that I have a proper one via MyMP4Box. Thanks for the info, though.
Similar Threads
-
Convert MKV to MP4 (Lossless) using MKVExtractGUI + MyMP4Box GUI
By ilimitus in forum Video ConversionReplies: 6Last Post: 4th Feb 2016, 12:17 -
myMp4Box GUI Batch change track title
By RealPetChicken in forum Newbie / General discussionsReplies: 1Last Post: 10th Sep 2015, 15:58 -
Yamb join mp4 problem
By jfharper in forum Video ConversionReplies: 3Last Post: 29th Apr 2013, 19:54 -
Using YAMB to change aspect ratio
By pooksahib in forum Video ConversionReplies: 18Last Post: 10th Mar 2013, 00:19 -
change in video length after editing by yamb.
By vxombe in forum EditingReplies: 1Last Post: 29th Aug 2012, 13:28