This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch master
in repository ffmpeg.

The following commit(s) were added to refs/heads/master by this push:
     new 09219cc683 swscale: print the effective scaler with SWS_PRINT_INFO
09219cc683 is described below

commit 09219cc6832671211c1963da0e27181d7bea62e5
Author:     Ayoub Nabil Boubagrat 
<[email protected]>
AuthorDate: Tue Aug 4 17:14:22 2026 +0200
Commit:     michaelni <[email protected]>
CommitDate: Tue Aug 25 16:06:34 2026 +0000

    swscale: print the effective scaler with SWS_PRINT_INFO
    
    use the resolved luma scaler for the log. keep the SWS_BICUBLIN description 
only when chroma is actually bilinear.
    
    add coverage for scaler_sub overrides and the missing FATE dependency. this 
fixes the incorrect scaler output reported in #23975.
    
    Signed-off-by: Ayoub Nabil Boubagrat 
<[email protected]>
---
 libswscale/utils.c          |  5 ++++-
 tests/fate/filter-video.mak | 11 +++++++++++
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/libswscale/utils.c b/libswscale/utils.c
index f5a992388b..59b6776f6a 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -1232,6 +1232,9 @@ av_cold int ff_sws_init_single_context(SwsContext *sws, 
SwsFilter *srcFilter,
     SwsScaler scaler_sub = sws->scaler_sub ? sws->scaler_sub : sws->scaler;
     int lum_scaler = scaler_flag(sws->scaler, i == SWS_BICUBLIN ? SWS_BICUBIC  
: i);
     int chr_scaler = scaler_flag(scaler_sub,  i == SWS_BICUBLIN ? SWS_BILINEAR 
: i);
+    const int info_scaler = sws->scaler == SWS_SCALE_AUTO &&
+                            i == SWS_BICUBLIN &&
+                            chr_scaler == SWS_BILINEAR ? i : lum_scaler;
 
     /* sanity check */
     if (srcW < 1 || srcH < 1 || dstW < 1 || dstH < 1) {
@@ -1757,7 +1760,7 @@ av_cold int ff_sws_init_single_context(SwsContext *sws, 
SwsFilter *srcFilter,
         const char *scaler = NULL, *cpucaps;
 
         for (i = 0; i < FF_ARRAY_ELEMS(scale_algorithms); i++) {
-            if (flags & scale_algorithms[i].flag) {
+            if (info_scaler == scale_algorithms[i].flag) {
                 scaler = scale_algorithms[i].description;
                 break;
             }
diff --git a/tests/fate/filter-video.mak b/tests/fate/filter-video.mak
index e0decc9b78..e2164de1c4 100644
--- a/tests/fate/filter-video.mak
+++ b/tests/fate/filter-video.mak
@@ -549,6 +549,17 @@ FATE_FILTER_VSYNTH-$(call FILTERDEMDEC, SCALE, RAWVIDEO, 
RAWVIDEO) += fate-filte
 fate-filter-scalechroma: tests/data/vsynth1.yuv
 fate-filter-scalechroma: CMD = framecrc -flags bitexact -s 352x288 -pix_fmt 
yuv444p -i $(TARGET_PATH)/tests/data/vsynth1.yuv -pix_fmt yuv420p -sws_flags 
+bitexact -vf scale=out_chroma_loc=bottomleft
 
+FATE_FILTER-$(call ALLYES, SCALE_FILTER TESTSRC2_FILTER LAVFI_INDEV \
+                           WRAPPED_AVFRAME_DECODER WRAPPED_AVFRAME_ENCODER \
+                           NULL_MUXER) += fate-filter-scale-print-info \
+                                          fate-filter-scale-print-info-sub
+fate-filter-scale-print-info: CMD = run $(FFMPEG) -nostdin -hide_banner 
-filter_threads 1 -f lavfi -i "testsrc2=s=16x16:d=0.04" -vf 
"scale=32:32:flags=+print_info:scaler=lanczos" -frames:v 1 -f null -
+fate-filter-scale-print-info: CMP = grep
+fate-filter-scale-print-info: REF = Lanczos scaler
+fate-filter-scale-print-info-sub: CMD = run $(FFMPEG) -nostdin -hide_banner 
-filter_threads 1 -f lavfi -i "testsrc2=s=16x16:d=0.04" -vf 
"scale=32:32:flags=bicublin+print_info:scaler_sub=lanczos" -frames:v 1 -f null -
+fate-filter-scale-print-info-sub: CMP = grep
+fate-filter-scale-print-info-sub: REF = bicubic scaler
+
 # Regression test: cascaded scale=...:-2 on extreme aspect ratios could
 # previously produce zero output dimensions, silently accepted by scale
 # filter and potentially hanging downstream encoders (issue #22817).

-- 
To stop receiving notification emails like this one, please contact
[email protected].
_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to