Summary: | duplicated XObjects with subtype image in PDF Output | ||
---|---|---|---|
Product: | cairo | Reporter: | clark <wzhu> |
Component: | pdf backend | Assignee: | Adrian Johnson <ajohnson> |
Status: | RESOLVED FIXED | QA Contact: | cairo-bugs mailing list <cairo-bugs> |
Severity: | major | ||
Priority: | medium | CC: | carlosgc, chris |
Version: | 1.10.0 | ||
Hardware: | Other | ||
OS: | All | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
clark
2009-10-29 20:16:45 UTC
It seems we are using the unique id of the image surface as the hash key for the surfaces cache, however it's possible to add the same image multiple times using different cairo surfaces. We would need to use the image contents (or even better the mime data if it exists) to make sure we don't duplicate image xobjects. Fix in git master http://cgit.freedesktop.org/cairo/commit/?id=9862c38fc71c6dcd444da3b079e5404cd14594c3 A new mime type CAIRO_MIME_TYPE_UNIQUE_ID has been added. Surfaces with the same unique id will only be embedded once even if different surfaces are created. We've offloaded the job of identifying different surfaces with the same content to the application. You can put what ever you want in the UNIQUE_ID to uniquely identify the surface. eg a filename or SHA1 hash. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.