[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-kimageshop
Subject:    Re: Default pixel and paint device bounds
From:       Sven Langkamp <sven.langkamp () gmail ! com>
Date:       2010-09-12 12:05:39
Message-ID: AANLkTikcVjT+48_SSrv_H4a_ymZFPKXgR1UBt1sEPdQe () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


On Sun, Sep 12, 2010 at 2:01 PM, Sven Langkamp <sven.langkamp@gmail.com>wrote:

> On Sun, Sep 12, 2010 at 1:44 PM, Boudewijn Rempt <boud@valdyas.org> wrote:
>
>> On Sunday 12 September 2010, Marc wrote:
>> > Yesterday I fixed bug 245778 in the transform workers, though the
>> > problem might still appear in other places.
>> > Actually, the problem came from the fact that the first layer had a non
>> > transparent default pixel. In that case, KisPaintDevice's exactBounds
>> > and extent return defaultBounds (which is set to (0,0),(image width,
>> > image height)) : that isn't really what the transform workers expect
>> > when calling exactBounds.
>> > For now, the transform workers check whether the default pixel is
>> > transparent or not. If it isn't, then it uses the dataManager extent
>> > instead of paintDevice bounds.
>> > It might be good to consider changing the exactBounds() behaviour when
>> > default pixel is not transparent (sven wondered whether we could unite
>> > the default bounds with the data manager in that case).
>>
>> I think that exactBounds is used in a number of different ways and that it
>> makes sense to add a parameter to the function to manage the handling of
>> non-transparent default pixel paint devices, something like
>>
>> exactBounds(bool alwaysCalculate = false);
>>
>> ?
>>
>
> Or add an enum (normal extent, extent or defaultbounds, extent united with
> defaultbounds)
> For the transform tool only the normal extent is needed, I think.
>
>
Unite might not be such a good idea for transform as there good be a very
big layer with a default pixel, but only very little painted.

[Attachment #5 (text/html)]

<div class="gmail_quote">On Sun, Sep 12, 2010 at 2:01 PM, Sven Langkamp <span \
dir="ltr">&lt;<a href="mailto:sven.langkamp@gmail.com">sven.langkamp@gmail.com</a>&gt;</span> \
wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; \
border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"> <div \
class="gmail_quote"><div class="im">On Sun, Sep 12, 2010 at 1:44 PM, Boudewijn Rempt \
<span dir="ltr">&lt;<a href="mailto:boud@valdyas.org" \
target="_blank">boud@valdyas.org</a>&gt;</span> wrote:<br><blockquote \
class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, \
204, 204); padding-left: 1ex;">

<div>On Sunday 12 September 2010, Marc wrote:<br>
&gt; Yesterday I fixed bug 245778 in the transform workers, though the<br>
&gt; problem might still appear in other places.<br>
&gt; Actually, the problem came from the fact that the first layer had a non<br>
&gt; transparent default pixel. In that case, KisPaintDevice&#39;s exactBounds<br>
&gt; and extent return defaultBounds (which is set to (0,0),(image width,<br>
&gt; image height)) : that isn&#39;t really what the transform workers expect<br>
&gt; when calling exactBounds.<br>
&gt; For now, the transform workers check whether the default pixel is<br>
&gt; transparent or not. If it isn&#39;t, then it uses the dataManager extent<br>
&gt; instead of paintDevice bounds.<br>
&gt; It might be good to consider changing the exactBounds() behaviour when<br>
&gt; default pixel is not transparent (sven wondered whether we could unite<br>
&gt; the default bounds with the data manager in that case).<br>
<br>
</div>I think that exactBounds is used in a number of different ways and that it \
makes sense to add a parameter to the function to manage the handling of \
non-transparent default pixel paint devices, something like<br> <br>
exactBounds(bool alwaysCalculate = false);<br>
<br>
?<br></blockquote></div><div><br>Or add an enum (normal extent, extent or \
defaultbounds, extent united with defaultbounds)<br>For the transform tool only the \
normal extent is needed, I think.<br><br></div></div> </blockquote></div><br>Unite \
might not be such a good idea for transform as there good be a very big layer with a \
default pixel, but only very little painted.<br>



_______________________________________________
kimageshop mailing list
kimageshop@kde.org
https://mail.kde.org/mailman/listinfo/kimageshop


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic