Commit 4fa08458 authored by Michael Natterer's avatar Michael Natterer 😴

pdb: remove int16 from the PDB types and rename int8 to uchar

parent 652fd758
Pipeline #104848 passed with stages
in 26 minutes and 26 seconds
......@@ -405,10 +405,10 @@ plug_in_alienmap2_invoker (GimpProcedure *procedure,
gdouble greenangle;
gdouble bluefrequency;
gdouble blueangle;
guint8 colormodel;
guint8 redmode;
guint8 greenmode;
guint8 bluemode;
guchar colormodel;
guchar redmode;
guchar greenmode;
guchar bluemode;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
redfrequency = g_value_get_double (gimp_value_array_index (args, 3));
......@@ -1725,15 +1725,15 @@ plug_in_exchange_invoker (GimpProcedure *procedure,
{
gboolean success = TRUE;
GimpDrawable *drawable;
guint8 from_red;
guint8 from_green;
guint8 from_blue;
guint8 to_red;
guint8 to_green;
guint8 to_blue;
guint8 red_threshold;
guint8 green_threshold;
guint8 blue_threshold;
guchar from_red;
guchar from_green;
guchar from_blue;
guchar to_red;
guchar to_green;
guchar to_blue;
guchar red_threshold;
guchar green_threshold;
guchar blue_threshold;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
from_red = g_value_get_uchar (gimp_value_array_index (args, 3));
......@@ -2345,10 +2345,10 @@ plug_in_maze_invoker (GimpProcedure *procedure,
{
gboolean success = TRUE;
GimpDrawable *drawable;
gint16 width;
gint16 height;
guint8 tileable;
guint8 algorithm;
gint width;
gint height;
guchar tileable;
guchar algorithm;
gint seed;
drawable = gimp_value_get_drawable (gimp_value_array_index (args, 2), gimp);
......@@ -7056,13 +7056,13 @@ register_plug_in_compat_procs (GimpPDB *pdb)
g_param_spec_int ("multiple",
"multiple",
"Multiple (use 57)",
G_MININT16, G_MAXINT16, 0,
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
gimp_procedure_add_argument (procedure,
g_param_spec_int ("offset",
"offset",
"Offset (use 1)",
G_MININT16, G_MAXINT16, 0,
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
gimp_pdb_register_procedure (pdb, procedure);
g_object_unref (procedure);
......
......@@ -392,7 +392,7 @@ g_param_spec_int ("$name",
$flags)
CODE
}
elsif ($pdbtype eq 'int8') {
elsif ($pdbtype eq 'uchar') {
if (defined $typeinfo[0]) {
$min = ($typeinfo[1] eq '<') ? ($typeinfo[0] + 1) : $typeinfo[0];
}
......
......@@ -45,13 +45,13 @@ HELP
desc => 'Blue/luminance component frequency factor' },
{ name => 'blueangle', type => '0 <= float <= 360',
desc => 'Blue/luminance component angle factor (0-360)' },
{ name => 'colormodel', type => '0 <= int8 <= 1',
{ name => 'colormodel', type => '0 <= uchar <= 1',
desc => 'Color model { RGB-MODEL (0), HSL-MODEL (1) }' },
{ name => 'redmode', type => '0 <= int8 <= 1',
{ name => 'redmode', type => '0 <= uchar <= 1',
desc => 'Red/hue application mode { TRUE, FALSE }' },
{ name => 'greenmode', type => '0 <= int8 <= 1',
{ name => 'greenmode', type => '0 <= uchar <= 1',
desc => 'Green/saturation application mode { TRUE, FALSE }' },
{ name => 'bluemode', type => '0 <= int8 <= 1',
{ name => 'bluemode', type => '0 <= uchar <= 1',
desc => 'Blue/luminance application mode { TRUE, FALSE }' }
);
......@@ -1542,23 +1542,23 @@ HELP
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' },
{ name => 'from_red', type => 'int8',
{ name => 'from_red', type => 'uchar',
desc => 'Red value (from)' },
{ name => 'from_green', type => 'int8',
{ name => 'from_green', type => 'uchar',
desc => 'Green value (from)' },
{ name => 'from_blue', type => 'int8',
{ name => 'from_blue', type => 'uchar',
desc => 'Blue value (from)' },
{ name => 'to_red', type => 'int8',
{ name => 'to_red', type => 'uchar',
desc => 'Red value (to)' },
{ name => 'to_green', type => 'int8',
{ name => 'to_green', type => 'uchar',
desc => 'Green value (to)' },
{ name => 'to_blue', type => 'int8',
{ name => 'to_blue', type => 'uchar',
desc => 'Blue value (to)' },
{ name => 'red_threshold', type => 'int8',
{ name => 'red_threshold', type => 'uchar',
desc => 'Red threshold' },
{ name => 'green_threshold', type => 'int8',
{ name => 'green_threshold', type => 'uchar',
desc => 'Green threshold' },
{ name => 'blue_threshold', type => 'int8',
{ name => 'blue_threshold', type => 'uchar',
desc => 'Blue threshold' }
);
......@@ -2273,19 +2273,19 @@ HELP
desc => 'Input image (unused)' },
{ name => 'drawable', type => 'drawable',
desc => 'Input drawable' },
{ name => 'width', type => '1 <= int16 <= 1024',
{ name => 'width', type => '1 <= int32 <= 1024',
desc => 'Width of the passages' },
{ name => 'height', type => '1 <= int16 <= 1024',
{ name => 'height', type => '1 <= int32 <= 1024',
desc => 'Height of the passages' },
{ name => 'tileable', type => '0 <= int8 <= 1',
{ name => 'tileable', type => '0 <= uchar <= 1',
desc => 'Tileable maze? (TRUE or FALSE)' },
{ name => 'algorithm', type => '0 <= int8 <= 1',
{ name => 'algorithm', type => '0 <= uchar <= 1',
desc => 'Generation algorithm (0 = DEPTH FIRST, 1 = PRIM\'S ALGORITHM)' },
{ name => 'seed', type => 'int32',
desc => 'Random Seed' },
{ name => 'multiple', type => 'int16', dead => 1,
{ name => 'multiple', type => 'int32', dead => 1,
desc => 'Multiple (use 57)' },
{ name => 'offset', type => 'int16', dead => 1,
{ name => 'offset', type => 'int32', dead => 1,
desc => 'Offset (use 1)' }
);
......
......@@ -27,20 +27,10 @@ package Gimp::CodeGen::pdb;
set_value_func => 'g_value_set_int ($value, $var)',
take_value_func => 'g_value_set_int ($value, $var)' },
int16 => { name => 'INT16',
gtype => 'G_TYPE_INT',
type => 'gint16 ',
const_type => 'gint16 ',
init_value => '0',
get_value_func => '$var = g_value_get_int ($value)',
dup_value_func => '$var = g_value_get_int ($value)',
set_value_func => 'g_value_set_int ($value, $var)',
take_value_func => 'g_value_set_int ($value, $var)' },
int8 => { name => 'INT8',
uchar => { name => 'UCHAR',
gtype => 'G_TYPE_UCHAR',
type => 'guint8 ',
const_type => 'guint8 ',
type => 'guchar ',
const_type => 'guchar ',
init_value => '0',
get_value_func => '$var = g_value_get_uchar ($value)',
dup_value_func => '$var = g_value_get_uchar ($value)',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment