H264 frame rates / rotation
Posted: 07 Jul 2010 16:37
General Question:
I (purposely) recorded a video in portrait mode as I knew there was software out there that would rotate it.
(let's not start the "Why would anyone want to do that?" discussion again, it has been done here before)
VLC will play it rotated, but of course I would like to save it rotated. After some searching I found that avidemux (http://avidemux.sourceforge.net/) was a good candidate for rotating and saving the video. And it does, but here is the problem, the new video plays too fast in VLC.
The original video was recorded on a Panasonic Lumix AVCHD Lite HD camera (in AVCHD mode)
According to VLC the original video is: H264 – MPEG-4 AVR part10, res: 1280x720, frame rate: 119.880119
but according to avidemux it is: H264, 1280x720, frame rate: 59.940 fps, 300 frames
So they see the initial frame rate different. My first question is How can they read a different frame rate? How is this information stored in the container file? Is the frame rate only stores as a single variable in the file header or is it stored with every frame?
The original file is a .MTS file.
Within avidemux, the original file plays slowly, which makes sense (to me) i.e. if it thinks there are 60fps but the video has 120fps then it will take 2 seconds at 60fps to play 1 sec of 120fps video. But avidemux has the ability to change the fps. So I set it to 119.88 and converted the file.
Then when I play it in avidemux it looks good. Here is the part I do not get: so I save the file, rotated (which works well by the way) but when I play the resulting file in VLC it plays at about 4x speed. Yet the "Codec info" says it's 119.88fps.
Can anyone explain this to me? please.
Thanks.
(P.S. I am posting this question in both forums looking for help)
I (purposely) recorded a video in portrait mode as I knew there was software out there that would rotate it.
(let's not start the "Why would anyone want to do that?" discussion again, it has been done here before)
VLC will play it rotated, but of course I would like to save it rotated. After some searching I found that avidemux (http://avidemux.sourceforge.net/) was a good candidate for rotating and saving the video. And it does, but here is the problem, the new video plays too fast in VLC.
The original video was recorded on a Panasonic Lumix AVCHD Lite HD camera (in AVCHD mode)
According to VLC the original video is: H264 – MPEG-4 AVR part10, res: 1280x720, frame rate: 119.880119
but according to avidemux it is: H264, 1280x720, frame rate: 59.940 fps, 300 frames
So they see the initial frame rate different. My first question is How can they read a different frame rate? How is this information stored in the container file? Is the frame rate only stores as a single variable in the file header or is it stored with every frame?
The original file is a .MTS file.
Within avidemux, the original file plays slowly, which makes sense (to me) i.e. if it thinks there are 60fps but the video has 120fps then it will take 2 seconds at 60fps to play 1 sec of 120fps video. But avidemux has the ability to change the fps. So I set it to 119.88 and converted the file.
Then when I play it in avidemux it looks good. Here is the part I do not get: so I save the file, rotated (which works well by the way) but when I play the resulting file in VLC it plays at about 4x speed. Yet the "Codec info" says it's 119.88fps.
Can anyone explain this to me? please.
Thanks.
(P.S. I am posting this question in both forums looking for help)