예제 #1
0
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process = operation_process;
  operation_class->prepare = prepare;

  operation_class->compat_name = "gegl:hard-light";
  gegl_operation_class_set_keys (operation_class,
  "name"        , "svg:hard-light",
  "description" ,
        _("SVG blend operation hard-light (<code>if 2 * cA < aA: d = 2 * cA * cB + cA * (1 - aB) + cB * (1 - aA) otherwise: d = aA * aB - 2 * (aB - cB) * (aA - cA) + cA * (1 - aB) + cB * (1 - aA)</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #2
0
static void
gegl_chant_class_init (GeglChantClass *klass)
{
    GeglOperationClass              *operation_class;
    GeglOperationPointComposerClass *point_composer_class;

    operation_class = GEGL_OPERATION_CLASS (klass);
    point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

    point_composer_class->process = process;
    operation_class->prepare = prepare;

    gegl_operation_class_set_keys (operation_class,
                                   "name"       , "gegl:threshold",
                                   "categories" , "color",
                                   "description",
                                   _("Thresholds the image to white/black based on either the global value "
                                     "set in the value property, or per pixel from the aux input."),
                                   "cl-source"  , kernel_source,
                                   NULL);
}
예제 #3
0
파일: divide.c 프로젝트: jonnor/gegl
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class  = GEGL_OPERATION_CLASS (klass);
  point_composer_class     = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->prepare = prepare;

  gegl_operation_class_set_keys (operation_class,
  "name"        , "gegl:divide",
  "title"       , "Divide",
  "categories"  , "compositors:math",
  "reference-hash"  , "c3bd84f8a6b2c03a239f3f832597592c",
  "description" ,
       _("Math operation divide, performs the operation per pixel, using either the constant provided in 'value' or the corresponding pixel from the buffer on aux as operands. The result is the evaluation of the expression result = value==0.0f?0.0f:input/value"),
       NULL);
}
예제 #4
0
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process      = operation_process;
  operation_class->prepare      = prepare;

  gegl_operation_class_set_keys (operation_class,
  "name"        , "gegl:soft-light",
  "title"       , "Soft-light",
  "description" ,
        _("SVG blend operation soft-light (<code>if 2 * cA < aA: d = cB * (aA - (aB == 0 ? 1 : 1 - cB / aB) * (2 * cA - aA)) + cA * (1 - aB) + cB * (1 - aA); if 8 * cB <= aB: d = cB * (aA - (aB == 0 ? 1 : 1 - cB / aB) * (2 * cA - aA) * (aB == 0 ? 3 : 3 - 8 * cB / aB)) + cA * (1 - aB) + cB * (1 - aA); otherwise: d = (aA * cB + (aB == 0 ? 0 : sqrt (cB / aB) * aB - cB) * (2 * cA - aA)) + cA * (1 - aB) + cB * (1 - aA)</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #5
0
파일: screen.c 프로젝트: jonnor/gegl
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process      = operation_process;
  operation_class->prepare      = prepare;

  gegl_operation_class_set_keys (operation_class,
  "name"        , "svg:screen",
  "compat-name" , "gegl:screen",
  "reference-hash" , "dd4057b688a2721774557d5637e59a50",
  "description" ,
        _("SVG blend operation screen (<code>d = cA + cB - cA * cB</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #6
0
파일: color-burn.c 프로젝트: GNOME/gegl
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process      = operation_process;
  operation_class->prepare      = prepare;

  gegl_operation_class_set_keys (operation_class,
  "name"        , "svg:color-burn",
  "compat-name" , "gegl:color-burn",
  "title"       , "Color-burn",
  "description" ,
        _("SVG blend operation color-burn (<code>if cA * aB + cB * aA <= aA * aB: d = cA * (1 - aB) + cB * (1 - aA) otherwise: d = (cA == 0 ? 1 : (aA * (cA * aB + cB * aA - aA * aB) / cA) + cA * (1 - aB) + cB * (1 - aA))</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #7
0
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process = operation_process;
  operation_class->prepare = prepare;

  operation_class->compat_name = "gegl:exclusion";

  gegl_operation_class_set_keys (operation_class,
  "name"        , "svg:exclusion",
  "description" ,
        _("SVG blend operation exclusion (<code>d = (cA * aB + cB * aA - 2 * cA * cB) + cA * (1 - aB) + cB * (1 - aA)</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #8
0
파일: xor.c 프로젝트: ChristianBusch/gegl
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->prepare = prepare;


  gegl_operation_class_set_keys (operation_class,
    "name"       , "svg:xor",
    "compat-name", "gegl:xor",
    "categories" , "compositors:porter-duff",
    "description",
        _("Porter Duff operation xor (d = cA * (1.0f - aB)+ cB * (1.0f - aA))"),
        NULL);
 

}
예제 #9
0
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->process      = operation_process;
  operation_class->prepare      = prepare;

  gegl_operation_class_set_keys (operation_class,
  "name"        , "svg:overlay",
  "compat-name" , "gegl:overlay",
  "title"       , "Overlay",
  "reference-hash" , "0148854c1b7d80cca8f015e216ce8fa3",
  "description" ,
        _("SVG blend operation overlay (<code>if 2 * cB > aB: d = 2 * cA * cB + cA * (1 - aB) + cB * (1 - aA) otherwise: d = aA * aB - 2 * (aB - cB) * (aA - cA) + cA * (1 - aB) + cB * (1 - aA)</code>)"),
        NULL);
  gegl_operation_class_set_key (operation_class, "categories", "compositors:svgfilter");
}
예제 #10
0
파일: over.c 프로젝트: dankamongmen/gegl
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);
  operation_class->prepare = prepare;
  operation_class->process = operation_process;

  point_composer_class->process = process;

  operation_class->compat_name = "gegl:over";

  gegl_operation_class_set_keys (operation_class,
    "name"       , "svg:src-over",
    "categories" , "compositors:porter-duff",
    "description",
          _("Porter Duff operation over (d = cA + cB * (1 - aA))"),
    "cl-source"  , svg_src_over_cl_source,
    NULL);
}
예제 #11
0
파일: opacity.c 프로젝트: dankamongmen/gegl
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  operation_class->prepare = prepare;
  operation_class->process = operation_process;
  point_composer_class->process = process;
  point_composer_class->cl_process = cl_process;

  operation_class->opencl_support = TRUE;

  gegl_operation_class_set_keys (operation_class,
    "name"       , "gegl:opacity",
    "categories" , "transparency",
    "description",
          _("Weights the opacity of the input both the value of the aux"
            " input and the global value property."),
    NULL);
}
예제 #12
0
파일: over.c 프로젝트: Distrotech/gegl
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);
  operation_class->prepare = prepare;
  operation_class->process = operation_process;

  point_composer_class->cl_process = cl_process;
  point_composer_class->process    = process;

  gegl_operation_class_set_keys (operation_class,
    "name"       , "svg:src-over",
    "title",       _("Normal compositing"),
    "compat-name", "gegl:over",
    "categories" , "compositors:porter-duff",
    "description",
          _("Porter Duff operation over (also known as normal mode, and src-over) (d = cA + cB * (1 - aA))"),
    "cl-source"  , svg_src_over_cl_source,
    NULL);
}
예제 #13
0
파일: dst-in.c 프로젝트: GNOME/gegl
static void
gegl_op_class_init (GeglOpClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->prepare = prepare;


  gegl_operation_class_set_keys (operation_class,
    "name"       , "svg:dst-in",
    "compat-name", "gegl:dst-in",
    "title"      , "Dst-in",
    "categories" , "compositors:porter-duff",
    "description",
        _("Porter Duff operation dst-in (d = cB * aA)"),
        NULL);
 

}
예제 #14
0
static void
gegl_chant_class_init (GeglChantClass *klass)
{
  GeglOperationClass              *operation_class;
  GeglOperationPointComposerClass *point_composer_class;

  operation_class      = GEGL_OPERATION_CLASS (klass);
  point_composer_class = GEGL_OPERATION_POINT_COMPOSER_CLASS (klass);

  point_composer_class->process = process;
  operation_class->prepare = prepare;


  operation_class->compat_name = "gegl:src-in";
  gegl_operation_class_set_keys (operation_class,
  "name"      , "svg:src-in",
  "get_bounding_box" , get_bounding_box,
  "categories", "compositors:porter-duff",
  "description" ,
        _("Porter Duff operation src-in (d = cA * aB)"),
        NULL);
 

}