app,pdb: Sort compatibility wrappers in alphabetical order

This commit is contained in:
Téo Mazars 2013-10-11 07:59:06 +02:00
parent 7be0e1c747
commit 786b21ee10
2 changed files with 241 additions and 241 deletions

View File

@ -433,43 +433,6 @@ plug_in_cubism_invoker (GimpProcedure *procedure,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_laplace_invoker (GimpProcedure *procedure,
Gimp *gimp,
GimpContext *context,
GimpProgress *progress,
const GimpValueArray *args,
GError **error)
{
gboolean success = TRUE;
GimpDrawable *drawable;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
if (success)
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:edge-laplace",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Laplace"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
return gimp_procedure_get_return_values (procedure, success,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_hsv_noise_invoker (GimpProcedure *procedure,
Gimp *gimp,
@ -524,6 +487,81 @@ plug_in_hsv_noise_invoker (GimpProcedure *procedure,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_laplace_invoker (GimpProcedure *procedure,
Gimp *gimp,
GimpContext *context,
GimpProgress *progress,
const GimpValueArray *args,
GError **error)
{
gboolean success = TRUE;
GimpDrawable *drawable;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
if (success)
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:edge-laplace",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Laplace"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
return gimp_procedure_get_return_values (procedure, success,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_make_seamless_invoker (GimpProcedure *procedure,
Gimp *gimp,
GimpContext *context,
GimpProgress *progress,
const GimpValueArray *args,
GError **error)
{
gboolean success = TRUE;
GimpDrawable *drawable;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
if (success)
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:tile-seamless",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Tile Seamless"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
return gimp_procedure_get_return_values (procedure, success,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_mblur_invoker (GimpProcedure *procedure,
Gimp *gimp,
@ -1349,44 +1387,6 @@ plug_in_threshold_alpha_invoker (GimpProcedure *procedure,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_make_seamless_invoker (GimpProcedure *procedure,
Gimp *gimp,
GimpContext *context,
GimpProgress *progress,
const GimpValueArray *args,
GError **error)
{
gboolean success = TRUE;
GimpDrawable *drawable;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
if (success)
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:tile-seamless",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Tile Seamless"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
return gimp_procedure_get_return_values (procedure, success,
error ? *error : NULL);
}
static GimpValueArray *
plug_in_vinvert_invoker (GimpProcedure *procedure,
Gimp *gimp,
@ -1938,42 +1938,6 @@ register_plug_in_compat_procs (GimpPDB *pdb)
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-laplace
*/
procedure = gimp_procedure_new (plug_in_laplace_invoker);
gimp_object_set_static_name (GIMP_OBJECT (procedure),
"plug-in-laplace");
gimp_procedure_set_static_strings (procedure,
"plug-in-laplace",
"High-resolution edge detection",
"This plugin creates one-pixel wide edges from the image, with the value proportional to the gradient. It uses the Laplace operator (a 3x3 kernel with -8 in the middle). The image has to be laplacered to get useful results, a gauss_iir with 1.5 - 5.0 depending on the noise in the image is best.",
"Compatibility procedure. Please see 'gegl:edge-laplace' for credits.",
"Compatibility procedure. Please see 'gegl:edge-laplace' for credits.",
"2013",
NULL);
gimp_procedure_add_argument (procedure,
g_param_spec_enum ("run-mode",
"run mode",
"The run mode",
GIMP_TYPE_RUN_MODE,
GIMP_RUN_INTERACTIVE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_image_id ("image",
"image",
"Input image (unused)",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_drawable_id ("drawable",
"drawable",
"Input drawable",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-hsv-noise
*/
@ -2034,6 +1998,78 @@ register_plug_in_compat_procs (GimpPDB *pdb)
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-laplace
*/
procedure = gimp_procedure_new (plug_in_laplace_invoker);
gimp_object_set_static_name (GIMP_OBJECT (procedure),
"plug-in-laplace");
gimp_procedure_set_static_strings (procedure,
"plug-in-laplace",
"High-resolution edge detection",
"This plugin creates one-pixel wide edges from the image, with the value proportional to the gradient. It uses the Laplace operator (a 3x3 kernel with -8 in the middle). The image has to be laplacered to get useful results, a gauss_iir with 1.5 - 5.0 depending on the noise in the image is best.",
"Compatibility procedure. Please see 'gegl:edge-laplace' for credits.",
"Compatibility procedure. Please see 'gegl:edge-laplace' for credits.",
"2013",
NULL);
gimp_procedure_add_argument (procedure,
g_param_spec_enum ("run-mode",
"run mode",
"The run mode",
GIMP_TYPE_RUN_MODE,
GIMP_RUN_INTERACTIVE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_image_id ("image",
"image",
"Input image (unused)",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_drawable_id ("drawable",
"drawable",
"Input drawable",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-make-seamless
*/
procedure = gimp_procedure_new (plug_in_make_seamless_invoker);
gimp_object_set_static_name (GIMP_OBJECT (procedure),
"plug-in-make-seamless");
gimp_procedure_set_static_strings (procedure,
"plug-in-make-seamless",
"Alters edges to make the image seamlessly tileable",
"This plugin creates a seamless tileable from the input drawable.",
"Compatibility procedure. Please see 'gegl:tile-seamless' for credits.",
"Compatibility procedure. Please see 'gegl:tile-seamless' for credits.",
"2013",
NULL);
gimp_procedure_add_argument (procedure,
g_param_spec_enum ("run-mode",
"run mode",
"The run mode",
GIMP_TYPE_RUN_MODE,
GIMP_RUN_INTERACTIVE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_image_id ("image",
"image",
"Input image (unused)",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_drawable_id ("drawable",
"drawable",
"Input drawable",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-mblur
*/
@ -2874,42 +2910,6 @@ register_plug_in_compat_procs (GimpPDB *pdb)
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-make-seamless
*/
procedure = gimp_procedure_new (plug_in_make_seamless_invoker);
gimp_object_set_static_name (GIMP_OBJECT (procedure),
"plug-in-make-seamless");
gimp_procedure_set_static_strings (procedure,
"plug-in-make-seamless",
"Alters edges to make the image seamlessly tileable",
"This plugin creates a seamless tileable from the input drawable.",
"Compatibility procedure. Please see 'gegl:tile-seamless' for credits.",
"Compatibility procedure. Please see 'gegl:tile-seamless' for credits.",
"2013",
NULL);
gimp_procedure_add_argument (procedure,
g_param_spec_enum ("run-mode",
"run mode",
"The run mode",
GIMP_TYPE_RUN_MODE,
GIMP_RUN_INTERACTIVE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_image_id ("image",
"image",
"Input image (unused)",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
gimp_param_spec_drawable_id ("drawable",
"drawable",
"Input drawable",
pdb->gimp, FALSE,
GIMP_PARAM_READWRITE));
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
/*
* gimp-plug-in-vinvert
*/

View File

@ -437,54 +437,6 @@ CODE
);
}
sub plug_in_laplace {
$blurb = 'High-resolution edge detection';
$help = <<'HELP';
This plugin creates one-pixel wide edges from the
image, with the value proportional to the gradient.
It uses the Laplace operator (a 3x3 kernel with -8
in the middle). The image has to be laplacered to
get useful results, a gauss_iir with 1.5 - 5.0
depending on the noise in the image is best.
HELP
&std_pdb_compat('gegl:edge-laplace');
$date = '2013';
@inargs = (
{ name => 'run_mode', type => 'enum GimpRunMode', dead => 1,
desc => 'The run mode' },
{ name => 'image', type => 'image', dead => 1,
desc => 'Input image (unused)' },
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' }
);
%invoke = (
code => <<'CODE'
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:edge-laplace",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Laplace"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
CODE
);
}
sub plug_in_hsv_noise {
$blurb = 'Randomize hue, saturation and value independently';
@ -546,6 +498,98 @@ CODE
);
}
sub plug_in_laplace {
$blurb = 'High-resolution edge detection';
$help = <<'HELP';
This plugin creates one-pixel wide edges from the
image, with the value proportional to the gradient.
It uses the Laplace operator (a 3x3 kernel with -8
in the middle). The image has to be laplacered to
get useful results, a gauss_iir with 1.5 - 5.0
depending on the noise in the image is best.
HELP
&std_pdb_compat('gegl:edge-laplace');
$date = '2013';
@inargs = (
{ name => 'run_mode', type => 'enum GimpRunMode', dead => 1,
desc => 'The run mode' },
{ name => 'image', type => 'image', dead => 1,
desc => 'Input image (unused)' },
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' }
);
%invoke = (
code => <<'CODE'
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:edge-laplace",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Laplace"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
CODE
);
}
sub plug_in_make_seamless {
$blurb = 'Alters edges to make the image seamlessly tileable';
$help = <<'HELP';
This plugin creates a seamless tileable from the input drawable.
HELP
&std_pdb_compat('gegl:tile-seamless');
$date = '2013';
@inargs = (
{ name => 'run_mode', type => 'enum GimpRunMode', dead => 1,
desc => 'The run mode' },
{ name => 'image', type => 'image', dead => 1,
desc => 'Input image (unused)' },
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' }
);
%invoke = (
code => <<'CODE'
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:tile-seamless",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Tile Seamless"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
CODE
);
}
sub plug_in_mblur {
$blurb = 'Simulate movement using directional blur';
@ -1482,50 +1526,6 @@ CODE
);
}
sub plug_in_make_seamless {
$blurb = 'Alters edges to make the image seamlessly tileable';
$help = <<'HELP';
This plugin creates a seamless tileable from the input drawable.
HELP
&std_pdb_compat('gegl:tile-seamless');
$date = '2013';
@inargs = (
{ name => 'run_mode', type => 'enum GimpRunMode', dead => 1,
desc => 'The run mode' },
{ name => 'image', type => 'image', dead => 1,
desc => 'Input image (unused)' },
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' }
);
%invoke = (
code => <<'CODE'
{
if (gimp_pdb_item_is_attached (GIMP_ITEM (drawable), NULL,
GIMP_PDB_ITEM_CONTENT, error) &&
gimp_pdb_item_is_not_group (GIMP_ITEM (drawable), error))
{
GeglNode *node =
gegl_node_new_child (NULL,
"operation", "gegl:tile-seamless",
NULL);
gimp_drawable_apply_operation (drawable, progress,
C_("undo-type", "Tile Seamless"),
node);
g_object_unref (node);
}
else
success = FALSE;
}
CODE
);
}
sub plug_in_vinvert {
$blurb = 'Invert the brightness of each pixel';
@ -1724,8 +1724,9 @@ CODE
plug_in_colors_channel_mixer
plug_in_colortoalpha
plug_in_cubism
plug_in_laplace
plug_in_hsv_noise
plug_in_laplace
plug_in_make_seamless
plug_in_mblur
plug_in_mblur_inward
plug_in_mosaic
@ -1741,7 +1742,6 @@ CODE
plug_in_shift
plug_in_spread
plug_in_threshold_alpha
plug_in_make_seamless
plug_in_vinvert
plug_in_waves
plug_in_whirl_pinch);