[FFmpeg-user] ffmpeg & MPEG-2 GOP structure

Valentin NOEL valent.noel at gmail.com
Tue Jan 13 12:04:17 CET 2015

2015-01-09 19:20 GMT+01:00 Nicolas George <george at nsup.org>:

> Le decadi 20 nivôse, an CCXXIII, Valentin NOEL a écrit :
> > Other encoders allow finishing closed GOP with B-frames (with only
> backward
> > reference)
> What is the difference between a B-frame with only backward reference and a
> P-frame?

Thanks for this question Nicolas, it made me dig deeper into my problem.

Actually, it seems that the closed GOP structure I look for is (in
presentation order) : B B I B B P B B P B B P
I explain : according to ISO/IEC 13818-2, P-frames are predicted from one
only backward reference, instead of B-frames which may be computed from :
    - both backward and forward references (well known),
    - from only backward reference,
    - from only forward reference (!!!)
That is the main difference between P-frames and B-frames computing. And it
explain why B-frames are used in the GOP structure I'd like to generate.

However, the problem is still there : how can I do it with FFmpeg ? It
seems FFmpeg do not generate B frames with one reference, isn't it ?

More information about the ffmpeg-user mailing list