diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-11 06:49:10 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-11 06:50:11 -0300 |
| commit | 378379807fb4cd751e90808c8363caddb365bcd8 (patch) | |
| tree | f84c7d0e7cbd42a9b9c93e791ab2b5376499d23d /anim/src/hexdump.zig | |
| parent | 5922ee911b9a6604f60dc83be36ba9e6c9abac98 (diff) | |
| download | computeranim-378379807fb4cd751e90808c8363caddb365bcd8.tar.gz computeranim-378379807fb4cd751e90808c8363caddb365bcd8.zip | |
canim: nothing changes in one frame; the map's space is used; the heap scene at its storyboard's length
The motion check counts a third of the one-frame changes it did: the
minimap's changes fade, and a register's value, a flag, a role, a pin's
names, a tag's note, a backtrace row, a call tree's node and a dump row
crossfade where they changed at once. What still fires is named in the
README; an encoder's keyframe and the gallery's cuts are exempt by name.
No caption stands over twelve seconds or under its reading time. The
heap scene is 78 s: what the storyboard does not narrate runs, and each
free's line cascades onto its call row (line stepping stops at a
breakpoint for that). On the map, leftover space holds the stack
continued, dumps round what the registers and the stack point at, open
loupes and the key: between 1% and 13% of a map is page, where it was 14%
to 42%.
Co-Authored-By: Claude Fable 5.2 <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNCKgYCGiANnEwcEQxa
Diffstat (limited to 'anim/src/hexdump.zig')
| -rw-r--r-- | anim/src/hexdump.zig | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/anim/src/hexdump.zig b/anim/src/hexdump.zig index 3abd052..47283e7 100644 --- a/anim/src/hexdump.zig +++ b/anim/src/hexdump.zig @@ -242,6 +242,27 @@ fn crossfade(now: cursors.Now) Passes { return .{ .moments = .{ now.shown(.memory), undefined }, .shows = .{ 1, 0 }, .n = 1 }; } +/// `crossfade`, for one row: at a walk too, a row whose bytes the step +/// changed where the recording saw no write (memory nothing watches, read +/// anew at the stop), or that became known, crossfades over 12 f from +/// memory's slot. Nothing changes in a frame. +fn rowPasses(now: cursors.Now, addr: u64) Passes { + const plain = crossfade(now); + if (plain.n == 2 or now.resting() or now.plan.gait != .walk or now.writeAge(addr, 16) == 0) return plain; + const q = std.math.clamp(now.since(.memory, 0) / theme.time.quick, 0, 1); + if (q <= 0 or q >= 1) return plain; + var was: [16]u8 = undefined; + var is: [16]u8 = undefined; + var known_was: [16]bool = undefined; + var known_is: [16]bool = undefined; + now.before().read(addr, &was, &known_was) catch return plain; + now.moment().read(addr, &is, &known_is) catch return plain; + for (0..16) |i| if (known_was[i] != known_is[i] or (known_is[i] and was[i] != is[i])) { + return .{ .moments = .{ now.before(), now.moment() }, .shows = .{ 1 - q, q }, .n = 2 }; + }; + return plain; +} + /// A row of a panel: its first byte's address and its top. pub const RowAt = struct { addr: u64, y: f32 }; @@ -418,9 +439,10 @@ pub fn fielded(v: View, now: cursors.Now, y: f32, of: Fields) void { ry += m.row; } last = r; - const passes = crossfade(now); + const passes = rowPasses(now, of.base + 16 * r); for (passes.moments[0..passes.n], passes.shows[0..passes.n]) |mm, shows| fieldRow(u.faded(shows), now, ry, of.base + 16 * r, if (passes.n == 2) mm else moment, of, lead, shift); at_rows.append(u.f.scratch, .{ .addr = of.base + 16 * r, .y = ry }) catch {}; + @import("map.zig").row(.view, of.base + 16 * r, u, .{ .x = 0, .y = ry, .w = 860, .h = m.row }); ry += m.row; } if (shown[shown.len - 1] < total - 1) more(u, ry, total - 1 - shown[shown.len - 1]); |
