mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-02-04 06:08:26 +02:00
avcodec/nvenc: Generate bufferingPeriod/pictureTiming SEI
For some unknown reason enabling these causes propper CBR padding, so as there are no known downsides just always enable them in CBR mode.
This commit is contained in:
parent
c8c14d0ffc
commit
3a9df7dfec
@ -796,6 +796,11 @@ static av_cold int nvenc_encode_init(AVCodecContext *avctx)
|
||||
if (avctx->codec->id == AV_CODEC_ID_H264) {
|
||||
ctx->encode_config.encodeCodecConfig.h264Config.adaptiveTransformMode = NV_ENC_H264_ADAPTIVE_TRANSFORM_ENABLE;
|
||||
ctx->encode_config.encodeCodecConfig.h264Config.fmoMode = NV_ENC_H264_FMO_DISABLE;
|
||||
ctx->encode_config.encodeCodecConfig.h264Config.outputBufferingPeriodSEI = 1;
|
||||
ctx->encode_config.encodeCodecConfig.h264Config.outputPictureTimingSEI = 1;
|
||||
} else if(avctx->codec->id == AV_CODEC_ID_H265) {
|
||||
ctx->encode_config.encodeCodecConfig.hevcConfig.outputBufferingPeriodSEI = 1;
|
||||
ctx->encode_config.encodeCodecConfig.hevcConfig.outputPictureTimingSEI = 1;
|
||||
}
|
||||
}
|
||||
} else if (avctx->global_quality > 0) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user