W3C home > Mailing lists > Public > www-svg@w3.org > February 2011

Re: SVG masks and luminance calculations

From: Dirk Schulze <vbs85@gmx.de>
Date: Thu, 3 Feb 2011 11:14:23 +0100
Cc: www-svg@w3.org, "Robert Longson" <longsonr@gmail.com>
Message-Id: <92C33765-4528-47F1-A427-6DF5BB71DDA5@gmx.de>
To: Erik Dahlstrom <ed@opera.com>
>> 
>> Given the fact that there are still bug reports about a wrong behavior on Firefox, it looks like the spec is a bit confusing here. I agree to Eric that linearRGB as default looks a bit confusing since the default of color-interpolation is sRGB. I guess the root of this phrasing is the specification of SVG Filters. The masking text relies to 'feColorMatrix'. And the default color space on filters is linearRGB[1].
>> Both confused me at the time I startet working on implementing masks[2] and filters. But filter has another property named 'color-interpolation-filters'. And the default value is linearRGB for this property. So even if I'm unsure why linearRGB was chosen, the definition looks clear here. This is different on Masking. And it might make sense to use sRGB as default.
>> The most(unsure about Safari/Win) ports of WebKit use linearRGB as default now, but it's no problem to change it back to sRGB. Note that the masking tests on the test suite would need new results, or the tests need to use  color-interpolation="linearRGB" explicitly.
> 
> I don't think that there are any tests in the testsuite where such a change would give a very different result visually.
> 
> It would make sense to include a test to clearly show the difference though. With gradients and with raster images with alpha.
> /Erik

We noticed a difference on masking-intro-01-f[1] and masking-mask-01-b[2] on running our pixel tests. But again, no new results are needed, if the <mask> elements include 'color-interpolation="linearRGB"'. This shouldn't be a problem, if a new test covers the differences between color spaces.

Cheers,
Dirk

[1] http://dev.w3.org/SVG/profiles/1.1F2/test/svg/masking-intro-01-f.svg
[2] http://dev.w3.org/SVG/profiles/1.1F2/test/svg/masking-mask-01-b.svg
Received on Thursday, 3 February 2011 10:15:03 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:47 GMT