On 24/09/2017 15:55, Luca Barbato wrote:
Should improve the performance on multiple transcoding from a single source. --- libavcodec/qsv.c | 2 ++ libavfilter/qsvvpp.c | 1 + 2 files changed, 3 insertions(+)diff --git a/libavcodec/qsv.c b/libavcodec/qsv.c index 56bfbb33d2..925dfaa4cc 100644 --- a/libavcodec/qsv.c +++ b/libavcodec/qsv.c @@ -594,6 +594,8 @@ int ff_qsv_init_session_device(AVCodecContext *avctx, mfxSession *psession, "Error setting a HW handle"); }+ MFXJoinSession(parent_session, session);+ ret = qsv_load_plugins(session, load_plugins, avctx); if (ret < 0) { av_log(avctx, AV_LOG_ERROR, "Error loading plugins\n"); diff --git a/libavfilter/qsvvpp.c b/libavfilter/qsvvpp.c index c70050822c..6a38e9f0f9 100644 --- a/libavfilter/qsvvpp.c +++ b/libavfilter/qsvvpp.c @@ -516,6 +516,7 @@ static int init_vpp_session(AVFilterContext *avctx, QSVVPPContext *s) if (ret != MFX_ERR_NONE) return AVERROR_UNKNOWN; } + MFXJoinSession(device_hwctx->session, s->session);if (IS_OPAQUE_MEMORY(s->in_mem_mode) || IS_OPAQUE_MEMORY(s->out_mem_mode)) {s->opaque_alloc.In.Surfaces = s->surface_ptrs_in;
As Chao mentioned it fails to join the session, but the error reported is: [h264_qsv @ 0x3250fa0] Error joining session: invalid handle (-6) lu _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
