summaryrefslogtreecommitdiff
path: root/libavcodec/vaapi_encode_mpeg2.c
diff options
context:
space:
mode:
authorMark Thompson <sw@jkqxz.net>2018-09-18 23:30:47 +0100
committerMark Thompson <sw@jkqxz.net>2018-09-23 14:42:33 +0100
commitbf726c26fde26601a90daacf1b10a9860d21321c (patch)
tree9ed0e2a816515ea53a488410333c86f18e522e1f /libavcodec/vaapi_encode_mpeg2.c
parent8479f99c7dd227d9cb94d262602f1298f71cf33b (diff)
vaapi_encode: Clean up the GOP structure configuration
Choose what types of reference frames will be used based on what types are available, and make the intra-only mode explicit (GOP size one, which must be used for MJPEG).
Diffstat (limited to 'libavcodec/vaapi_encode_mpeg2.c')
-rw-r--r--libavcodec/vaapi_encode_mpeg2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vaapi_encode_mpeg2.c b/libavcodec/vaapi_encode_mpeg2.c
index db72516187..b6edca9158 100644
--- a/libavcodec/vaapi_encode_mpeg2.c
+++ b/libavcodec/vaapi_encode_mpeg2.c
@@ -355,7 +355,7 @@ static int vaapi_encode_mpeg2_init_sequence_params(AVCodecContext *avctx)
*vseq = (VAEncSequenceParameterBufferMPEG2) {
- .intra_period = avctx->gop_size,
+ .intra_period = ctx->gop_size,
.ip_period = ctx->b_per_p + 1,
.picture_width = avctx->width,