diff options
author | Adrian Johnson <ajohnson@redneon.com> | 2008-04-05 13:32:51 +1030 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2008-10-30 21:24:54 +0000 |
commit | 05fce5bced9718ffa803f5a87df00f96809d1f53 (patch) | |
tree | 0d1b29e4d144175f032d8a939fb52e8c4223e056 /test/surface-pattern-scale-up.c | |
parent | 2c53bdb82a955c672c8fee2b1b4c991af2654ae0 (diff) |
PS/PDF: Set image Interpolation flag
If the filter mode is anything other than DEFAILT, FAST or NEAREST set the
Interpolate flag in the image dictionary so that a smoothing filter is
applied when rasterising the vector file.
As we have no control over the implementation of the Interpolate filter
(the PS/PDF specifications leave it undefined) we need to capture the
output of poppler/GS and update our reference images. (For a couple of
tests, the filtering is irrelevant so for those we set the filter to
NEAREST.)
Note that GhostScript's Interpolate filter does not work on rotated images
(and a variety of other transformations) so several of the PS reference
images have use nearest-neighbour sampling instead of a bilinear filter.
Diffstat (limited to 'test/surface-pattern-scale-up.c')
-rw-r--r-- | test/surface-pattern-scale-up.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/surface-pattern-scale-up.c b/test/surface-pattern-scale-up.c index 3c097532e..33f62fc0a 100644 --- a/test/surface-pattern-scale-up.c +++ b/test/surface-pattern-scale-up.c @@ -24,6 +24,9 @@ * Author: Behdad Esfahbod <behdad@behdad.org> */ +/* Exhibits nasty behaviour with GS due as their /Interpolate implementation + * does not function for rotated images. */ + #include <math.h> #include "cairo-test.h" #include <stdio.h> @@ -34,8 +37,7 @@ static cairo_test_draw_function_t draw; static const cairo_test_t test = { "surface-pattern-scale-up", - "Test scaled-up transformed not-repeated surface patterns" - "\nFails xlib backend (with argb32) with inexplicable alpha in result", + "Test scaled-up transformed not-repeated surface patterns", SIZE, SIZE, draw }; |