[x265] Adaptove GoP sizes - not sure if its working

Steve Borho steve at borho.org
Sat Aug 22 16:27:55 CEST 2015


On 08/22, Roshantha Mendis wrote:
> Okay I will try to find a video like that. If you have a good appropriate
> test sequence for me to test, that will give that behaviour, please let me
> know.  Thank you.
> 
> The strange thing is, the original vid clip was encoded in mp4 (downloaded
> from YouTube) and when I used ffprobe to inspect it, the GOP sizes (I to I)
> seemed to be different to the sizes generated by x265. Maybe it's to do
> with the way frames are identified..

You're conflating two or three topics.

The encoder will only insert keyframes to satisfy a keyframe interval
(max) limit, and the keyframe max interval is generally specified by
your target use case (web streaming, video conferencing, file
transcoding, etc). For instance:

https://developer.apple.com/library/ios/technotes/tn2224/_index.html#//apple_ref/doc/uid/DTS40009745-CH1-DECIDEONYOURVARIANTS

Our lookahead will use P frames at scene cuts unless the current
keyframe interval is approaching the user-specified max interval, and
even then only if scenecut detection is enabled (--scenecut, which is
enabled by default). If scenecut detection is disabled, then keyframes
will always be at the max interval distance from each other.  In short,
a scene cut does not always result in a keyframe.

The keyframe interval used in the source video has no bearing on the
keyframe interval given to the output encoder.

-- 
Steve Borho


More information about the x265-devel mailing list