From: wenbin.chen-at-intel.com@ffmpeg.org
To: ffmpeg-devel@ffmpeg.org
Subject: [FFmpeg-devel] [PATCH] libavcodec/qsvenc: Add dynamic setting support of low_delay_brc to av1_qsv
Date: Thu, 2 Mar 2023 10:33:36 +0800
Message-ID: <20230302023336.127035-1-wenbin.chen@intel.com> (raw)
From: Wenbin Chen <wenbin.chen@intel.com>
Signed-off-by: Wenbin Chen <wenbin.chen@intel.com>
---
doc/encoders.texi | 2 +-
libavcodec/qsvenc.c | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/doc/encoders.texi b/doc/encoders.texi
index b02737b9df..e9b34010ed 100644
--- a/doc/encoders.texi
+++ b/doc/encoders.texi
@@ -3344,7 +3344,7 @@ Supported in h264_qsv.
Change these value to reset qsv codec's max/min qp configuration.
@item @var{low_delay_brc}
-Supported in h264_qsv and hevc_qsv.
+Supported in h264_qsv, hevc_qsv and av1_qsv.
Change this value to reset qsv codec's low_delay_brc configuration.
@item @var{framerate}
diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c
index 3607859cb8..c975302b4f 100644
--- a/libavcodec/qsvenc.c
+++ b/libavcodec/qsvenc.c
@@ -1127,6 +1127,7 @@ static int init_video_param(AVCodecContext *avctx, QSVEncContext *q)
} else if (avctx->codec_id == AV_CODEC_ID_AV1) {
if (q->low_delay_brc >= 0)
q->extco3.LowDelayBRC = q->low_delay_brc ? MFX_CODINGOPTION_ON : MFX_CODINGOPTION_OFF;
+ q->old_low_delay_brc = q->low_delay_brc;
}
if (avctx->codec_id == AV_CODEC_ID_HEVC) {
@@ -2213,7 +2214,9 @@ static int update_low_delay_brc(AVCodecContext *avctx, QSVEncContext *q)
{
int updated = 0;
- if (avctx->codec_id != AV_CODEC_ID_H264 && avctx->codec_id != AV_CODEC_ID_HEVC)
+ if (avctx->codec_id != AV_CODEC_ID_H264 &&
+ avctx->codec_id != AV_CODEC_ID_HEVC &&
+ avctx->codec_id != AV_CODEC_ID_AV1)
return 0;
UPDATE_PARAM(q->old_low_delay_brc, q->low_delay_brc);
--
2.34.1
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next reply other threads:[~2023-03-02 2:33 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-02 2:33 wenbin.chen-at-intel.com [this message]
2023-03-16 3:57 ` Xiang, Haihao
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230302023336.127035-1-wenbin.chen@intel.com \
--to=wenbin.chen-at-intel.com@ffmpeg.org \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git