Release Notes

Unreleased

  • fbm2, fractal (fractional Brownian motion) noise: several octaves of perlin2 summed together, for noise with detail at every scale rather than at just one. Configurable octaves, persistence and lacunarity.
  • Measuring and sampling a SimplePath, all by distance travelled rather than by point index: length, pointAt, tangentAt and pointsAlong. Plus alongPath, which iterates over evenly spaced points along a path (or anything with one, e.g. Star), handing you the point and the angle the path heads in there.
  • withSymmetry, which draws its callback several times over with the canvas already rotated and/or reflected: "rotational", "mirror" or "kaleidoscope".
  • curl2, curl noise: a divergence free vector field taken from the curl of perlin2/fbm2, so lines following it swirl around each other instead of draining into the same few places as a naive noise-as-angle field does. Plus SimplePath.flowLine, which traces a path through any vector field.
  • Measuring a SimplePath as a shape: boundingBox (in the form Rect takes), area, containsPoint and convexHull, along with a standalone convexHull for bare points. And simplified, which drops the points that barely change a path's shape (Ramer-Douglas-Peucker).
  • harmony, which builds the classic colour schemes (complementary, analogous, triadic, tetradic, split complementary, monochrome) around a colour, and mixColors, which blends two colours the short way round the hue circle.
  • worley2, cellular noise: the distance to the nearest of a scattering of feature points, for the structured textures Perlin noise cannot give (scales, cobbles, cracked mud, stained glass). Configurable feature ("f1", "f2" or "difference", which draws the boundaries between cells), metric and jitter. Plus worleyCell2, which says which cell a point falls in, for colouring cells as a whole.
  • offset on a SimplePath: the parallel path, a fixed distance to one side, with mitred corners. Offset a line both ways and join the two up for a filled ribbon, or step the distance for contours inside a shape.
  • forRadialTiling, a polar forTiling: rings of cells going out from a centre, each ring divided into sectors, each cell a HollowArc ready to fill, with an optional hole in the middle and an optional partial turn for a fan.

0.20.0

  • Additional conversions from Arc, HollowArc, Ellipse, Circle and RoundedRect to SimplePath

0.19.0

  • Support for using fragment shaders (see some early docs).
    • Render a fragment shader to a texture (image) via renderShader
    • Render a Solandra sketch to a texture (image) via render
    • Pass images into shaders
    • Render these images in sketches (so can combine in both directions) via drawImage
    • Uses OffscreenCanvas (which is quite widely supported but not in Safari 16.x)
  • Poisson disc sampling iteration
  • Pseudorandom angle generation
  • transformLoopedPoints for non-determininistic transformations of looped points (basically make first and last point the same)
  • rotateAround helper
  • remove hack in place to work around Safari bugs with rendering text at 'small' (point) sizes
  • cache meta

0.18.0

Solandra was made by James Porter.

Check out the GitHub page or install with npm i solandra