diff --git a/ChangeLog b/ChangeLog index 81cedd16d6..e95db8ba2b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Nov 9 11:33:03 PST 1999 Manish Singh + + * tools/pdbgen/pdb/drawable.pdb: fix {get,set}_pixel typo reported + by Tamito KAJIYAMA + Tue Nov 9 15:08:13 MET 1999 Sven Neumann * app/fileops.c: diff --git a/app/drawable_cmds.c b/app/drawable_cmds.c index 495a05800d..b6fa963bcd 100644 --- a/app/drawable_cmds.c +++ b/app/drawable_cmds.c @@ -332,7 +332,7 @@ drawable_image_invoker (Argument *args) gboolean success = TRUE; Argument *return_args; GimpDrawable *drawable; - GimpImage *gimage; + GimpImage *gimage = NULL; drawable = gimp_drawable_get_ID (args[0].value.pdb_int); if (drawable == NULL) @@ -1062,7 +1062,7 @@ drawable_get_pixel_invoker (Argument *args) x %= TILE_WIDTH; y %= TILE_WIDTH; - p = tile_data_pointer (tile, y, x); + p = tile_data_pointer (tile, x, y); for (b = 0; b < num_channels; b++) pixel[b] = p[b]; @@ -1172,7 +1172,7 @@ drawable_set_pixel_invoker (Argument *args) x %= TILE_WIDTH; y %= TILE_WIDTH; - p = tile_data_pointer (tile, y, x); + p = tile_data_pointer (tile, x, y); for (b = 0; b < num_channels; b++) *p++ = *pixel++; diff --git a/tools/pdbgen/pdb/drawable.pdb b/tools/pdbgen/pdb/drawable.pdb index 0fec6933f1..f74907d8b3 100644 --- a/tools/pdbgen/pdb/drawable.pdb +++ b/tools/pdbgen/pdb/drawable.pdb @@ -212,6 +212,7 @@ sub drawable_image { @outargs = ( &std_image_arg ); $outargs[0]->{desc} = "The drawable's image"; + $outargs[0]->{init} = 1; delete $inargs[0]->{no_success}; @@ -356,7 +357,7 @@ HELP x %= TILE_WIDTH; y %= TILE_WIDTH; - p = tile_data_pointer (tile, y, x); + p = tile_data_pointer (tile, x, y); for (b = 0; b < num_channels; b++) pixel[b] = p[b]; @@ -397,7 +398,7 @@ HELP x %= TILE_WIDTH; y %= TILE_WIDTH; - p = tile_data_pointer (tile, y, x); + p = tile_data_pointer (tile, x, y); for (b = 0; b < num_channels; b++) *p++ = *pixel++;