Four independent coin flips per cell, each one deciding whether a pair of pipes runs straight or detours.
Four decisions per cell, not one
Where the earlier Recursive Subdivision pieces flip one coin per cell, this one
flips four — one for each quadrant, drawn independently:
private void DrawLeaf(SKCanvas canvas, float x, float y, float s, float detourTurn, SeededRandom rng)
{
foreach (var rotation in ArmRotations)
DrawArm(canvas, x, y, s, detourTurn, rng, rotation);
}
The four arms are one motif — a pair of pipes — drawn in a local frame and
rotated into each quadrant by an exact quarter-turn matrix, so the code
carries one arm’s geometry, not four copies of it.
At the deepest rendering that is 256 cells × 4 quadrants = 1024 independent bits, and
because the quadrants of a single cell do not consult each other, a cell has sixteen
possible appearances rather than two.
One cell at full size, all four quadrants visible. Two of them have taken the
straight option and two the detour, and that mixture is already the piece’s whole
character.
Straight or detour
Each quadrant carries a pair of parallel pipes running from the cell edge to the
centre lines. The coin decides between two ways of getting there:
if (rng.NextDouble() < 0.5)
{
// detour: a plate on the quarter line plus a three-sided bracket
}
else
{
// straight: two parallel rails from the quarter line to the edge
}
The straight option is two segments. The detour is four, and it turns at
detourTurn × s, where
detourTurn = 1 - WidthParam;
WidthParam is 0.25 by default, so the detour turns at three quarters of the way
out. That single number sets how deep every detour cuts, and it is the only
continuous parameter in the piece — everything else is a coin. The coin itself need
not be fair: DetourProbability biases it, and several presets lean on that, as
does the underlay field that Pipe Echo draws beneath its main one.
One division, sixteen decisions. The detours are what stop the drawing being a
grid.
Sixteen cells. Because every pipe end lands on a quarter point of a cell edge, and
every neighbour’s does too, pipes cross cell boundaries without a join being drawn.
Runs of pipe now cross several cells.
Sixty-four cells and 256 flips.
Two hundred and fifty-six cells. A thousand independent decisions, and no two
quadrants in the drawing were coordinated.
Depth replaces, it does not refine
A leaf that subdivides is deleted and replaced by four leaves, each drawing its own
four quadrants at half the size from the next values in the sequence. So the stages
above are five separate drawings of one rule, not one drawing gaining detail — which
is what recursive subdivision means, and is worth seeing rather than assuming.
Seven renderings
The piece ships as seven presets — one per direction the rule can be pushed. Pipe
Cyan is the marquee: the even coin, framed on black. Every other preset varies
something structural, not just the ink:
| Rendering | The difference |
|---|
| Pipe Cyan | the even coin, framed on black — the lead |
| Pipe Magenta | one subdivision deeper: 1024 cells read as a dense weave |
| Pipe Cobalt | full bleed: the square is enlarged until the canvas crops it on all sides |
| Pipe Amber | a three-quarter detour coin turns the field into a lattice of sockets |
| Pipe Loom | a one-in-eight coin leaves mostly open corridors, brackets as accents |
| Pipe Echo | a coarse second field in deep blue, offset beneath the fine one |
| Pipe Paper | ink on warm paper instead of neon on black |
Hung
The piece ships one museum presentation — a single gallery plate,
museum-pipe-cyan, that shows the lead the way it would hang on a wall.
MuseumFrame — the presentation layer from SkiaSharp.Extensions — clears to
a gallery wall, draws a frame, a mat with a bevel rule, and the artwork
contain-fitted into the opening behind them, with a soft drop shadow lifting
the frame off the wall. The proportions are fixed: the opening keeps 65 % of
the canvas in each axis, the mat and the frame are fixed fractions of the
shorter side around it, and the artwork is clipped at the mat edge, so
nothing it draws bleeds onto the wall.
The treatment is presentation, not a new family of renderings: it wraps the
finished drawing and adds nothing to the rule itself. Pipe Cyan appears in
the gallery twice — once as the raw plate, once framed — and no other
rendering gets a framed copy: one plate, the way one work hangs on one wall.
The field the presets draw on is part of the same decision. Every rendering
fills 600 of the 800-pixel canvas — a surround that reads as the piece’s own
mat — except Pipe Cobalt, which bleeds past the edge on purpose.
Determinism
SeededRandom — the project’s stable Xoshiro256StarStar — is seeded from the
preset and consumed four times per leaf, quadrant by quadrant, in the subdivision’s
own traversal order. Same seed, same drawing, on any machine.