Re: patternTransform

Just in case someone is interested in, a simple reduction. Works in Batik and IE so far:

<svg xmlns="http://www.w3.org/2000/svg">
<defs>
<pattern id="pattern" width="5" height="5" patternUnits="userSpaceOnUse" patternTransform="scale(40)">
	<circle cx="2.5" cy="2.5" r="2.5" fill="lime" />
</pattern>
</defs>
<rect width="200" height="200" fill="url(#pattern)"/>
</svg>

Looks like WebKit does indeed just take the viewBox into account for calculating the correct tile size. Shouldn't be hard to fix.

Am 03.10.2011 um 16:04 schrieb Erik Dahlstrom:

> On Mon, 03 Oct 2011 12:44:23 +0200, Dirk Schulze <vbs85@gmx.de> wrote:
> 
>> 
>> Am 03.10.2011 um 12:14 schrieb Domenico Strazzullo:
> ...
>>> You can check some results here: http://dotuscomus.com/pergola/download/pergola_1.3.6/ExamplesHTML/Patterns/patterns.html
>>> 
>>> Domenico
>> 
>> You should specify your question. I assume you mean the pixelation on the pattern tiles. IIRC all implementations try to avoid pixelated tiles. And normally it works quite well. I haven't checked why Opera, Firefox and WebKit fail on your example yet. But ideally patterns should never look pixelated, independent of the pattern transform, viewBox or other transformations.
> 
> I agree that it would be better to render the pattern tile so that it doesn't look pixelated or blurred. Opera currently doesn't compensate for patternTransform scaling, but a patch for that is in the works.
> 
> Cheers
> -- 
> Erik Dahlstrom, Core Technology Developer, Opera Software
> Co-Chair, W3C SVG Working Group
> Personal blog: http://my.opera.com/macdev_ed
> 

Received on Monday, 3 October 2011 15:13:56 UTC