9fa5f4
From 72168aba34445e4cd99aaed32d8e6a80e89ce729 Mon Sep 17 00:00:00 2001
9fa5f4
From: Nils Philippsen <nils@redhat.com>
9fa5f4
Date: Mon, 1 Jul 2013 13:53:18 +0200
9fa5f4
Subject: [PATCH] patch: remove-src-over-op
9fa5f4
9fa5f4
Squashed commit of the following:
9fa5f4
9fa5f4
commit b766094d951bf1515a75408ee85d4e1af432e6bd
9fa5f4
Author: Daniel Sabo <DanielSabo@gmail.com>
9fa5f4
Date:   Tue Jun 4 20:57:03 2013 -0700
9fa5f4
9fa5f4
    Remove auto-generated svg:src-over
9fa5f4
9fa5f4
    It was already shadowed by gegl:over, which declares
9fa5f4
    svg:src-over as a compat-name.
9fa5f4
9fa5f4
    (cherry picked from commit c1caf2401271e8a17fd1937bf84279c250bd8e2a)
9fa5f4
9fa5f4
    Conflicts:
9fa5f4
    	po/POTFILES.in
9fa5f4
---
9fa5f4
 operations/generated/src-over.c            | 122 -----------------------------
9fa5f4
 operations/generated/svg-12-porter-duff.rb |   5 +-
9fa5f4
 po/POTFILES.in                             |   3 +-
9fa5f4
 3 files changed, 4 insertions(+), 126 deletions(-)
9fa5f4
 delete mode 100644 operations/generated/src-over.c
9fa5f4
9fa5f4
diff --git a/operations/generated/src-over.c b/operations/generated/src-over.c
9fa5f4
deleted file mode 100644
9fa5f4
index e586087..0000000
9fa5f4
--- a/operations/generated/src-over.c
9fa5f4
+++ /dev/null
9fa5f4
@@ -1,122 +0,0 @@
9fa5f4
-
9fa5f4
-/* !!!! AUTOGENERATED FILE generated by svg-12-porter-duff.rb !!!!!
9fa5f4
- *
9fa5f4
- * This file is an image processing operation for GEGL
9fa5f4
- *
9fa5f4
- * GEGL is free software; you can redistribute it and/or
9fa5f4
- * modify it under the terms of the GNU Lesser General Public
9fa5f4
- * License as published by the Free Software Foundation; either
9fa5f4
- * version 3 of the License, or (at your option) any later version.
9fa5f4
- *
9fa5f4
- * GEGL is distributed in the hope that it will be useful,
9fa5f4
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
9fa5f4
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
9fa5f4
- * Lesser General Public License for more details.
9fa5f4
- *
9fa5f4
- * You should have received a copy of the GNU Lesser General Public
9fa5f4
- * License along with GEGL; if not, see <http://www.gnu.org/licenses/>.
9fa5f4
- *
9fa5f4
- *  Copyright 2006, 2007 Øyvind Kolås <pippin@gimp.org>
9fa5f4
- *            2007 John Marshall
9fa5f4
- *
9fa5f4
- * SVG rendering modes; see:
9fa5f4
- *     http://www.w3.org/TR/SVG12/rendering.html
9fa5f4
- *     http://www.w3.org/TR/2004/WD-SVG12-20041027/rendering.html#comp-op-prop
9fa5f4
- *
9fa5f4
- *     aA = aux(src) alpha      aB = in(dst) alpha      aD = out alpha
9fa5f4
- *     cA = aux(src) colour     cB = in(dst) colour     cD = out colour
9fa5f4
- *
9fa5f4
- * !!!! AUTOGENERATED FILE !!!!!
9fa5f4
- */
9fa5f4
-#include "config.h"
9fa5f4
-#include <glib/gi18n-lib.h>
9fa5f4
-
9fa5f4
-
9fa5f4
-#ifdef GEGL_CHANT_PROPERTIES
9fa5f4
-
9fa5f4
-/* no properties */
9fa5f4
-
9fa5f4
-#else
9fa5f4
-
9fa5f4
-#define GEGL_CHANT_TYPE_POINT_COMPOSER
9fa5f4
-#define GEGL_CHANT_C_FILE        "src-over.c"
9fa5f4
-
9fa5f4
-#include "gegl-chant.h"
9fa5f4
-
9fa5f4
-static void prepare (GeglOperation *operation)
9fa5f4
-{
9fa5f4
-  const Babl *format = babl_format ("RaGaBaA float");
9fa5f4
-
9fa5f4
-  gegl_operation_set_format (operation, "input", format);
9fa5f4
-  gegl_operation_set_format (operation, "aux", format);
9fa5f4
-  gegl_operation_set_format (operation, "output", format);
9fa5f4
-}
9fa5f4
-
9fa5f4
-static gboolean
9fa5f4
-process (GeglOperation        *op,
9fa5f4
-          void                *in_buf,
9fa5f4
-          void                *aux_buf,
9fa5f4
-          void                *out_buf,
9fa5f4
-          glong                n_pixels,
9fa5f4
-          const GeglRectangle *roi,
9fa5f4
-          gint                 level)
9fa5f4
-{
9fa5f4
-  gint i;
9fa5f4
-  gfloat * GEGL_ALIGNED in = in_buf;
9fa5f4
-  gfloat * GEGL_ALIGNED aux = aux_buf;
9fa5f4
-  gfloat * GEGL_ALIGNED out = out_buf;
9fa5f4
-
9fa5f4
-  if (aux==NULL)
9fa5f4
-    return TRUE;
9fa5f4
-
9fa5f4
-  for (i = 0; i < n_pixels; i++)
9fa5f4
-    {
9fa5f4
-      gint   j;
9fa5f4
-      gfloat aA G_GNUC_UNUSED, aB G_GNUC_UNUSED, aD G_GNUC_UNUSED;
9fa5f4
-
9fa5f4
-      aB = in[3];
9fa5f4
-      aA = aux[3];
9fa5f4
-      aD = aA + aB - aA * aB;
9fa5f4
-
9fa5f4
-      for (j = 0; j < 3; j++)
9fa5f4
-        {
9fa5f4
-          gfloat cA G_GNUC_UNUSED, cB G_GNUC_UNUSED;
9fa5f4
-
9fa5f4
-          cB = in[j];
9fa5f4
-          cA = aux[j];
9fa5f4
-          out[j] = cA + cB * (1.0f - aA);
9fa5f4
-        }
9fa5f4
-      out[3] = aD;
9fa5f4
-      in  += 4;
9fa5f4
-      aux += 4;
9fa5f4
-      out += 4;
9fa5f4
-    }
9fa5f4
-  return TRUE;
9fa5f4
-}
9fa5f4
-
9fa5f4
-
9fa5f4
-static void
9fa5f4
-gegl_chant_class_init (GeglChantClass *klass)
9fa5f4
-{
9fa5f4
-  GeglOperationClass              *operation_class;
9fa5f4
-  GeglOperationPointComposerClass *point_composer_class;
9fa5f4
-
9fa5f4
-  operation_class      = GEGL_OPERATION_CLASS (klass);
9fa5f4
-  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);
9fa5f4
-
9fa5f4
-  point_composer_class->process = process;
9fa5f4
-  operation_class->prepare = prepare;
9fa5f4
-
9fa5f4
-
9fa5f4
-  operation_class->compat_name = "gegl:src-over";
9fa5f4
-  gegl_operation_class_set_keys (operation_class,
9fa5f4
-    "name"      , "svg:src-over",
9fa5f4
-    "categories", "compositors:porter-duff",
9fa5f4
-    "description",
9fa5f4
-        _("Porter Duff operation src-over (d = cA + cB * (1.0f - aA))"),
9fa5f4
-        NULL);
9fa5f4
- 
9fa5f4
-
9fa5f4
-}
9fa5f4
-
9fa5f4
-#endif
9fa5f4
diff --git a/operations/generated/svg-12-porter-duff.rb b/operations/generated/svg-12-porter-duff.rb
9fa5f4
index 5516802..dab5d2f 100755
9fa5f4
--- a/operations/generated/svg-12-porter-duff.rb
9fa5f4
+++ b/operations/generated/svg-12-porter-duff.rb
9fa5f4
@@ -1,4 +1,5 @@
9fa5f4
 #!/usr/bin/env ruby
