Bug 30480

Summary: REGRESSION: SVG Mask doesn't work for maskContentUnits="objectBoundingBox"
Product: WebKit Reporter: Dirk Schulze <krit>
Component: SVGAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 525.x (Safari 3.1)   
Hardware: PC   
OS: OS X 10.5   
Attachments:
Description Flags
Fix mask context location, linerRGB as default color-space.
none
Fix mask context location, linerRGB as default color-space. zimmermann: review+

Description Dirk Schulze 2009-10-17 12:02:28 PDT
The test svg/W3C-SVG-1.1/masking-intro-01-f.svg fails.

This is a regression after bug 41193. The apparently wrong calculation of the offset was made to support maskContentUnits="objectBoundingBox" but breaks maskContentUnits="userSpaceOnUse". The patch in 41193 added support for the other mode by breaking objectBoundingBox.
Comment 1 Dirk Schulze 2009-10-17 13:09:27 PDT
Created attachment 41364 [details]
Fix mask context location, linerRGB as default color-space.

This patch fixes an issue of r49598. The maskDestRect shouldn't be used to calculate the position of he masking context. It's just  the location and size of the mask image. Use another FloatPoint for the context position.

It also change the default color-space to linearRGB according to the spec. This must be adapted by other platforms and just works with CG atm.
Comment 2 Dirk Schulze 2009-10-17 14:12:01 PDT
Created attachment 41366 [details]
Fix mask context location, linerRGB as default color-space.

typo in last patch
Comment 3 Nikolas Zimmermann 2009-10-18 14:01:51 PDT
Comment on attachment 41366 [details]
Fix mask context location, linerRGB as default color-space.

Looks fine, r=me.
Comment 4 Dirk Schulze 2009-10-18 14:38:54 PDT
fix landed in r49757.