diff options
author | James Almer <jamrial@gmail.com> | 2017-12-14 18:46:10 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-12-14 18:46:10 -0300 |
commit | f61cf0e4df52130c138ee55691409044ab2e9833 (patch) | |
tree | 8ad439a837c05114e50187b97446cfdbdc668cde /libavcodec/qsvenc.c | |
parent | 2ca3c049cd09527bafd48e50117283a6a965a1b2 (diff) | |
parent | 7c65a76b16bc3a44f1592acde2176f187a058797 (diff) | |
download | ffmpeg-f61cf0e4df52130c138ee55691409044ab2e9833.tar.gz |
Merge commit '7c65a76b16bc3a44f1592acde2176f187a058797'
* commit '7c65a76b16bc3a44f1592acde2176f187a058797':
lavc/qsvenc: add error messeage if ICQ unsupported.
Merged-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/qsvenc.c')
-rw-r--r-- | libavcodec/qsvenc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/libavcodec/qsvenc.c b/libavcodec/qsvenc.c index 74d901973b..d44bec3313 100644 --- a/libavcodec/qsvenc.c +++ b/libavcodec/qsvenc.c @@ -287,6 +287,12 @@ static int select_rc_mode(AVCodecContext *avctx, QSVEncContext *q) return AVERROR(EINVAL); } + if (!want_qscale && avctx->global_quality > 0 && !QSV_HAVE_ICQ){ + av_log(avctx, AV_LOG_ERROR, + "ICQ ratecontrol mode requested, but is not supported by this SDK version\n"); + return AVERROR(ENOSYS); + } + if (want_qscale) { rc_mode = MFX_RATECONTROL_CQP; rc_desc = "constant quantization parameter (CQP)"; |