docs: record the paint-order key as landed, with what it left unsettled

This commit is contained in:
Sylpheed RE agent
2026-08-19 05:43:29 +00:00
parent deff5a4d6d
commit fb4f035f08

View File

@@ -31,16 +31,30 @@ the per-element visibility toggles still line up.
**Derivation found (2026-08-19)**: the order sorts by the word at **`+0x08` of **Derivation found (2026-08-19)**: the order sorts by the word at **`+0x08` of
the T8aD sprite header** — non-decreasing in paint order on both measured the T8aD sprite header** — non-decreasing in paint order on both measured
screens, with no inversion, and on the splash it explains the whole permutation. screens, with no inversion, and on the splash it explains the whole permutation.
See [`structures/ui-paint-order-key.md`](structures/ui-paint-order-key.md). Not See [`structures/ui-paint-order-key.md`](structures/ui-paint-order-key.md).
yet wired into the compositor, and its ties are unexplained.
**Still open:** the tie-break, what the field's bits mean, and a third measured **Wired into the compositor (2026-08-19)** and regression-checked. `compose`
screen to promote this from "holds on two" to a rule. Also still open, and sorts by the key for every build except the two whose measured order is hard
unaffected by the key: deriving the order for screens nobody has captured. It is not in the declaration entry, the placement region or the runtime coded. It reorders **341 of 965 builds**, and a disc-gated test asserts every
element record (all measured); what remains is the loader that builds the child composite's draw list is strictly increasing in `(key, declaration index)`.
list. The order is deterministic across boots, so a rule exists — it just has not Against the two screens the corpus had already verified against the running game
been found, and every screen without a measured order still paints in declaration — the tutorial PAUSE menu and the title main menu — the new order changes 3.8 %
order. and 1.1 % of pixels, max delta 45/255, **with no layout change**: only blends
where translucent sprites overlap.
**Still open:**
* 🟡 Which order is more faithful on those two verified screens. The difference
is too small to decide against the committed side-by-side oracle and no fresh
framebuffer capture of either exists. First thing to check if one is taken.
* ❔ The tie-break. Two groups share a key and the game paints them in an order
that is not declaration order; the compositor keeps declaration order there.
* ❔ What the field's bits mean — `0x8000`/`0x80a0`/`0xa110` look like flag words
with a layer in some bits, not a plain depth. Sorting the whole word works on
both measured screens; which bits carry the layer is unknown.
* ❔ A third measured permutation, to promote "holds on two" to a rule. The
cheapest is a screen whose object is resident at the same time as the title's.
* ❔ 341 builds now composite in an order no capture has checked.
The investigation that got here follows, kept in full because most of it is The investigation that got here follows, kept in full because most of it is
refutations that were worth the cost. refutations that were worth the cost.