[Pixman] [PATCH pixman 07/15] pixman-filter: Speed up the BOX+BOX filter
Bill Spitzak
spitzak at gmail.com
Tue Dec 23 17:52:04 PST 2014
This is easy as the caller already intersected the two boxes, so
the width is the integral.
---
pixman/pixman-filter.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/pixman/pixman-filter.c b/pixman/pixman-filter.c
index 4aafa51..782f73d 100644
--- a/pixman/pixman-filter.c
+++ b/pixman/pixman-filter.c
@@ -182,6 +182,11 @@ integral (pixman_kernel_t reconstruct, double x1,
assert (width == 0.0);
return filters[sample].func (x2 / scale);
}
+ else if (reconstruct == PIXMAN_KERNEL_BOX && sample == PIXMAN_KERNEL_BOX)
+ {
+ assert (width <= 1.0);
+ return width;
+ }
else if (sample == PIXMAN_KERNEL_IMPULSE)
{
assert (width == 0.0);
--
1.7.9.5
More information about the Pixman
mailing list