Expand description
Laying out many pixels at once: a grid, a ring, a path. Positions are in metres in the definition’s frame, x to the right and y down like the canvas, and pixels come out in DMX order.
Structs§
- Corner
Iter - An iterator over the variants of Corner
- Grid
Order Iter - An iterator over the variants of GridOrder
- Grid
Spec - Path
Spec - A path of straight segments through
points_m. - Pixel
Template - What every generated pixel shares.
- Ring
Spec
Enums§
- Corner
- The corner the first pixel sits in. It reads as the generator form words it.
- Grid
Order - Which way the DMX order runs through a grid. It reads as the generator form words it.
Functions§
- grid
- A grid of pixels centred on
centre_m. - path
- Pixels spread evenly along a path by arc length, each turned along its segment. On an open path the first sits on its start and the last on its end, as the old SVG lamps placed their LEDs; on a loop they are spaced evenly all the way round.
- ring
- Pixels evenly around a circle.
- single
- One pixel at
at_m. - smooth
- A smooth curve through
points, as straight pieces:stepsof them between two neighbouring points. It passes through every point (a Catmull-Rom spline), so a path clicked corner by corner becomes the curve a bent strip makes. A closed curve runs back round to the first point.