rendering different in inkscape than FF/Baltik with masked objects

Bug #404009 reported by Thomas Hicks
24
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Inkscape
Invalid
Medium
Unassigned

Bug Description

Similar to Bug #169148

This is a file that I think renders correctly in Inkscape, but Firefox, Opera and Baltik all render it diffrent (consistant) way so something is wrong

The svg is group of clones that has then been masked by another group.
The problem seems to be that Firefox, Opera and Baltik all don't render anything to the left or above the red corner mark, whereas in Inskape It appears to be masked differently.

I will try to produce a reduced testcase

Revision history for this message
Thomas Hicks (hicks-kingtom) wrote :
Revision history for this message
su_v (suv-lp) wrote :

possibly related to bug #208217, comments 21 and 25?
"A masked object overlapping the edge of the page and then translated onto the page will be drawn in the PDF file correctly. However, if the masked object is first placed in a group (a layer is actually a group) and then translated, the part initially drawn off the page will be missing."

Revision history for this message
Thomas Hicks (hicks-kingtom) wrote :

reduced testcase, only mask, no clones

summary: - rendering diffrent in inkscape with masked clones
+ rendering different in inkscape than FF/Baltik with masked objects
Revision history for this message
Thomas Hicks (hicks-kingtom) wrote :

I have just simplified the test case further, and think that the problem is todo with how the transformations are applied to the objects.

The problem happens when you do a "Fit page to selection" on the object. Which implies that inkscape is treating the transformations on the mask differently than in Firefox, opera and Baltik

Revision history for this message
jazzynico (jazzynico) wrote :

Confirmed on Windows XP, Inkscape rev. 21920.
I've attached the same file saved as plain SVG, which seems to work well (tested with FF3.5 and Opera 10b2).

Changed in inkscape:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
su_v (suv-lp) wrote :

related to bug #168651 "Tiled Clones" inside transformed groups broken ?

tags: added: clones transformations
su_v (suv-lp)
tags: added: masking
removed: clones
Revision history for this message
su_v (suv-lp) wrote :

Another example of the same issue as described in comment #5:
Bug #208217, comments 32 and 35
<https://bugs.launchpad.net/inkscape/+bug/208217/comments/32>
<https://bugs.launchpad.net/inkscape/+bug/208217/comments/35>

Revision history for this message
su_v (suv-lp) wrote :

Attaching another reduced test case - likely describing the same issue - based on an image created in Inkscape, that wasn't displayed in browsers propertly. File was provided by ChALkeR on irc.

Revision history for this message
su_v (suv-lp) wrote :

With regard to the ChALKeR's example: AFAICT the difference is how the initial size (width / height of the <svg> element) affects the size of the mask (it gets clipped to the size of the <svg> + 10%), whereas Inkscape does not clip the mask at all, even if it (partially) is outside the defined initial viewport.

Tests can be done by increasing/decreasing the 'width' attribute if the <svg> element by 100px steps: the the left edge of the visible portion of the masked rectangle will shift by 10 px (direction depending on whether the width was increased or decreased).

su_v (suv-lp)
tags: added: svg
Revision history for this message
Nathan Lee (nathan.lee) wrote :

Hi,

We've moved our bug tracker to gitlab, so closing this issue and continuing to track this issue in https://gitlab.com/inkscape/inkscape/-/issues/3183

Note: the reason render_problem_v4.svg displayed correctly was because maskUnits was unset (defaulting to objectBoundingBox), while the other attached files had it set to userSpaceOnUse. Without setting appropriate x/y/width/height on the mask object, this can cause clipping as noted above.

File from #1 can be fixed by adding x="-558.528" y="-605.999" to the mask.
File from #4 can be fixed by adding x="-558.528" y="-605.999" to the mask.
File from #5 can be fixed by adding x="-334.42179" y="-615.72246" to the mask.
File from #8 can be fixed by adding y="952.36218" to the mask.
File from #9 can be fixed by adding x="-400" y="-30" to the mask.

These values all are the inverses of the transform applied to it's parent layer. Removing the maskUnits value is a simpler solution (that is robust against more complex transforms or multiple uses of the mask (but is not suitable when multiple objects try to share the same mask).

Changed in inkscape:
status: Confirmed → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.