Yet another bug. This time filters vs selections

Dmitry Kazakov dimula73 at gmail.com
Wed Sep 9 21:38:19 CEST 2009


On Wed, Sep 9, 2009 at 11:22 PM, Boudewijn Rempt <> wrote:

> On Wednesday 09 September 2009, Dmitry Kazakov wrote:
>
> > Ideally, we should free filters from doing this dirty work. Selections
> > should be our internal routine... Ideally...
> > Another question - how to implement it?
>
> Historically, selections were part of a paint device. When we decided that
> that was a Bad Thing, it became necessary to pass selections to interested
> routines. The only way to make filters work without an explicit selection
> parameter is to copy the data before passing it to a filter and then
> blitting
> it back with the selection set on the painter. I don't think that's worth
> it:
> let's just fix the filters.
>

That is not good API solution. In the worst case we will have to introduce
unified way of iterating through pixels taking selections into account.
Other way we get the same unmaintainable pieces of different code like in
layer's updateProjection stuff. Every layer has it's own implementation of
masks application and every implementation is wrong in it's own way.

We'll get the same stuff with filters if we decide to do selections inside
of them without any system.


PS:
kis_layer's stuff is already fixed

-- 
Dmitry Kazakov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/kimageshop/attachments/20090909/e7522408/attachment-0001.htm 


More information about the kimageshop mailing list