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

Git pushed a commit to branch master
in repository ffmpeg.

commit 215cd902015fb693b1237d5b6d01db3a7086a1ef
Author:     Niklas Haas <[email protected]>
AuthorDate: Wed Apr 15 19:03:40 2026 +0200
Commit:     Niklas Haas <[email protected]>
CommitDate: Thu Apr 16 23:24:55 2026 +0200

    swscale/x86/ops: simplify DECL_DITHER definition
    
    This extra indirection boilerplate just for the 0-size fast path really 
isn't
    doing us any favors.
    
    Signed-off-by: Niklas Haas <[email protected]>
---
 libswscale/x86/ops.c | 28 +++++++++++++++++-----------
 1 file changed, 17 insertions(+), 11 deletions(-)

diff --git a/libswscale/x86/ops.c b/libswscale/x86/ops.c
index c3f5f50838..f3c20a9236 100644
--- a/libswscale/x86/ops.c
+++ b/libswscale/x86/ops.c
@@ -254,8 +254,14 @@ static int setup_dither(const SwsImplParams *params, 
SwsImplResult *out)
     return 0;
 }
 
-#define DECL_DITHER(DECL_MACRO, EXT, SIZE)                                     
 \
-    DECL_MACRO(F32, dither##SIZE##EXT,                                         
 \
+#define DECL_DITHER0(EXT)                                                      
 \
+    DECL_COMMON_PATTERNS(F32, dither0##EXT,                                    
 \
+        .op    = SWS_OP_DITHER,                                                
 \
+        .setup = setup_dither,                                                 
 \
+    );
+
+#define DECL_DITHER(EXT, SIZE)                                                 
 \
+    DECL_ASM(F32, dither##SIZE##EXT,                                           
 \
         .op    = SWS_OP_DITHER,                                                
 \
         .setup = setup_dither,                                                 
 \
         .dither_size = SIZE,                                                   
 \
@@ -726,15 +732,15 @@ static const SwsOpTable ops16##EXT = {
     DECL_EXPAND(EXT,   U8, U32)                                                
 \
     DECL_MIN_MAX(EXT)                                                          
 \
     DECL_SCALE(EXT)                                                            
 \
-    DECL_DITHER(DECL_COMMON_PATTERNS, EXT, 0)                                  
 \
-    DECL_DITHER(DECL_ASM, EXT, 1)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 2)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 3)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 4)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 5)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 6)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 7)                                              
 \
-    DECL_DITHER(DECL_ASM, EXT, 8)                                              
 \
+    DECL_DITHER0(EXT)                                                          
 \
+    DECL_DITHER(EXT, 1)                                                        
 \
+    DECL_DITHER(EXT, 2)                                                        
 \
+    DECL_DITHER(EXT, 3)                                                        
 \
+    DECL_DITHER(EXT, 4)                                                        
 \
+    DECL_DITHER(EXT, 5)                                                        
 \
+    DECL_DITHER(EXT, 6)                                                        
 \
+    DECL_DITHER(EXT, 7)                                                        
 \
+    DECL_DITHER(EXT, 8)                                                        
 \
     DECL_LINEAR(EXT, luma,      SWS_MASK_LUMA)                                 
 \
     DECL_LINEAR(EXT, alpha,     SWS_MASK_ALPHA)                                
 \
     DECL_LINEAR(EXT, lumalpha,  SWS_MASK_LUMA | SWS_MASK_ALPHA)                
 \

_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to