summaryrefslogtreecommitdiff
path: root/libavcodec/nvenc.c
diff options
context:
space:
mode:
authorTimo Rothenpieler <timo@rothenpieler.org>2020-07-28 21:44:11 +0200
committerTimo Rothenpieler <timo@rothenpieler.org>2020-07-28 21:44:11 +0200
commit466c14d10728cd315c60e602ffe3797e7dd0c3d3 (patch)
treec23fd2ab046175deb81af7dc993f6613478ea85b /libavcodec/nvenc.c
parent39c4b788297b7883d833d68fad3707ce50e01472 (diff)
avcodec/nvenc: fix B-Ref-Mode support check for recent HEVC
Diffstat (limited to 'libavcodec/nvenc.c')
-rw-r--r--libavcodec/nvenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/nvenc.c b/libavcodec/nvenc.c
index c6740c1842..8f5036b699 100644
--- a/libavcodec/nvenc.c
+++ b/libavcodec/nvenc.c
@@ -424,7 +424,7 @@ static int nvenc_check_capabilities(AVCodecContext *avctx)
#ifdef NVENC_HAVE_BFRAME_REF_MODE
ret = nvenc_check_cap(avctx, NV_ENC_CAPS_SUPPORT_BFRAME_REF_MODE);
- if (ctx->b_ref_mode == NV_ENC_BFRAME_REF_MODE_EACH && ret != 1) {
+ if (ctx->b_ref_mode == NV_ENC_BFRAME_REF_MODE_EACH && ret != 1 && ret != 3) {
av_log(avctx, AV_LOG_WARNING, "Each B frame as reference is not supported\n");
return AVERROR(ENOSYS);
} else if (ctx->b_ref_mode != NV_ENC_BFRAME_REF_MODE_DISABLED && ret == 0) {