Record the snap as approved and CPU rounding as recommended
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
c0b0921973
commit
4763e1a70d
1 file changed
+19
-4
+19
-4
@@ -218,8 +218,10 @@ fn snap_floor(v: vec2<f32>) -> vec2<f32> {
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
A rendering decision, so proposed rather than made. The check is the
|
Approved by Bryan on 2026-09-17, together with rounding on the CPU; see
|
||||||
reference render set plus the oracle; expect `tabs` to move its arcs back.
|
item 5 under "Next" for why both, and what each does not fix. The check is
|
||||||
|
the reference render set plus the oracle; expect `tabs` to move its arcs
|
||||||
|
back.
|
||||||
|
|
||||||
### Smaller items
|
### Smaller items
|
||||||
|
|
||||||
@@ -641,8 +643,21 @@ In order, from the review above and Bryan's steer (2026-09-17):
|
|||||||
3. Keep the `DrawInfo` on `ActiveData`; delete the copied fields and the
|
3. Keep the `DrawInfo` on `ActiveData`; delete the copied fields and the
|
||||||
reconstruction in `redraw`.
|
reconstruction in `redraw`.
|
||||||
4. `Span`'s leftover boundary through `Holds::through`.
|
4. `Span`'s leftover boundary through `Holds::through`.
|
||||||
5. The shader snap, if Bryan takes it: change, then the render set and the
|
5. **Round on the CPU and snap to the nearest pixel in the shader**, as
|
||||||
oracle.
|
one change with one verification. Bryan approved the snap on 2026-09-17
|
||||||
|
(rendering may change wherever it brings the screen closer to what the
|
||||||
|
user's code says: three equal sections of 1000 px need one of them
|
||||||
|
rounded up). CPU rounding is recommended for a different reason: a
|
||||||
|
`Rel` is off by at most `2^-25` of its box, so with round-to-nearest
|
||||||
|
every product whose true value is a whole number of steps is exact for
|
||||||
|
boxes under about 8,000 px, where truncation leaves half of them one
|
||||||
|
step short and layout then decides "does not fit" on a container the
|
||||||
|
user meant to fit exactly. Use the branchless round-half-up form,
|
||||||
|
`(a * b + (1 << (BY - 1))) >> BY`, not the sign-branching
|
||||||
|
`shift_round`; re-derive `Holds::through` for `round` (its two shifted
|
||||||
|
bounds move by half a `Rel` step); check with `nm` that `UiSpan::within`
|
||||||
|
still inlines; expect a couple of percent of instructions and re-run the
|
||||||
|
long fuzzers and the render set once for both.
|
||||||
6. The smaller items: the stale `f32` comment, the gap of an undrawn child,
|
6. The smaller items: the stale `f32` comment, the gap of an undrawn child,
|
||||||
confirm nested `leftover` weights, one zero-divisor fallback.
|
confirm nested `leftover` weights, one zero-divisor fallback.
|
||||||
7. `LazySpan`, the next LAYOUT.md §2 item. Region nodes cover the movable
|
7. `LazySpan`, the next LAYOUT.md §2 item. Region nodes cover the movable
|
||||||
|
|||||||
Reference in new issue
Block a user