[FFmpeg-devel] [PATCH 02/11] avfilter/overlay_vaapi: build filter params just once

softworkz ffmpegagent at gmail.com
Mon Oct 10 13:54:32 EEST 2022


From: softworkz <softworkz at hotmail.com>

Signed-off-by: softworkz <softworkz at hotmail.com>
---
 libavfilter/vf_overlay_vaapi.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libavfilter/vf_overlay_vaapi.c b/libavfilter/vf_overlay_vaapi.c
index 218daf571f..cf17426b5d 100644
--- a/libavfilter/vf_overlay_vaapi.c
+++ b/libavfilter/vf_overlay_vaapi.c
@@ -181,10 +181,6 @@ static int overlay_vaapi_blend(FFFrameSync *fs)
     VARectangle overlay_region, output_region;
     int err;
 
-    err = overlay_vaapi_build_filter_params(avctx);
-    if (err < 0)
-        return err;
-
     err = ff_framesync_get_frame(fs, 0, &input_main, 0);
     if (err < 0)
         return err;
@@ -309,6 +305,10 @@ static int overlay_vaapi_config_output(AVFilterLink *outlink)
     if (err < 0)
         return err;
 
+    err = overlay_vaapi_build_filter_params(avctx);
+    if (err < 0)
+        return err;
+
     err = ff_framesync_init_dualinput(&ctx->fs, avctx);
     if (err < 0)
         return err;
-- 
ffmpeg-codebot



More information about the ffmpeg-devel mailing list