# Build floor shadows three times faster, without the faces that add nothing · dara/icarus

[View on GitCafe](https://git.cafe/dara/icarus/commit/795b9c961ecceb3cadbac38400bb8e98280e2aae)

Repository: [dara/icarus](https://git.cafe/dara/icarus)

Visibility: public

Requested revision: 795b9c961ecceb3cadbac38400bb8e98280e2aae

Requested commit: 795b9c961ecceb3cadbac38400bb8e98280e2aae

Commit: 795b9c961ecceb3cadbac38400bb8e98280e2aae

Tree: 5d3f7409c82b13f86f36fae905358ebfe075516b

Author: Dara Adedeji

Committer: Dara Adedeji

## Message

```
Build floor shadows three times faster, without the faces that add nothing

A Lotus or Icebox cone built 900-2,200 shadow faces per frame, each a
rectangle clipped through lists and closures: 3 ms typical, 17 ms at p99 in
a profile-mode drag. Faces are now clipped in flat buffers, a face whose
wedge misses the floor is dropped before any clipping, and where a shadow
runs on for ever only the edges facing the eye cast it: an edge facing away
shades what the near side already shades. On 113 Lotus and Icebox cones the
shadows cover exactly the same 22,600 sample points, with 46% fewer faces
in a third of the time.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

```

## Parents

- [3729ad1b3e3f7c3324d3c0b12b7ae0606edfe3be](https://git.cafe/dara/icarus/commit/3729ad1b3e3f7c3324d3c0b12b7ae0606edfe3be?format=markdown)

[Source at this commit](https://git.cafe/dara/icarus/tree/795b9c961ecceb3cadbac38400bb8e98280e2aae?format=markdown)
