[gegl] workshop: only scale the chromaticity components and not alpha channel



commit 6b7915d039bff389a4224c0facfdf3c055af7668
Author: Øyvind Kolås <pippin gimp org>
Date:   Sun Jun 30 13:15:38 2019 +0200

    workshop: only scale the chromaticity components and not alpha channel

 operations/workshop/saturation-yuv.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/operations/workshop/saturation-yuv.c b/operations/workshop/saturation-yuv.c
index df318259d..69ff2b2a2 100644
--- a/operations/workshop/saturation-yuv.c
+++ b/operations/workshop/saturation-yuv.c
@@ -30,7 +30,7 @@ property_double (scale, "Scale", 1.0)
 
 #define GEGL_OP_POINT_FILTER
 #define GEGL_OP_NAME     saturation_hue_constant2
-#define GEGL_OP_C_SOURCE saturation-yuv.c
+#define GEGL_OP_C_SOURCE saturation-foo.c
 
 #include "gegl-op.h"
 
@@ -62,9 +62,9 @@ process (GeglOperation       *operation,
   for (i = 0; i < n_pixels; i++)
     {
       out[0] = in[0];
-      out[1] = in[1] * scale;
-      out[2] = in[2] * scale;
-      out[3] = in[3] * scale;
+      out[1] = (in[1]) * scale;
+      out[2] = (in[2]) * scale;
+      out[3] = in[3];
 
       in += 4;
       out += 4;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]