Commit Graph

396 Commits

Author SHA1 Message Date
Michael Natterer 9504e85a7e app: set an icon on the floating selection filter 2013-04-16 20:30:13 +02:00
Michael Natterer 8bfb1769b7 app: use a GimpApplicator for floating selection compositing 2013-04-15 01:44:18 +02:00
Michael Natterer 1235013177 app: add local "private" variables to make drawable's FS code more readable 2013-04-12 21:07:56 +02:00
Michael Natterer 38e983c724 app: fix regression: make the selection clip the FS again 2013-04-12 18:26:34 +02:00
Michael Natterer 39ab59e032 app: add gimp_drawable_get_floating_sel_filter() 2013-04-12 16:57:39 +02:00
Michael Natterer b16f75b8af app: make the FS' drawable update itself when the active components change
which removes more FS knowledge from the image.
2013-04-12 15:58:42 +02:00
Michael Natterer 538e3813be app: make floating selection compositing honor the image's active components
This was a regression from 2.8
2013-04-12 15:54:05 +02:00
Michael Natterer a1ddd7dfda app: use the newly added drawable filter api to add/remove the fs filter 2013-04-12 12:56:01 +02:00
Michael Natterer f3308e6ba3 app: add a GimpFilterStack to each GimpDrawable
which is part of the drawable's source_node, so we can generically
filter a drawable's pixels. Reading from the source_node will
transparently give the filtered results.

Turn floating selection compositing into a GimpFilter and add it to
the filter stack while we have a floating selection on the drawable.
2013-04-11 19:06:23 +02:00
Michael Natterer 4ca746eab7 app: move the "is-last-node" property and API from drawable to filter 2013-04-11 12:25:11 +02:00
Michael Natterer 45a6ea432c app: add new class GimpFilter as parent class of GimpItem
and move the item's GeglNode API there. The purpose of this is to
factor out "gimp object that manages a node".
2013-04-11 12:25:10 +02:00
Michael Natterer c914aa805d Bug 675747 - Layers with some modes get hidden in layer groups
Add a boolean "is-last-node" property to GimpDrawable and set it from
GimpDrawableStack, which is the place that easily has the information.
In GimpLayer, connect to "notify" and make sure we use NORMAL mode
unless the layer is in NORMAL or DISSOLVE mode.
2012-11-12 10:55:41 +01:00
Michael Natterer 435df29d85 app: add utility functions for applying specific operations to buffers
so gimp_gegl_apply_foo() will run "gegl:foo" with the required
properties on a buffer and write the result to another buffer.
2012-10-31 23:47:45 +01:00
Michael Natterer ca4dadefa4 app: remove gimp_drawable_apply_operation_to_buffer()
it was a completely silly wrapper. Use gimp_gegl_apply_operation()
directly instead.
2012-10-22 16:14:56 +02:00
Michael Natterer 60305c11d5 app: add "const Babl *new_format" to GimpDrawable::convert_type()
but only to the virtual function, not the public API. Implement it in
GimpSelection and GimpLayerMask, and pass the correct mask format down
to the parent class which does the actual conversion.
2012-10-13 22:56:32 +02:00
Michael Natterer 5dbcdef477 app: implement optional dithering when converting to lower bit depth
Add "layer_dither_type" and "mask_dither_type" to
GimpDrawable::convert_type(), pass around the dither type from the
dialog, and implement dithering using gegl:color-reduction.
2012-10-13 21:46:56 +02:00
Michael Natterer 373a4e7469 app: completely remove TileManager and friends (base/ and paint-funcs/)
And along with it a lot of stuff like the drawable preview cache, the
gegl tile manager backend, temporary gimp_gegl_buffer_foo() stuff, and
the remaining bits of performance.

