koffice/krita/image/recorder

Cyrille Berger cberger at cberger.net
Tue Jan 26 09:55:17 CET 2010


On Tuesday 26 January 2010, LukasT.dev at gmail.com wrote:
> I use settings->node() for accessing paint device of the currently selected
> layer. I remember that using painter()->device() used to do different
>  things. Sometimes it used to crash if I read and write from it .Especially
>  if you were using BUILD UP/WASH mode, weird things happened like you did
>  have different color in the accessor then you have seen on layer (probably
>  because of the BUILD UP/WASH mode)
> I supposed that when we have node() in settings, I can access another
>  layers. E.g. I would like to add to the settings of the paintop layer
>  selecting for colour source.
> 
> Use case:
> You want to use "sample input color" in spray in non-destructing way. You
> select in the settings widget layer you want to use as source (or avoid
>  this and use layer below currently selected layer) to take colours from.
>  And then you spray around as mad man and ta daaa - masterpiece.
> But you don't want to ruin your current layer. It can be workarounded by
> copying the layer.
Ok now, I understand what you used the node for, as as source. And the for the 
destination you correctly use the one in the KisPainter.
But I still think that it is an abuse of the settings, which is a permanent 
ressource, and get assigned a temporary ressource before painting. (We have 
the same problem  with the perspective grid which is in the image to give the 
duplicate op access to it). Furthermore, I don't think paintop should rely on 
that information to be available, I think they should fallback graciously, or 
we need to rename KisPainter from being a KisPaintDevice painter to be a 
KisNode painter.

So what I am thinking is that currentNode, image and perspective grid should 
be set on a different object, wether KisPainter or a new object. And that 
should be considered as optional (meaning, no crash in paintop when not 
available).

-- 
Cyrille Berger


More information about the kimageshop mailing list