Skip to content

Page: a person view of who built what; cleaner street centre lines - #9

Merged
Fengzdadi merged 6 commits into
mainfrom
page/builders
Nov 3, 2026
Merged

Fengzdadi merged 6 commits into
mainfrom
page/builders

Conversation

@Fengzdadi

Copy link
Copy Markdown
Owner

Follows #8.

Who built what, as a person view

  • A "who built this city" panel (B, or the people button) lists everyone by buildings built, with their GitHub face.
  • Picking someone lights their buildings. The rest of the city fades to soft grey ghosts, their buildings flash once, the camera frames them, and small arrows mark them when there are 24 or fewer.
  • Their card shows commits, years and where they built. Two tiles switch between buildings they built and buildings where they made the most commits.
  • ?by=<name>[&most] opens the city on that person.
  • Building tooltips name who built it and who made the most commits. District labels carry the founder's face.
  • Share card for one person (landscape, square, story). On the hosted site, ?by= links preview with that card, drawn headless and stored in R2 per person.

Scanner

  • Per author it keeps the latest commit hash, a login when the email is a GitHub noreply address, a commit count and first/last dates. It also keeps the repo's GitHub slug from remote.origin.url. Emails still never leave the scan.
  • Each building records who made the most of its commits, only when that isn't its builder. Snapshots moved only in that field.
  • The hosted SCANNER version (container/version.mjs) still needs a bump before hosted cities get faces and most.

Streets

  • Centre lines are found in a band near street centres, not over the whole field: 186 ms on postgres, down from ~730 ms.
  • One-sided roads (the ring road, river banks) get centre lines too.
  • Cars no longer show over the water.

Tests

npm test: preload, layout, history (20 cases) and snapshots all pass.

🤖 Generated with Claude Code

Fengzdadi and others added 6 commits November 3, 2026 00:40
Street centre lines were found per pixel as the ridge of the 8-bit
distance field. Rounding left flat spots all over the asphalt, so the
test fired at random and the roads were covered in white specks; the
dash direction came from an angle that wraps at 0/π and dashes were
measured from the world origin, so they broke up.

- streets: a second sweep finds each texel's nearest *other* block, and
  near the middle of a street the distances to the two blocks' outlines
  give a signed distance to the centre line (B) and a mask of where one
  may be drawn (A). Distances are to the line of the side a street runs
  along, so the centre line carries on across the mouth of a narrower
  side street and stops out in a junction. Streets with a block on one
  side only (open land, a river bank) have none.
- A second RG texture says where the dashes fall: the length round one
  of the two blocks' outlines, as an angle so it filters without a seam.
  Dashes keep their spacing round curved streets.
- surfaces: the line is a pixel wide (wider with the street, close up);
  dashes are as before at the default zoom and lengthen zoomed out.

Streets build in ~113 ms on flask, up from ~45 ms.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The second distance sweep that told each texel which block is across
the street ran over the whole field: on postgres (2555² texels) it took
~320 ms and ~90 MB of arrays, to be read only near street centres.

Now the centre is found where two street texels side by side have
different nearest blocks, and that block pair spreads 8 texels either
side; only that band is measured and drawn. Streets build in 72 ms on
flask (was 113) and 186 ms on postgres (was ~730), and the field keeps
one 16-bit array instead of four.

The two blocks must face each other, both where a line starts and at
every texel drawn. Two blocks side by side meet along a boundary that
runs on out into the street they both front; without the check that
boundary drew false lines across it. With it, the wide street past the
ends of flask's rows gets one continuous centre line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A street with a block on one side only had no centre line: the ring
road round the city's edge, and roads along a river bank. Those now get
one too, halfway between the block's side and the far edge: the river
bank, or where the asphalt stops on open land. Lanes follow it, so cars
drive their side of the road rather than hugging the block.

A car could show on the water where a street ran along a river: its
centre was on the street but its front or back hung over the bank (313
of 510,575 car positions on postgres). Each route sample now keeps how
far it is from the water, and a car shows only where all of it is
clear. On postgres none are over water now, with 175 cars (was 171).

Two-sided centre lines also stop where the water comes between the two
blocks, so a river no longer gets a line drawn across it.

Streets build in 116 ms on flask (was 72) and 232 ms on postgres (was
186).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The colour map of builders is gone. In its place, a "who built this
city" panel (B, or the people button) lists everyone by buildings
built, with their GitHub face. Picking someone lights their buildings:
the rest fade to soft grey ghosts, theirs flash once, the camera frames
them, and small arrows mark them when there are 24 or fewer. Their card
shows commits, years, where they built, and two tiles to switch between
buildings they built and buildings where they made the most commits.
?by=<name>[&most] opens the city on that person.

Building tooltips name who built it and who made the most commits, with
faces. District labels carry the founder's face.

The scanner keeps, per author, the latest commit hash, a login when the
email is a GitHub noreply address, a commit count and first/last dates,
plus the repo's github slug from remote.origin.url. Emails still never
leave the scan. Each building also records who made the most of its
commits (only when that isn't its builder). Snapshots moved only in that
field.

A person's buildings share as their own card (landscape, square and
story), and on the hosted site ?by= links preview with that card,
drawn headless and stored in R2 per person.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A car could drive right through a street tree. A block's lane and its
tree line were each one distance for the whole block, taken from its
narrower sides; since one-sided roads got their centre halfway to the
bank, a block with a canal on one side pulled its lane in to the kerb
on every side, where the trees stand. On postgres 65% of car positions
touched a tree trunk.

- Each side of a block now keeps its own lane distance (offset() takes
  one per side), so the wide road along the city's edge and the narrow
  road along a canal each get theirs.
- A long side is walked from five places and the middle answer kept:
  one walk from the middle of a side could cross a bridge, miss the
  water, and put the lane on the road's centre line.
- Street trees stand far enough in from the lane for their canopy to
  clear a bus. A side too narrow for that, where cars drive, gets no
  street trees.

Car positions under a tree canopy: postgres 0 (was 1% before the
one-sided roads, 65% after), ky 1.1% (was 15%; what's left is yard
trees). Fewer street trees on narrow roads: postgres 442 (was 774), ky
142 (was 227).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Picking someone who built nothing (they only made the most commits on
  some buildings) lit nothing and sent the camera to the world origin.
  Their buildings by most commits are lit instead, and a tile with no
  buildings can't be picked.
- On a phone the panel spans the foot of the screen, so the lit
  buildings are framed above it, not to its left (where they were
  pushed off the edge).
- District signs no longer ask GitHub for their founder's face: there
  are enough signs to use up a visitor's 60 lookups an hour before they
  open anything. Only faces already known are shown there.
- A GitHub hiccup (5xx) is no longer remembered as "no face".
- The marker limit counts only buildings standing at the end, as the
  card does.
- gitropolis.dev: a ?by= link's preview title and description name the
  person only when they're one of the city's authors (any text could
  be put in the preview otherwise). Each city now keeps a small list of
  its people beside it, so checking a name, or drawing someone's card,
  doesn't read and parse the whole city each time.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Fengzdadi
Fengzdadi merged commit 1b474f5 into main Nov 3, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant