diff options
author | James Almer <jamrial@gmail.com> | 2017-11-11 19:58:32 +0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-11-11 19:58:32 +0300 |
commit | d59efe4ca63dca54ab0ca0f8be77c1b59c79227a (patch) | |
tree | 6c783c8b07562e9c79b77361899bc6b776c16036 /libavcodec/qsvenc_hevc.c | |
parent | 460e7596cb5b1a449e50a7c3d2e6a5fff4a94c9a (diff) | |
parent | b05128f3c953bd66483e697d60a2e7e45ee9cfa0 (diff) |
Merge commit 'b05128f3c953bd66483e697d60a2e7e45ee9cfa0'
* commit 'b05128f3c953bd66483e697d60a2e7e45ee9cfa0':
qsv: Load the hw hevc plugin by default on Linux
Merged-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/qsvenc_hevc.c')
-rw-r--r-- | libavcodec/qsvenc_hevc.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libavcodec/qsvenc_hevc.c b/libavcodec/qsvenc_hevc.c index ff396b2784..a8b293e19c 100644 --- a/libavcodec/qsvenc_hevc.c +++ b/libavcodec/qsvenc_hevc.c @@ -214,12 +214,18 @@ static av_cold int qsv_enc_close(AVCodecContext *avctx) return ff_qsv_enc_close(avctx, &q->qsv); } +#if defined(_WIN32) +#define LOAD_PLUGIN_DEFAULT LOAD_PLUGIN_HEVC_SW +#else +#define LOAD_PLUGIN_DEFAULT LOAD_PLUGIN_HEVC_HW +#endif + #define OFFSET(x) offsetof(QSVHEVCEncContext, x) #define VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM static const AVOption options[] = { QSV_COMMON_OPTS - { "load_plugin", "A user plugin to load in an internal session", OFFSET(load_plugin), AV_OPT_TYPE_INT, { .i64 = LOAD_PLUGIN_HEVC_SW }, LOAD_PLUGIN_NONE, LOAD_PLUGIN_HEVC_HW, VE, "load_plugin" }, + { "load_plugin", "A user plugin to load in an internal session", OFFSET(load_plugin), AV_OPT_TYPE_INT, { .i64 = LOAD_PLUGIN_DEFAULT }, LOAD_PLUGIN_NONE, LOAD_PLUGIN_HEVC_HW, VE, "load_plugin" }, { "none", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = LOAD_PLUGIN_NONE }, 0, 0, VE, "load_plugin" }, { "hevc_sw", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = LOAD_PLUGIN_HEVC_SW }, 0, 0, VE, "load_plugin" }, { "hevc_hw", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = LOAD_PLUGIN_HEVC_HW }, 0, 0, VE, "load_plugin" }, |