<p>Some MP4s have keyframes on scene changes; others have keyframes seemingly randomly placed, or placed every 5-10 seconds. I prefer the former, both for ease of editing and because, unless I'm misunderstanding the mp4 codec, it's the most efficient.</p>

<p>How would I force one behavior or the other in ffmpeg or Avidemux? (Specifically I would like to force the former, although I would like to know what causes the latter just out of curiosity.)</p>

<ffmpeg><encoding><codec><mp4>
Some MP4s have keyframes on scene changes. Others seem to have random keyframes, or keyframes every X seconds. What causes this discrepancy?
felwithe
# Some MP4s have keyframes on scene changes. Others seem to have random keyframes, or keyframes every X seconds. What causes this discrepancy?

(Asked by: username_0 on 2019-08-19)

Some MP4s have keyframes on scene changes; others have keyframes seemingly randomly placed, or placed every 5-10 seconds. I prefer the former, both for ease of editing and because, unless I'm misunderstanding the mp4 codec, it's the most efficient.

How would I force one behavior or the other in ffmpeg or Avidemux? (Specifically I would like to force the former, although I would like to know what causes the latter just out of curiosity.)

**Tags:** ffmpeg, encoding, codec, mp4


---

## 0 answers

