Incorrect start frame when converting mpeg2video in .mov to mp4
|Reported by:||sroy8||Owned by:|
|Blocking:||Reproduced by developer:||no|
|Analyzed by developer:||no|
Summary of the bug:
When I convert an mpeg2video in a .mov container to mp4, the output includes additional frames that are before the start frame in the input. This is possible because the start time of the input is non-zero.
% ffmpeg -i incorrect-start-frame.mov incorrect-start-frame.mp4
In more detail, ffprobe on the input gives the following duration and start:
Duration: 00:00:00.70, start: 0.522533, bitrate: 46718 kb/s
In contrast, ffprobe on the output gives:
Duration: 00:00:01.24, start: 0.021313, bitrate: 10801 kb/s
I would be fine with small discrepancies. However, the beginning of the output includes frames that are before the start of the input, which is a problem. I end up with these input files when I capture video from a Canon HV20 camera using iMovie. iMovie splits the video into scenes, and it's common for a file to include a few additional frames from the previous scene before the video start time. The input video suppresses these frames by setting the start time. However, the output video incorrectly shows them. Often, these frames have no relationship to the rest of the video.
My workaround has been to use gawk to extract the start time of the input video and then pass this to ffmpeg using -ss. For example:
% ffmpeg -ss 0.522533 -i incorrect-start-frame.mov correct-start-frame.mp4
I've tried many different flags to try to get the right behavior without needing -ss, without success. However, even if there is a correct flag setting, it seems like a bug from a user standpoint that the default behavior includes the extra frames.
Change History (10)
comment:3 by , 8 years ago
|Summary:||Incorrect start frame when converting mpeg2video to mp4 → Incorrect start frame when converting mpeg2video in .mov to mp4|