koffice/krita/tools
Adrian Page
adrian at pagenet.plus.com
Thu Aug 26 00:31:13 CEST 2004
On Wednesday 25 August 2004 12:17 pm, Boudewijn Rempt wrote:
> If there's a selection, first create a temporary layer as big as the
> selected area, and either simply composit the pattern in a loop into the
> area, or use KisPainters rectangular fill. Then apply the selection mask --
> this is still slow because of pixel/setPixel, but that's something we
> should improve -- and bitBlt the temporary layer with the specified opacity
> onto the target layer.
>
> If there isn't a selection, follow the old code path to flood fill.
There's an advantage to always using a temporary layer rather than writing to
the target layer directly, and that's that you can use the bitblt to perform
the composite op and opacity setting that all of the paint tools should
support. In fact, that seems to be the only practical way of supporting these
options.
Adrian
More information about the kimageshop
mailing list