app: no need to clear newly created buffers

Freshly created GeglBuffers, that are native GeglBuffers are already sparse
and all tiles are implicit COW empty tiles.
This commit is contained in:
Øyvind Kolås
2012-04-10 18:20:11 +02:00
committed by Michael Natterer
parent 631134180e
commit 25030ce6c4
4 changed files with 0 additions and 8 deletions

View File

@ -101,10 +101,6 @@ gimp_drawable_offset (GimpDrawable *drawable,
gegl_buffer_set_color (new_buffer, NULL, color); gegl_buffer_set_color (new_buffer, NULL, color);
g_object_unref (color); g_object_unref (color);
} }
else
{
gegl_buffer_clear (new_buffer, NULL);
}
} }
if (offset_x >= 0) if (offset_x >= 0)

View File

@ -341,8 +341,6 @@ gimp_drawable_stroke_scan_convert (GimpDrawable *drawable,
mask_buffer = gegl_buffer_new (GEGL_RECTANGLE (0, 0, w, h), mask_buffer = gegl_buffer_new (GEGL_RECTANGLE (0, 0, w, h),
babl_format ("Y u8")); babl_format ("Y u8"));
gegl_buffer_clear (mask_buffer, NULL);
/* render the stroke into it */ /* render the stroke into it */
gimp_item_get_offset (GIMP_ITEM (drawable), &off_x, &off_y); gimp_item_get_offset (GIMP_ITEM (drawable), &off_x, &off_y);

View File

@ -397,7 +397,6 @@ gimp_paint_core_start (GimpPaintCore *core,
gimp_item_get_width (item), gimp_item_get_width (item),
gimp_item_get_height (item)), gimp_item_get_height (item)),
babl_format ("Y u8")); babl_format ("Y u8"));
gegl_buffer_clear (core->canvas_buffer, NULL);
/* Get the initial undo extents */ /* Get the initial undo extents */

View File

@ -392,7 +392,6 @@ gimp_perspective_clone_get_source (GimpSourceCore *source_core,
dest_buffer = gegl_buffer_new (GEGL_RECTANGLE (0, 0, x2d - x1d, y2d - y1d), dest_buffer = gegl_buffer_new (GEGL_RECTANGLE (0, 0, x2d - x1d, y2d - y1d),
src_format_alpha); src_format_alpha);
gegl_buffer_clear (dest_buffer, NULL);
gimp_perspective_clone_get_matrix (clone, &matrix); gimp_perspective_clone_get_matrix (clone, &matrix);