-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Submodule ffmpeg 5c2a29c..1800a0d Update 0055 and 0071 Signed-off-by: Haihao Xiang <[email protected]>
- Loading branch information
Showing
3 changed files
with
30 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From 23e574e913b4d2ccb3386cbe9516877a772ec46d Mon Sep 17 00:00:00 2001 | ||
From da63117d63708aa1b48f0ba069a0a79b9ca5bb7d Mon Sep 17 00:00:00 2001 | ||
From: "Chen,Wenbin" <[email protected]> | ||
Date: Thu, 26 Aug 2021 16:52:50 +0800 | ||
Subject: [PATCH 25/46] libavcodec/qsvenc_hevc: add main10sp support to | ||
|
@@ -19,7 +19,7 @@ Signed-off-by: Wenbin Chen <[email protected]> | |
3 files changed, 39 insertions(+), 3 deletions(-) | ||
|
||
diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c | ||
index 0995722858..bf6e39dc2a 100644 | ||
index 0118d6f5d9..14f72e1956 100644 | ||
--- a/libavcodec/qsvenc.c | ||
+++ b/libavcodec/qsvenc.c | ||
@@ -198,6 +198,7 @@ static void dump_video_param(AVCodecContext *avctx, QSVEncContext *q, | ||
|
@@ -39,7 +39,7 @@ index 0995722858..bf6e39dc2a 100644 | |
av_log(avctx, AV_LOG_VERBOSE, "profile: %s; level: %"PRIu16"\n", | ||
print_profile(avctx->codec_id, info->CodecProfile), info->CodecLevel); | ||
|
||
@@ -357,6 +360,12 @@ static void dump_video_param(AVCodecContext *avctx, QSVEncContext *q, | ||
@@ -373,6 +376,12 @@ static void dump_video_param(AVCodecContext *avctx, QSVEncContext *q, | ||
av_log(avctx, AV_LOG_VERBOSE, "NumTileColumns: %"PRIu16"; NumTileRows: %"PRIu16"\n", | ||
exthevctiles->NumTileColumns, exthevctiles->NumTileRows); | ||
} | ||
|
@@ -52,7 +52,7 @@ index 0995722858..bf6e39dc2a 100644 | |
} | ||
|
||
static void dump_video_vp9_param(AVCodecContext *avctx, QSVEncContext *q, | ||
@@ -1115,6 +1124,18 @@ static int init_video_param(AVCodecContext *avctx, QSVEncContext *q) | ||
@@ -1136,6 +1145,18 @@ static int init_video_param(AVCodecContext *avctx, QSVEncContext *q) | ||
q->extparam_internal[q->nb_extparam_internal++] = (mfxExtBuffer *)&q->exthevctiles; | ||
} | ||
|
||
|
@@ -71,7 +71,7 @@ index 0995722858..bf6e39dc2a 100644 | |
q->extvsi.VideoFullRange = (avctx->color_range == AVCOL_RANGE_JPEG); | ||
q->extvsi.ColourDescriptionPresent = 0; | ||
|
||
@@ -1307,12 +1328,16 @@ static int qsv_retrieve_enc_params(AVCodecContext *avctx, QSVEncContext *q) | ||
@@ -1328,12 +1349,16 @@ static int qsv_retrieve_enc_params(AVCodecContext *avctx, QSVEncContext *q) | ||
.Header.BufferSz = sizeof(hevc_tile_buf), | ||
}; | ||
|
||
|
@@ -90,7 +90,7 @@ index 0995722858..bf6e39dc2a 100644 | |
ext_buffers[ext_buf_num++] = (mfxExtBuffer*)&extradata; | ||
ext_buffers[ext_buf_num++] = (mfxExtBuffer*)&co; | ||
|
||
@@ -1334,6 +1359,10 @@ static int qsv_retrieve_enc_params(AVCodecContext *avctx, QSVEncContext *q) | ||
@@ -1355,6 +1380,10 @@ static int qsv_retrieve_enc_params(AVCodecContext *avctx, QSVEncContext *q) | ||
q->exthevctiles_idx = ext_buf_num; | ||
ext_buffers[ext_buf_num++] = (mfxExtBuffer*)&hevc_tile_buf; | ||
} | ||
|
@@ -102,18 +102,18 @@ index 0995722858..bf6e39dc2a 100644 | |
q->param.ExtParam = ext_buffers; | ||
q->param.NumExtParam = ext_buf_num; | ||
diff --git a/libavcodec/qsvenc.h b/libavcodec/qsvenc.h | ||
index eb79db9871..f477b5dab6 100644 | ||
index a7bbb3797e..fa3e1b8ffd 100644 | ||
--- a/libavcodec/qsvenc.h | ||
+++ b/libavcodec/qsvenc.h | ||
@@ -154,6 +154,7 @@ typedef struct QSVEncContext { | ||
@@ -166,6 +166,7 @@ typedef struct QSVEncContext { | ||
mfxExtMultiFrameControl extmfc; | ||
#endif | ||
mfxExtHEVCTiles exthevctiles; | ||
+ mfxExtHEVCParam exthevcparam; | ||
mfxExtVP9Param extvp9param; | ||
#if QSV_HAVE_EXT_AV1_PARAM | ||
mfxExtAV1TileParam extav1tileparam; | ||
@@ -168,7 +169,7 @@ typedef struct QSVEncContext { | ||
@@ -180,7 +181,7 @@ typedef struct QSVEncContext { | ||
|
||
mfxExtVideoSignalInfo extvsi; | ||
|
||
|
@@ -122,21 +122,21 @@ index eb79db9871..f477b5dab6 100644 | |
int nb_extparam_internal; | ||
|
||
mfxExtBuffer **extparam; | ||
@@ -285,6 +286,9 @@ typedef struct QSVEncContext { | ||
int old_rc_max_rate; | ||
@@ -299,6 +300,9 @@ typedef struct QSVEncContext { | ||
// This is used for SEI Timing reset | ||
int old_pic_timing_sei; | ||
+ | ||
int skip_frame; | ||
+ int exthevcparam_idx; | ||
+ int main10sp; | ||
+ | ||
} QSVEncContext; | ||
|
||
int ff_qsv_enc_init(AVCodecContext *avctx, QSVEncContext *q); | ||
diff --git a/libavcodec/qsvenc_hevc.c b/libavcodec/qsvenc_hevc.c | ||
index 2a3f34b915..22cdb86532 100644 | ||
index e042263bf5..c307f2dfb3 100644 | ||
--- a/libavcodec/qsvenc_hevc.c | ||
+++ b/libavcodec/qsvenc_hevc.c | ||
@@ -276,6 +276,9 @@ static const AVOption options[] = { | ||
@@ -360,6 +360,9 @@ static const AVOption options[] = { | ||
{ "int_ref_qp_delta", "QP difference for the refresh MBs", OFFSET(qsv.int_ref_qp_delta), AV_OPT_TYPE_INT, { .i64 = INT16_MIN }, INT16_MIN, INT16_MAX, VE }, | ||
{ "int_ref_cycle_dist", "Distance between the beginnings of the intra-refresh cycles in frames", OFFSET(qsv.int_ref_cycle_dist), AV_OPT_TYPE_INT, { .i64 = -1 }, -1, INT16_MAX, VE }, | ||
|
||
|
@@ -147,5 +147,5 @@ index 2a3f34b915..22cdb86532 100644 | |
}; | ||
|
||
-- | ||
2.34.1 | ||
2.25.1 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From b246b2387b0b5b1437f3fa35f0fb57a012dffd6f Mon Sep 17 00:00:00 2001 | ||
From 0f8034dcdf89bc2c6946d6eb9d4ed839cfe8a4d2 Mon Sep 17 00:00:00 2001 | ||
From: Fei Wang <[email protected]> | ||
Date: Thu, 16 Jun 2022 10:04:18 +0800 | ||
Subject: [PATCH 38/46] lavc/vaapi: support av1 encode | ||
|
@@ -39,10 +39,10 @@ Signed-off-by: Haihao Xiang <[email protected]> | |
create mode 100644 libavcodec/vaapi_encode_av1.c | ||
|
||
diff --git a/configure b/configure | ||
index f910361d68..d291165f46 100755 | ||
index c429609f14..673b03b45f 100755 | ||
--- a/configure | ||
+++ b/configure | ||
@@ -3276,6 +3276,8 @@ wmv3_crystalhd_decoder_select="crystalhd" | ||
@@ -3266,6 +3266,8 @@ wmv3_crystalhd_decoder_select="crystalhd" | ||
av1_qsv_decoder_select="qsvdec" | ||
av1_qsv_encoder_select="qsvenc" | ||
av1_qsv_encoder_deps="libvpl" | ||
|
@@ -51,7 +51,7 @@ index f910361d68..d291165f46 100755 | |
|
||
# parsers | ||
aac_parser_select="adts_header mpeg4audio" | ||
@@ -6990,6 +6992,7 @@ if enabled vaapi; then | ||
@@ -6976,6 +6978,7 @@ if enabled vaapi; then | ||
check_type "va/va.h va/va_enc_jpeg.h" "VAEncPictureParameterBufferJPEG" | ||
check_type "va/va.h va/va_enc_vp8.h" "VAEncPictureParameterBufferVP8" | ||
check_type "va/va.h va/va_enc_vp9.h" "VAEncPictureParameterBufferVP9" | ||
|
@@ -60,10 +60,10 @@ index f910361d68..d291165f46 100755 | |
|
||
if enabled_all opencl libdrm ; then | ||
diff --git a/doc/encoders.texi b/doc/encoders.texi | ||
index 53dd02fd28..c999546e3f 100644 | ||
index b8051cda3f..3363a2d4ef 100644 | ||
--- a/doc/encoders.texi | ||
+++ b/doc/encoders.texi | ||
@@ -3926,6 +3926,20 @@ Average variable bitrate. | ||
@@ -3971,6 +3971,20 @@ Average variable bitrate. | ||
Each encoder also has its own specific options: | ||
@table @option | ||
|
||
|
@@ -85,18 +85,18 @@ index 53dd02fd28..c999546e3f 100644 | |
@option{profile} sets the value of @emph{profile_idc} and the @emph{constraint_set*_flag}s. | ||
@option{level} sets the value of @emph{level_idc}. | ||
diff --git a/libavcodec/Makefile b/libavcodec/Makefile | ||
index 7761620de7..53684845c6 100644 | ||
index 94dc75a1b2..9d6e75c6df 100644 | ||
--- a/libavcodec/Makefile | ||
+++ b/libavcodec/Makefile | ||
@@ -245,6 +245,7 @@ OBJS-$(CONFIG_AURA2_DECODER) += aura.o | ||
OBJS-$(CONFIG_AV1_DECODER) += av1dec.o | ||
@@ -247,6 +247,7 @@ OBJS-$(CONFIG_AV1_DECODER) += av1dec.o | ||
OBJS-$(CONFIG_AV1_CUVID_DECODER) += cuviddec.o | ||
OBJS-$(CONFIG_AV1_NVENC_ENCODER) += nvenc_av1.o nvenc.o | ||
OBJS-$(CONFIG_AV1_QSV_ENCODER) += qsvenc_av1.o | ||
+OBJS-$(CONFIG_AV1_VAAPI_ENCODER) += vaapi_encode_av1.o av1_profile_level.o | ||
OBJS-$(CONFIG_AVRN_DECODER) += avrndec.o | ||
OBJS-$(CONFIG_AVRP_DECODER) += r210dec.o | ||
OBJS-$(CONFIG_AVRP_ENCODER) += r210enc.o | ||
@@ -1285,6 +1286,7 @@ TESTPROGS-$(CONFIG_H264_METADATA_BSF) += h264_levels | ||
@@ -1286,6 +1287,7 @@ TESTPROGS-$(CONFIG_H264_METADATA_BSF) += h264_levels | ||
TESTPROGS-$(CONFIG_HEVC_METADATA_BSF) += h265_levels | ||
TESTPROGS-$(CONFIG_RANGECODER) += rangecoder | ||
TESTPROGS-$(CONFIG_SNOW_ENCODER) += snowenc | ||
|
@@ -105,11 +105,11 @@ index 7761620de7..53684845c6 100644 | |
TESTOBJS = dctref.o | ||
|
||
diff --git a/libavcodec/allcodecs.c b/libavcodec/allcodecs.c | ||
index 4f1d66cb0c..9c3416bde3 100644 | ||
index f5ec3bc6e1..54cb833f09 100644 | ||
--- a/libavcodec/allcodecs.c | ||
+++ b/libavcodec/allcodecs.c | ||
@@ -829,6 +829,7 @@ extern const FFCodec ff_av1_decoder; | ||
extern const FFCodec ff_av1_cuvid_decoder; | ||
@@ -830,6 +830,7 @@ extern const FFCodec ff_av1_cuvid_decoder; | ||
extern const FFCodec ff_av1_nvenc_encoder; | ||
extern const FFCodec ff_av1_qsv_decoder; | ||
extern const FFCodec ff_av1_qsv_encoder; | ||
+extern const FFCodec ff_av1_vaapi_encoder; | ||
|
@@ -1859,5 +1859,5 @@ index aa199e0308..0d1fc96299 100644 | |
fate-iirfilter: libavcodec/tests/iirfilter$(EXESUF) | ||
fate-iirfilter: CMD = run libavcodec/tests/iirfilter$(EXESUF) | ||
-- | ||
2.34.1 | ||
2.25.1 | ||
|