View Full Version : GOP min and max values
Makaveli84
4th September 2012, 18:39
The rule of thumb says that GOP Min = FPS and GOP Max = FPS * 10.
Based on that, here are the values I use when encoding:
FPS = 23.976, GOP Min = 23, GOP Max = 230
FPS = 24.000, GOP Min = 24, GOP Max = 240
FPS = 25.000, GOP Min = 25, GOP Max = 250
FPS = 29.970, GOP Min = 29, GOP Max = 290
Yet I rarely see other people abiding by these values. For example, most encoders seem to leave GOP Max at 250, and lesser values than 29 for FPS = 29.97. So which is the right way, or maybe the best way to do it?
Also, what should one use in the following less common cases:
FPS = VFR, GOP Min = ??, GOP Max = ???
FPS = 59.94, GOP Min = ??, GOP Max = ???
Thanks.
Keiyakusha
4th September 2012, 19:15
right way is to leave it at defaults. min gop set automatically anyway and max, 250 is just right because more may affect seeking in a way you don't want and obviously it will always do less if it feels like it needs to do it.
Btw where did you get such "rule of thumb"?
edit: Here is new rule of thumb for you
There is no reason keyint "should" be any specific value. It's just a tradeoff between seeking speed and compression. Don't muck with it.
min-keyint is automatically decided by the encoder. Don't muck with it.
...
As a general rule, don't mess with any options that aren't in x264 --help without extremely good reason.
Asmodian
4th September 2012, 19:29
It is all about the same, any benefit from setting it to the recommended max is pretty small at standard frame rates. There is not a large difference between max GOP set to 250 or 290. It just needs to keep seeking quick but still have long enough GOPs the increase in I frames doesn't cause the size to go up very much.
I still follow the rule of thumb but I don't think it matters much until you start talking about very different frame rates, like 60+.
Makaveli84
4th September 2012, 19:53
right way is to leave it at defaults. min gop set automatically anyway and max, 250 is just right because more may affect seeking in a way you don't want and obviously it will always do less if it feels like it needs to do it.
OK. Defaults it is.
Btw where did you get such "rule of thumb"?
Online discussions and posts. For example: http://forum.doom9.org/showthread.php?p=1163038#post1163038
And also, although a bit differently stated, in: http://mewiki.project357.com/wiki/X264_Settings#keyint (keyint and min-keyint sections combined imply the "rule")
the_weirdo
5th September 2012, 06:43
Online discussions and posts. For example: http://forum.doom9.org/showthread.php?p=1163038#post1163038
And also, although a bit differently stated, in: http://mewiki.project357.com/wiki/X264_Settings#keyint (keyint and min-keyint sections combined imply the "rule")
You should also read this thread (http://forum.doom9.org/showthread.php?p=1579051).
Blue_MiSfit
5th September 2012, 09:21
In my experience, if you're using at least a few seconds for the max GOP length, you're usually fine. Fast action will have tons of scene changes anyway. BluRay uses a max keyint of 1 second and still looks great - granted there's a ton of bits to play with but you get my drift.
I definitely wouldn't lose any sleep over using keyint 250 instead of keyint 300 for 30fps content...
In fact, I personally think the defaults lead to annoyingly slow seek times in some cases (i.e. scrubbing through video in AviSynth, or other editorial type tasks), so when I'm encoding for these types of scenarios I usually use 2x frame rate.
Derek
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.