The projection is in an evil semi-ported state which makes it work
ok-ish for stuff like layer moving, but absolutely unbearable for
painting, there is also an off-by-one rendering glitch at some zoom
levels.
2012-06-20 21:44:09 +02:00
Michael Natterer 4dcd1f3ad4 app: use plain gegl_buffer_new() and _dup(), not the gimp_gegl_ variants
unless the buffers end up being drawable->buffer.
2012-05-20 22:02:59 +02:00
Michael Natterer aee7ddd56d app: remove the !use_gegl case from gimp_drawable_apply_buffer()
and its last three parameters because they were only used for legacy
floating selection projection.
2012-05-19 00:14:51 +02:00
Michael Natterer d294cfb8b2 app: remove the legacy projection construction code 2012-05-19 00:06:03 +02:00
Michael Natterer 83a728f492 app: rename gimp_gegl_node_set_layer_mode() to gimp_gegl_mode_node_set()
and have it set mode and opacity at the same time, so we don't reset
opacity each time we set the mode.
2012-05-18 23:50:35 +02:00
Michael Natterer 4699725821 app: port floating selection blending to the new mode ops
Also, remove the fallback layer mode code from GimpOperationPointLayerMode,
and pass premultiplied = FALSE to gimp_gegl_node_set_layer_mode().
2012-05-18 23:37:56 +02:00
Michael Natterer efa52edf6e app: change the layer's graph to expect mode operations with mask inputs
and opacity inputs. Add two offset nodes for both layer and mask, and
plug everything directly into the mode node.
2012-05-18 18:57:58 +02:00
Michael Natterer 94da46c373 app: add precision argument to gimp_image_get_format()
and use it instead of gimp_babl_format() in some places where indexed
formats can occur. Also fix some places using gimp_babl_format() to
special case indexed formats correctly.
2012-05-07 21:46:47 +02:00
Michael Natterer 010418d874 app: remove gimp_drawable_get_tiles() 2012-05-06 04:39:23 +02:00
Michael Natterer 69893e4f72 app: remove GimpPickable::get_tiles()
and change some legacy places to get their tiles from the buffer
returned by GimpPickable::get_buffer().
2012-05-06 01:01:54 +02:00
Michael Natterer 3ad73b3658 libgimpcolor: add GdkPixbuf <-> GeglBuffer utility functions
and update tons of includes in libgimp and app.
2012-05-03 03:37:20 +02:00
Michael Natterer d81ea1315e app: implement active, affected components in GEGL
Add GimpOperationMaskComponents, enum GimpComponentMask, and image and
drawable infrastructure to get the right mask, and plug the mask
operation into gimp_gegl_create_apply_buffer_node().
2012-05-02 17:51:17 +02:00
Michael Natterer f164069c9c app: remove gimp_drawable_bytes() and ask its format instead 2012-05-02 17:51:16 +02:00
Michael Natterer e15702cbe5 app: create gimp-babl-compat.[ch] for gimp_babl_format_get_image_type()
and remove gimp_drawable_type().
2012-05-02 17:51:15 +02:00
Michael Natterer 96ebc6f848 app: add "new_precision" argument to gimp_drawable_convert_type()
for clarity and consistency with the "new_base_type" argument.
2012-05-02 17:51:15 +02:00
Michael Natterer 0e8a00db8b app: honor precision when copying drawables between images 2012-05-02 17:51:15 +02:00
Michael Natterer a016b8102b app: change the maskPR in gimp_drawable_replace_buffer() to GeglBuffer 2012-05-02 17:51:12 +02:00
Michael Natterer c07325a005 app: add "precision" argument to gimp_image_new() 2012-05-02 17:51:09 +02:00
Michael Natterer ff931e1ded app: move gimp_babl_format_get_base_type() to gimp-babl.[ch]
The GimpImageBaseType enum is going to go away, but a format -> enum
API is going to stay around.
2012-05-02 17:51:08 +02:00
Michael Natterer e6975ed065 app: add format parameter to GimpPickable::get_pixel_at()
allowing NULL for the pickable's native format. Fix and simplify auto
cropping to always use "R'G'B'A u8".
2012-05-02 17:51:07 +02:00
Michael Natterer 9d518677d2 app: remove gimpdrawable-convert.[ch]
This can now be done in gimp_drawable_real_convert_type() with a few
lines of GEGL buffer copying.
2012-05-02 17:51:03 +02:00
Michael Natterer 95cb77edc9 app: change gimp_image_get_format() to take a base_type and a with_alpha boolean
which kills almost all remaining use of GimpImageType.
2012-05-02 17:51:03 +02:00
Michael Natterer ec2d5647c0 app: remove gimp_drawable_type_with_alpha() 2012-05-02 17:50:57 +02:00
Michael Natterer 3c4f9d55ed app: use the new functions added with the last commit 2012-05-02 17:50:57 +02:00
Michael Natterer 2b18645fb5 app: use gimp_drawable_get_base_type() instead of GIMP_IMAGE_TYPE_BASE_TYPE() 2012-05-02 17:50:57 +02:00
Michael Natterer f6f7d53020 app: add gimp_drawable_get_base_type() 2012-05-02 17:50:57 +02:00
Michael Natterer afe8eaf256 app: remove GimpImageType based API and macro junk 2012-05-02 17:50:57 +02:00
Michael Natterer 368ae01c86 app: don't special case the FS wrt its visibility in the layer stack
Its source node produces nothingness anyway, so it can be safely
plugged in. More FS special code gone \o/.
2012-05-02 17:50:54 +02:00
Michael Natterer 8cca4c51ad app: use gimp_gegl_node_set_layer_mode() to configure the FS' mode node 2012-05-02 17:50:54 +02:00
Øyvind Kolås 6efd812d08 app: s/GIMP_GEGL_RECT/GEGL_RECTANGLE/
Defining GeglRectangle inline is so useful that it has been added to
GEGL.
2012-05-02 17:50:52 +02:00
Michael Natterer 8dfea70191 app: fix GIMP_TIMER_END() to take an arbitrary string
not a string constant that only works in the C preprocessor, and add a
timer to gimp_apply_operation().
2012-05-02 17:50:43 +02:00
Michael Natterer 1a34171e68 app: remove the legacy option in gimp_drawable_scale() 2012-05-02 17:50:42 +02:00
Michael Natterer 87b7af7fa5 app: remove drawable->private->format, its buffer has a format already
Also, make group layer type conversion much less hackish by using the
same kind of temporary states that are used for reallocating its
projection on size change.
2012-05-02 17:50:42 +02:00
Michael Natterer 2a853cd1ee app: remove GimpPickable::get_bytes() 2012-05-02 17:50:42 +02:00