You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Ladislav Jahoda (JIRA)" <ji...@apache.org> on 2009/07/05 22:58:15 UTC

[jira] Updated: (HARMONY-6256) Incorrect test of transformation type when clipping

     [ https://issues.apache.org/jira/browse/HARMONY-6256?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ladislav Jahoda updated HARMONY-6256:
-------------------------------------

    Attachment: CommonGraphics2D.java.patch

CommonGraphics2D.java patch of clip and setClip

> Incorrect test of transformation type when clipping
> ---------------------------------------------------
>
>                 Key: HARMONY-6256
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6256
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Ladislav Jahoda
>         Attachments: CommonGraphics2D.java.patch
>
>
> In CommonGraphics2D both clip and setClip use bitwise AND operator for transformation type test. This is wrong. Note that tested TYPE_IDENTITY is defined as zero, so bitwise AND always gives zero and identity transformation is not recognized. This means that even the most simple cases with identity transformation are rasterized. Moreover, the test logic doesn't make sense for TYPE_TRANSLATION either - note that if the object is just rotated then it is rasterized, but when it is translated and rotated then because of TYPE_TRANSLATION bit set it is only translated. I think the bitwise AND is incorrect here and test should use == instead.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.