[FFmpeg-devel] [PATCH] lavc/vaapi_encode_h264: Return AVERROR(ENOSYS)

Haihao Xiang haihao.xiang at intel.com
Tue Feb 13 10:23:22 EET 2018


The corresponding feature is not implemented for old versions of
VA-API, the returned value should be AVERROR(ENOSYS)

Signed-off-by: Haihao Xiang <haihao.xiang at intel.com>
---
 libavcodec/vaapi_encode_h264.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/vaapi_encode_h264.c b/libavcodec/vaapi_encode_h264.c
index a7f9a602533..6e2db4af070 100644
--- a/libavcodec/vaapi_encode_h264.c
+++ b/libavcodec/vaapi_encode_h264.c
@@ -942,7 +942,7 @@ static av_cold int vaapi_encode_h264_init(AVCodecContext *avctx)
 #else
         av_log(avctx, AV_LOG_ERROR, "Low-power encoding is not "
                "supported with this VAAPI version.\n");
-        return AVERROR(EINVAL);
+        return AVERROR(ENOSYS);
 #endif
     } else {
         ctx->va_entrypoint = VAEntrypointEncSlice;
-- 
2.14.1



More information about the ffmpeg-devel mailing list