PeachDrawing
PeachDrawing.Filters
Turbulence Class
Perlin noise exactly as the SVG specification’s reference implementation defines it (Filter Effects 1, feTurbulence),
so a given seed, frequency and octave count yields the same picture every conforming renderer draws.
public sealed class Turbulence
Inheritance System.Object → Turbulence
| Constructors | |
|---|---|
| Turbulence(long) | Creates a generator seeded per the SVG reference algorithm. |
| Methods | |
|---|---|
| Render(RasterSurface, double, double, double, double, int, bool, bool, double, double, double, double) | Fills surface with the noise, sampling each pixel’s centre in user space (pixelsPerUserX pixels per user unit) and premultiplying the result, which the reference algorithm defines as straight colour. |
| Sample(int, double, double, double, double, int, bool, bool, double, double, double, double) | The noise value of one colour channel at a point of the filter’s user space. |