Bug 89533 - pdftocairo -svg produced garbaged shadows in the ouput file
Summary: pdftocairo -svg produced garbaged shadows in the ouput file
Status: RESOLVED DUPLICATE of bug 73038
Alias: None
Product: cairo
Classification: Unclassified
Component: svg backend (show other bugs)
Version: 1.12.4
Hardware: All All
: medium normal
Assignee: Emmanuel Pacaud
QA Contact: cairo-bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-03-11 12:40 UTC by Vladimir Rapatskiy
Modified: 2015-03-11 18:42 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
File with shadows, which garbaged during PDF->SVG conversion (149.71 KB, text/plain)
2015-03-11 12:40 UTC, Vladimir Rapatskiy
Details

Description Vladimir Rapatskiy 2015-03-11 12:40:33 UTC
Created attachment 114219 [details]
File with shadows, which garbaged during PDF->SVG conversion

When converting attached file to SVG, I see that square and star objects shadows are missing. I've used pdftocairo version 0.24.6. Command:
pdftocairo -svg testlinks.pdf

Using git bisect I've found that first commit where shadow rendering was broken is

commit 8020e0bc8cbd3e5ac188eb305b74ae1c1f362a31
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Wed Oct 3 17:01:41 2012 +0100

In that commit file src/cairo-recording-surface.c was changed.

If I revert this part of diff patch, then shadows rendering brings back.

@@ -1131,7 +1441,7 @@ _cairo_recording_surface_snapshot (void *abstract_other)
     surface->optimize_clears = TRUE;
 
     _cairo_array_init (&surface->commands, sizeof (cairo_command_t *));
-    status = _cairo_recording_surface_replay (&other->base, &surface->base);
+    status = _cairo_recording_surface_copy (other, surface);
     if (unlikely (status)) {
        cairo_surface_destroy (&surface->base);
        return _cairo_surface_create_in_error (status);

Could you please help me to fix _cairo_recording_surface_copy function to support shadows?

In the latest cairo builds shadows are broken even more. They are not absent, but rendered as gray rectangles under the objects.
Comment 1 Massimo 2015-03-11 17:54:37 UTC
it seems to be a duplicate of bug #73038
Comment 2 Vladimir Rapatskiy 2015-03-11 18:42:18 UTC
Yes, it is the duplicated bug. Thank you!
Comment 3 Vladimir Rapatskiy 2015-03-11 18:42:40 UTC

*** This bug has been marked as a duplicate of bug 73038 ***


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.