RE: [ISSUE-2335] feConvolveMatrix bias property in SVG 1.1 SE

Hi Jasper,

Please see my comments below.

> -----Original Message-----
> From: Jasper van de Gronde [mailto:th.v.d.gronde@hccnet.nl]
> Sent: Wednesday, 10 November 2010 9:15 PM
> To: Anthony Grasso
> Cc: www-svg@w3.org; W3C SVG Public List
> Subject: Re: [ISSUE-2335] feConvolveMatrix bias property in SVG 1.1 SE
>
> Hi,
>
> I see the divisor as being nothing more or less than a convenient way
> of scaling the kernel, so not as a separate entity. So in the options I
> listed I assumed:
>    cF = cO (*) (kernel/divisor)
>    aF = aO (*) (kernel/divisor)
> With (*) standing for convolution, and cO/aO for the original color and
> alpha channels. (With the F standing for filtered.)
>

Ok. Thank you for the clarification.

When you originally raised this issue you suggested:
-------------------------------------
Option 2:
cR = cF + bias*aR
-------------------------------------

Just to clarify, the new formula in its expanded form, that you are suggesting is:
cR = cF + bias*aR

where: cF = cO (*) (kernel/divisor). Thus,

cR = (cO (*) (kernel/divisor)) + bias*aR


I assume then for aR:
aR = aF + bias

where: aF = aO (*) (kernel/divisor). Thus,

aR = (aO (*) (kernel/divisor)) + bias


So the suggested set of new equations is:
aR = (aO (*) (kernel/divisor)) + bias
cR = (cO (*) (kernel/divisor)) + bias*aR


Please let me know if the above is your intended suggestion, particularly if my assumption for aR is correct. I would like to test what the output looks like with the new equations.

Cheers,
Anthony

> Regards, Jasper
>
> On 2010-11-10 02:06, Anthony Grasso wrote:
> > Hi Jasper,
> >
> > I was given ACTION-2900 [1] to investigate the bias attribute.
> >
> > As you're aware the specification currently says when
> preserveAlpha="false" to apply the convolution to all channels.
> Currently in the specification, the formula to do the convolution for
> that case is:
> >
> > cR = (cF * kernel)/divisor + bias
> > aR = (aF * kernal)/divisor + bias
> >
> > I agree that the definition of 'bias' is not clear at all and should
> be changed.
> >
> > Regarding how it is used in a filter mathematically, your options
> listed below do not take into account the filter 'divisor' that the
> current formula does. I would like to know where you think the
> 'divisor' value fits in with your options that you have specified.
> >
> > Cheers,
> > Anthony
> >
> > [1] http://www.w3.org/Graphics/SVG/WG/track/actions/2900

> > ...
>  >> <quote>
>  >> For reference, the pseudo-code in the SVG  specification suggests
> the  >> following (preserveAlpha=false):
>  >> -------------------------------------
>  >> Option 1:
>  >>     aF = filtered alpha without bias
>  >>     cF = filtered (premultiplied) color without bias
>  >>     aR = aF + bias
>  >>     cR = cF + bias
>  >> -------------------------------------
>  >> ...
The information contained in this email message and any attachments may be confidential and may also be the subject to legal professional privilege. If you are not the intended recipient, any use, interference with, disclosure or copying of this material is unauthorised and prohibited. If you have received this email in error, please immediately advise the sender by return email and delete the information from your system.

Received on Thursday, 2 December 2010 05:33:36 UTC