different results unsing feTurbulence between inkscape and firefox

Bug #1489171 reported by Todd Shifflett
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Triaged
Medium
Unassigned

Bug Description

When writing out a png file with inkscape --export-png the following code will produce different results then what is seen and expected in firefox.

Something seems to function strangely with regard to the baseFrequency of feTurbulence. it has a very narrow window of change.
values of 0.1 to 0.0001 produce relatively similar results compared with their representation in the web browser.

values close to 0.1 yield similar results, however using lower values such as 0.001 produce two very different outcomes.

In addition, adding the 'primitiveUnits' parameter to the filter seems to result in no filter being applied.

  ( <filter id="L2" x="0" y="0" width="100%" height="100%" primitiveUnits="objectBoundingBox" > )

I'm running: Inkscape 0.91 r13725 (Jul 19 2015)
platform: Mac OSX 10.10.5

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <svg height="300" width="300" viewBox="0 0 300 300" >
        <defs>
            <filter id="F1" x="0" y="0" width="100%" height="100%" >
                <feTurbulence baseFrequency="0.01" numOctaves="1" type="turbulence" seed="1" stitchTiles="stitch" result="noise" />
            </filter>
        </defs>
        <rect x="0" y="0" width="300" height="300" rx="0" ry="0" stroke="#000" stroke-width="0.3" fill="#646464" opacity="1" filter="url(#F1)" />
    </svg>

tags: added: filters-svg svg
description: updated
description: updated
description: updated
description: updated
Revision history for this message
su_v (suv-lp) wrote :

Attaching example as separate file to ease testing (required namespace declaration added).

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

Attaching modified test case which renders the same in Inkscape 0.91 r13725, Inkscape 0.91+devel r14324 and e.g. Firefox.

Difference: disabled smooth transitions at the border of tiles (stitchTiles="nostitch")

See also:
http://www.w3.org/TR/SVG11/filters.html#feTurbulenceStitchTilesAttribute

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

Reproduced with Inkscape 0.91 r13725 and 0.91+devel r14324 on OS X 10.7.5
(similar result with Inkscape 0.47 and 0.48.5 -> no regression in the new renderer)

[ TODO: check for mention of 'stitchTiles' in existing reports. ]

Changed in inkscape:
importance: Undecided → Medium
status: New → Confirmed
Revision history for this message
jazzynico (jazzynico) wrote :

Also reproduced on Xubuntu 15.04, Inkscape 0.91.

Changed in inkscape:
status: Confirmed → Triaged
Revision history for this message
jazzynico (jazzynico) wrote :

Follow-up report: bug #1490123 "UI for setting stitchTiles attribute (feTurbulence) missing in the filters editor".

Revision history for this message
jazzynico (jazzynico) wrote :

Testing low frequency values to prevent divisions by zero seems to improve the rendering with Inkscape, but there are still differences when using very low frequency values (<0.005).
Attaching my test patch, in case it could help someone solve the issue properly.

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.