Francis Kung wrote:
Hi,
The attached patch gets cairo to respect interpolation hints; however
I'm not entirely convinced it's the best option. I don't want to remove
the cairoSurfaceSetFilter function; however the cairo_pattern usually
hasn't been created yet (and won't be created until the drawPixels or
drawSurface function), so I'm not sure how to make SurfaceSetFilter do
anything useful...
Why is cairoSurfaceSetFilter needed? Should it just be removed?
[...]
+ else if
(hints.containsValue(RenderingHints.VALUE_ALPHA_INTERPOLATION_QUALITY))
+ return 3; // CAIRO_FILTER_BEST
+
+ else if
(hints.containsValue(RenderingHints.VALUE_ALPHA_INTERPOLATION_DEFAULT))
+ return 4; // CAIRO_FILTER_GOOD
These could be made static consts.
Tom