Effect masks vs. selections and "embedded" transparency masks

Sven Langkamp sven.langkamp at gmail.com
Sat Sep 5 04:55:36 CEST 2009


On Fri, Sep 4, 2009 at 10:31 PM, Dmitry Kazakov <dimula73 at gmail.com> wrote:

> Hi again, All!
>
> There are some more troubles. This time they are with effect masks.
>
> The problem is: we simply CAN'T add any selection with a selection
> tool or paint something with a freehand tool on ANY MASK.
>

Can you explain what you expect? When I select something on a transparency
mask e.g with retangular selection I can paint inside the selection with the
normal brush.
I don't see the problem.


> The reason is we use explicit conversion of the node to KisLayer* type
> in these tools.
>
> kis_tool_freehand.cc:282
>
>  if (!m_paintIncremental) {
>
>         KisIndirectPaintingSupport* layer;
>         if ((layer =
> dynamic_cast<KisIndirectPaintingSupport*>(currentNode().data()))) {
>             // Hack for the painting of single-layered layers using
> indirect painting,
>             // because the group layer would not have a correctly synched
> cache (
>             // because of an optimization that would happen, having this
> layer as
>             // projection).
>             KisLayerSP l = layer->layer();
> ...
>
> kis_selection_tool_helper.h:33
>
> class KRITAUI_EXPORT KisSelectionToolHelper
> {
> public:
>
> ...
>
> private:
>     KisCanvas2* m_canvas;
>     KisImageSP m_image;
>     KisLayerSP m_layer;
>     QString m_name;
> };
>
>
> I don't see any clear solution for this. And more than that, I'm afraid
> some
> other tools can use the same conversion inside themselves.
>
> The only solution i see is to derieve filter masks from
> KisIndirectPaintingSupport and make some workaround with layer()
> method...
> Don't know really...
>
> Do you have any ideas?
>
> --
> Dmitry Kazakov
>
> _______________________________________________
> kimageshop mailing list
> kimageshop at kde.org
> https://mail.kde.org/mailman/listinfo/kimageshop
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kimageshop/attachments/20090905/a3b67c02/attachment.htm 


More information about the kimageshop mailing list