diff options
author | Zhao Zhili <zhilizhao@tencent.com> | 2025-01-23 22:17:29 +0800 |
---|---|---|
committer | Zhao Zhili <zhilizhao@tencent.com> | 2025-02-04 01:21:26 +0800 |
commit | 1438f6997db70945173f01aea1768e3b27ce2679 (patch) | |
tree | bae044ed3a11ad7d30ded39b6d8bf44ac5183f48 /libavcodec/nvenc.c | |
parent | 4a0e1cfc6f33d152e007849f6de7028d651de2af (diff) | |
download | ffmpeg-1438f6997db70945173f01aea1768e3b27ce2679.tar.gz |
avcodec/nvenc: Enable recovery point SEI for intra refresh mode
Otherwise all frames can be dropped after seek without the
output_corrupt/showall flags.
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
Reviewed-by: Timo Rothenpieler <timo@rothenpieler.org>
Diffstat (limited to 'libavcodec/nvenc.c')
-rw-r--r-- | libavcodec/nvenc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/nvenc.c b/libavcodec/nvenc.c index c52e47734e..c359c2bc8a 100644 --- a/libavcodec/nvenc.c +++ b/libavcodec/nvenc.c @@ -1281,6 +1281,7 @@ static av_cold int nvenc_setup_h264_config(AVCodecContext *avctx) h264->intraRefreshPeriod = cc->gopLength; h264->intraRefreshCnt = cc->gopLength - 1; cc->gopLength = NVENC_INFINITE_GOPLENGTH; + h264->outputRecoveryPointSEI = 1; #ifdef NVENC_HAVE_SINGLE_SLICE_INTRA_REFRESH h264->singleSliceIntraRefresh = ctx->single_slice_intra_refresh; #endif @@ -1461,6 +1462,7 @@ static av_cold int nvenc_setup_hevc_config(AVCodecContext *avctx) hevc->intraRefreshPeriod = cc->gopLength; hevc->intraRefreshCnt = cc->gopLength - 1; cc->gopLength = NVENC_INFINITE_GOPLENGTH; + hevc->outputRecoveryPointSEI = 1; #ifdef NVENC_HAVE_SINGLE_SLICE_INTRA_REFRESH hevc->singleSliceIntraRefresh = ctx->single_slice_intra_refresh; #endif |