W3C home > Mailing lists > Public > public-fx@w3.org > January to March 2015

Re: [filter-effects] Bug in feTurbulance random algorithm.

From: <ryan.richards@ani-mayhem.com>
Date: Tue, 13 Jan 2015 20:12:51 -0800
Message-ID: <2bbd7482a7600b61cb45439c7ca85e72.squirrel@mail.ani-mayhem.com>
To: "public-fx@w3.org" <public-fx@w3.org>
Changing

fGradient[k][i][0] /= s;
fGradient[k][i][1] /= s;

to

fGradient[k][i][0] = (fGradient[k][i][0] == 0 ? 0 : fGradient[k][i][0] / s);
fGradient[k][i][1] = (fGradient[k][i][1] == 0 ? 0 : fGradient[k][i][1] / s);

in the reference code would do it.

"For fractalSum, you get a turbFunctionResult that is aimed at a range of
-1 to 1"
"For turbulence, you get a turbFunctionResult that is aimed at a range of
0 to 1"

0 is in both of those ranges.

And some fun facts. There are 8,465,580 affected seeds. From 346 to
2,147,483,583
Received on Wednesday, 14 January 2015 04:13:41 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:49:52 UTC