[FFmpeg-cvslog] swscale: Remove duplicated code

Lauri Kasanen git at videolan.org
Wed Mar 27 08:57:36 EET 2019


ffmpeg | branch: master | Lauri Kasanen <cand at gmx.com> | Sun Mar 24 13:00:39 2019 +0200| [81a4719d8eaffd2e0251777cd121ecb54b239784] | committer: Lauri Kasanen

swscale: Remove duplicated code

In this function, the exact same clamping happens both in the if and unconditionally.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=81a4719d8eaffd2e0251777cd121ecb54b239784
---

 libswscale/output.c | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/libswscale/output.c b/libswscale/output.c
index d7c53e60d9..d3401f0cd1 100644
--- a/libswscale/output.c
+++ b/libswscale/output.c
@@ -853,11 +853,6 @@ yuv2422_1_c_template(SwsContext *c, const int16_t *buf0,
                 V  = av_clip_uint8(V);
             }
 
-            Y1 = av_clip_uint8(Y1);
-            Y2 = av_clip_uint8(Y2);
-            U  = av_clip_uint8(U);
-            V  = av_clip_uint8(V);
-
             output_pixels(i * 4, Y1, U, Y2, V);
         }
     } else {
@@ -875,11 +870,6 @@ yuv2422_1_c_template(SwsContext *c, const int16_t *buf0,
                 V  = av_clip_uint8(V);
             }
 
-            Y1 = av_clip_uint8(Y1);
-            Y2 = av_clip_uint8(Y2);
-            U  = av_clip_uint8(U);
-            V  = av_clip_uint8(V);
-
             output_pixels(i * 4, Y1, U, Y2, V);
         }
     }



More information about the ffmpeg-cvslog mailing list