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

List:       cairo-bugs
Subject:    [cairo-bugs] [Bug 46255] New: Image Surface _cairo_image_surface_paint() has logic issue
From:       bugzilla-daemon () freedesktop ! org
Date:       2012-02-18 18:04:02
Message-ID: bug-46255-4039 () http ! bugs ! freedesktop ! org/
[Download RAW message or body]

https://bugs.freedesktop.org/show_bug.cgi?id=46255

             Bug #: 46255
           Summary: Image Surface _cairo_image_surface_paint() has logic
                    issue
    Classification: Unclassified
           Product: cairo
           Version: 1.10.2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: major
          Priority: medium
         Component: image backend
        AssignedTo: cworth@cworth.org
        ReportedBy: ihaohu@gmail.com
         QAContact: cairo-bugs@cairographics.org


The issue is the image surface will have different rendering result than the xlib \
surface. 

e.g. If a circle should get clipped by a clip. On xlib surface, everything draws \
fine. On image surface, the circle is NOT clipped.



http://cgit.freedesktop.org/cairo/tree/src/cairo-image-surface.c?h=1.10

Under _cairo_image_surface_paint(), there are two issues:

1. line 3294 -> 3302. Logic of "(clip_path = _clip_get_single_path (clip)) != NULL)" \
is not correct. It just simple against the comment above that logic. Since this will \
still be a valid condition even when the clip contains a set of boxes.

The same code path in _cairo_surface_fallback_paint() in cairo-surface-fallback.c \
should be the correct logic (line 918): "clip != NULL && clip_path->prev == NULL"


2. The _clip_get_single_path() in the cairo-image-surface.c, at line 3243, the return \
value shouldn't be "FALSE" anyway. It should be a (cairo_clip_path_t *) value, not \
boolean. I suspect, it should be "path" instead.


SAME ISSUEs in cairo-xcb-surface-render.c as well.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA Contact for the bug.
_______________________________________________
cairo-bugs mailing list
cairo-bugs@lists.cairographics.org
http://lists.cairographics.org/mailman/listinfo/cairo-bugs


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

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