[cairo-commit] 2 commits - ROADMAP src/cairo-pattern.c
Behdad Esfahbod
behdad at kemper.freedesktop.org
Fri Apr 13 13:34:16 PDT 2007
ROADMAP | 6 +++---
src/cairo-pattern.c | 15 ++++++++++-----
2 files changed, 13 insertions(+), 8 deletions(-)
New commits:
diff-tree 7ead3e64f17fe302398ec60c61eaeaae4e9b18cf (from 84c10a79ffd233a953434bd787dcfe57787552f8)
Author: Behdad Esfahbod <behdad at behdad.org>
Date: Fri Apr 13 16:34:31 2007 -0400
[ROADMAP] Put back bug 10508 into 1.4.4 roadmap and mark it fixed
Yay!
diff --git a/ROADMAP b/ROADMAP
index 3fad500..7b715ce 100644
--- a/ROADMAP
+++ b/ROADMAP
@@ -16,11 +16,11 @@ cairo 1.4.4 (scheduled for 2007-04-09)
â 10531 cairo nquartz backend floating point precision issues (bewins)
-cairo 1.4.x (not scheduled, may become part of 1.6)
-===================================================
- ⢠10508 Transformed image source surfaces sometimes misrender to xlib
+ â 10508 Transformed image source surfaces sometimes misrender to xlib
surface target (cworth)
+cairo 1.4.x (not scheduled, may become part of 1.6)
+===================================================
⢠Fix all remaining XFAIL failures from the test suite
a8mask has a patch available on the list
diff-tree 84c10a79ffd233a953434bd787dcfe57787552f8 (from fcf49a56130ede8c6aa9f84a8c59ecef54714b7b)
Author: Behdad Esfahbod <behdad at behdad.org>
Date: Fri Apr 13 16:33:07 2007 -0400
[cairo-pattern] Slightly hackish fix for bug #10508
The so-attributed-to-X-server bug was that cairo maps the drawing
region to the pattern space, rounds the box, and uploads only that
part of the source surface to the X server. Well, this only works for
NEAREST filter as any more sophisticated filter needs to sneak a peek
at the neighboring pixels around the edges too.
The right fix involves taking into account the filter used, and the
pattern matrix, but for most cases, a single pixel should be enough.
Not sure about scaling down...
Anyway, this is just a workaround to get 1.4.4 out of the door. I'll
commit a proper fix soon.
diff --git a/src/cairo-pattern.c b/src/cairo-pattern.c
index e92d87d..af432f2 100644
--- a/src/cairo-pattern.c
+++ b/src/cairo-pattern.c
@@ -1472,11 +1472,16 @@ _cairo_pattern_acquire_surface_for_surfa
* in a region larger than the surface, but we never
* want to clone more than the surface itself, (we
* know we're not repeating at this point due to the
- * above. */
- x = MAX (0, floor (x1));
- y = MAX (0, floor (y1));
- width = MIN (extents.width, ceil (x2)) - x;
- height = MIN (extents.height, ceil (y2)) - y;
+ * above.
+ *
+ * XXX: The one padding here is to account for filter
+ * radius. It's a workaround right now, until we get a
+ * proper fix. (see bug #10508)
+ */
+ x = MAX (0, floor (x1) - 1);
+ y = MAX (0, floor (y1) - 1);
+ width = MIN (extents.width, ceil (x2) + 1) - x;
+ height = MIN (extents.height, ceil (y2) + 1) - y;
}
x += tx;
y += ty;
More information about the cairo-commit
mailing list