Commit b9a066ae authored by Zhong Li's avatar Zhong Li

lavc/qsvenc: use the common option "trellis" of AVCodecContext

Signed-off-by: 's avatarZhong Li <zhong.li@intel.com>
parent 4131b061
...@@ -683,7 +683,10 @@ FF_ENABLE_DEPRECATION_WARNINGS ...@@ -683,7 +683,10 @@ FF_ENABLE_DEPRECATION_WARNINGS
#endif #endif
#if QSV_HAVE_TRELLIS #if QSV_HAVE_TRELLIS
q->extco2.Trellis = q->trellis; if (avctx->trellis >= 0)
q->extco2.Trellis = (avctx->trellis == 0) ? MFX_TRELLIS_OFF : (MFX_TRELLIS_I | MFX_TRELLIS_P | MFX_TRELLIS_B);
else
q->extco2.Trellis = MFX_TRELLIS_UNKNOWN;
#endif #endif
#if QSV_VERSION_ATLEAST(1, 8) #if QSV_VERSION_ATLEAST(1, 8)
......
...@@ -181,7 +181,7 @@ static const AVCodecDefault qsv_enc_defaults[] = { ...@@ -181,7 +181,7 @@ static const AVCodecDefault qsv_enc_defaults[] = {
#if FF_API_CODER_TYPE #if FF_API_CODER_TYPE
{ "coder", "-1" }, { "coder", "-1" },
#endif #endif
{ "trellis", "-1" },
{ "flags", "+cgop" }, { "flags", "+cgop" },
#if FF_API_PRIVATE_OPT #if FF_API_PRIVATE_OPT
{ "b_strategy", "-1" }, { "b_strategy", "-1" },
......
...@@ -254,7 +254,7 @@ static const AVCodecDefault qsv_enc_defaults[] = { ...@@ -254,7 +254,7 @@ static const AVCodecDefault qsv_enc_defaults[] = {
// same as the x264 default // same as the x264 default
{ "g", "248" }, { "g", "248" },
{ "bf", "8" }, { "bf", "8" },
{ "trellis", "-1" },
{ "flags", "+cgop" }, { "flags", "+cgop" },
#if FF_API_PRIVATE_OPT #if FF_API_PRIVATE_OPT
{ "b_strategy", "-1" }, { "b_strategy", "-1" },
......
...@@ -87,7 +87,7 @@ static const AVCodecDefault qsv_enc_defaults[] = { ...@@ -87,7 +87,7 @@ static const AVCodecDefault qsv_enc_defaults[] = {
// same as the x264 default // same as the x264 default
{ "g", "250" }, { "g", "250" },
{ "bf", "3" }, { "bf", "3" },
{ "trellis", "-1" },
{ "flags", "+cgop" }, { "flags", "+cgop" },
#if FF_API_PRIVATE_OPT #if FF_API_PRIVATE_OPT
{ "b_strategy", "-1" }, { "b_strategy", "-1" },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment