[cairo] fallback resolution bug?

Adrian Johnson ajohnson at redneon.com
Sun Oct 4 18:30:15 PDT 2009


bulia byak wrote:
> Hi Carl,
> 
> I'm addressing you personally because I saw your blog post about a
> similar, or maybe even the same, bug. I attach a simple SVG which was
> exported by Inkscape to EPS, using cairo operations as we now do.
> There are two bugs:
> 
> - where the transparent image overlaps the text, it is obvious that it
> is rasterized at a very small resolution, perhaps 72 dpi, not the
> default 300. Inkscape never sets this so it should be 300. The image
> itself it rendered at 300 dpi, but the other objects touched by it are
> not.
> 
> - in fact, in the rasterized bitmap there must be no text at all -
> because text is higher in z-order and thus is not affected by the
> image with alpha anyway. Fallback rasterization should render only the
> transparent object and whatever is BELOW it, not above.

There are many optimizations that could be done to improve output in 
cases such as the above. But they also add a lot more complexity to the 
fallback code for limited gain.

I am not planning on doing any further optimizing of the finer grained 
fallbacks code. However patches are welcome.

Note also that in PDF surface fallback images can only be painted last 
due to need to use a knockout group to paint the fallback image on top.

> 
> This is with cairo 1.8.8. Can you tell me if there exists a version
> that fixes at least the first of these bugs? If not what can I do to
> help you or someone in the know to fix it?

I have a branch that contains a fix for Carl's patch for this bug. It 
works for me.

http://cgit.freedesktop.org/~ajohnson/cairo/log/?h=acquire_source_image_transformed

> 
> Thanks!
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo



More information about the cairo mailing list