mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-26 17:32:06 +00:00
vf_scale_vaapi: Respect driver quirks around buffer destruction
This commit is contained in:
parent
221ffca631
commit
582d4211e0
@ -342,13 +342,14 @@ static int scale_vaapi_filter_frame(AVFilterLink *inlink, AVFrame *input_frame)
|
|||||||
goto fail_after_render;
|
goto fail_after_render;
|
||||||
}
|
}
|
||||||
|
|
||||||
// This doesn't get freed automatically for some reason.
|
if (ctx->hwctx->driver_quirks &
|
||||||
|
AV_VAAPI_DRIVER_QUIRK_RENDER_PARAM_BUFFERS) {
|
||||||
vas = vaDestroyBuffer(ctx->hwctx->display, params_id);
|
vas = vaDestroyBuffer(ctx->hwctx->display, params_id);
|
||||||
if (vas != VA_STATUS_SUCCESS) {
|
if (vas != VA_STATUS_SUCCESS) {
|
||||||
av_log(ctx, AV_LOG_ERROR, "Failed to free parameter buffer: "
|
av_log(ctx, AV_LOG_ERROR, "Failed to free parameter buffer: "
|
||||||
"%d (%s).\n", vas, vaErrorStr(vas));
|
"%d (%s).\n", vas, vaErrorStr(vas));
|
||||||
err = AVERROR(EIO);
|
// And ignore.
|
||||||
goto fail;
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
av_frame_copy_props(output_frame, input_frame);
|
av_frame_copy_props(output_frame, input_frame);
|
||||||
|
Loading…
Reference in New Issue
Block a user