Review request: Masks support compositeOps and opacity

Dmitry Kazakov dimula73 at gmail.com
Mon Oct 26 22:37:41 CET 2009


>
> About KisBaseNode not knowing about the parent: it has been a conscious
> desicion to separate the the graph part from the base bart. So, if
> setCompositeOpn needs to know about the parent, there is no need for
> duplication, move that code to KisNode from KisLayer and KisMask.
>

I'm fully agree that a graph part and a base one should be in separate
classes. =)
Don't think KisNode is a good place for compositeOp as this class is for
graph part.

I think as a long-term solution we could swap names for KisBaseNode and
KisNode.
What i mean:

now:
KisNode - graph part
KisBaseNode - base part

how it could be:
KisNode - base part
KisBaseNode - graph part

In such a case every function from a base part will be able to access graph
functions.

Just an idea...


We could also decide that all nodes must have a composite op set,
> COMPOSITE_OVER by default, so they don't go back to their parent anymore.
> That might be even simpler.
>

I'm afraid parent is needed as a compositeOp should be prepared for merging
operation that is done in parent's colorSpace, that, in general case, can
differ from this->colorSpace().


-----------
>
> This is just from eyeballing the source: I haven't been able to run it yet,
> because I get a compile error:
>

[]

Ah yes! Forgot to compile tests. =)
Here is an additional patch in attachment (should be added to the previous
one).

I've done tests. Kis{,Base}Node tests are done successfully, but some Masks
and Selections tests fail with segmentation. Could you check whether this is
a regression or not?


-- 
Dmitry Kazakov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kimageshop/attachments/20091027/ad885014/attachment.htm 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01_masks_composite_ops_tests_fix.diff
Type: text/x-patch
Size: 3704 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kimageshop/attachments/20091027/ad885014/attachment.diff 


More information about the kimageshop mailing list