9fa5f4
+# encoding: utf-8
9fa5f4
 
9fa5f4
 copyright = '
9fa5f4
 /* !!!! AUTOGENERATED FILE generated by svg-12-porter-duff.rb !!!!!
9fa5f4
@@ -38,8 +39,8 @@ a = [
9fa5f4
                         'aA'],
9fa5f4
       ['dst',           'cB',
9fa5f4
                         'aB'],
9fa5f4
-      ['src_over',      'cA + cB * (1.0f - aA)',
9fa5f4
-                        'aA + aB - aA * aB'],
9fa5f4
+#      ['src_over',      'cA + cB * (1.0f - aA)',
9fa5f4
+#                        'aA + aB - aA * aB'],
9fa5f4
       ['dst_over',      'cB + cA * (1.0f - aB)',
9fa5f4
                         'aA + aB - aA * aB'],
9fa5f4
       ['dst_in',        'cB * aA', # <- XXX: typo?
9fa5f4
diff --git a/po/POTFILES.in b/po/POTFILES.in
9fa5f4
index e309594..d36cbc2 100644
9fa5f4
--- a/po/POTFILES.in
9fa5f4
+++ b/po/POTFILES.in
9fa5f4
@@ -115,10 +115,9 @@ operations/generated/plus.c
9fa5f4
 operations/generated/screen.c
9fa5f4
 operations/generated/soft-light.c
9fa5f4
 operations/generated/src-atop.c
9fa5f4
+operations/generated/src.c
9fa5f4
 operations/generated/src-in.c
9fa5f4
 operations/generated/src-out.c
9fa5f4
-operations/generated/src-over.c
9fa5f4
-operations/generated/src.c
9fa5f4
 operations/generated/subtract.c
9fa5f4
 operations/generated/svg-multiply.c
9fa5f4
 operations/generated/xor.c
9fa5f4
-- 
9fa5f4
1.8.3.1
9fa5f4