From b54c6776953d3243ab5b8e676e747713827ab320 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Wed, 11 Nov 2026 17:42:07 -0300 Subject: canim: the disassembly under the source everywhere; rings From the user. In every split the disassembly stays under the source; registers a scene never changes fold three to a row, and the stack takes the room: nine to twenty slots where it had six. The graph's first form is rings: a loop a ring its blocks sit on, an inner loop a smaller ring touching its parent, a way out leaving along the tangent; layers stay for functions without loops. Its layout comes from the code alone and it shows nothing from after the moment: a block not reached yet is quiet and is reached, a fold of what is not reached yet opens when the run arrives. A pane unrolls from its strip into its whole column and rolls back. The sqlite scene's strips move before their panes. Co-Authored-By: Claude Fable 5.2 Claude-Session: https://claude.ai/code/session_016Y9MNCKgYCGiANnEwcEQxa --- anim/src/disasm.zig | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'anim/src/disasm.zig') diff --git a/anim/src/disasm.zig b/anim/src/disasm.zig index be3452f..7017453 100644 --- a/anim/src/disasm.zig +++ b/anim/src/disasm.zig @@ -87,7 +87,8 @@ pub const Disasm = struct { const from = listing(u, rec, now.marks[0], room); const to = listing(u, rec, now.marks[1], room); // On the map its box is as long as the instructions the recording has round the pc. - if (ui.mapping and d.measures) map.measure(.disasm, listing(u, rec, now.marks[1], theme.map.disasm_rows).rows.len); + // (Of the moment the pane shows: a continue's destination repacks the map as the pane goes there, not as it sets off.) + if (ui.mapping and d.measures) map.measure(.disasm, listing(u, rec, now.marks[if (going >= 0.5) 1 else 0], theme.map.disasm_rows).rows.len); const pc = [2]u64{ rec.register(now.marks[0], "rip"), rec.register(now.marks[1], "rip") }; // The function's name: one that changes with the advance crossfades over it. @@ -113,17 +114,17 @@ pub const Disasm = struct { var merged: []const Insn = to.rows; var offsets = [2]f32{ 0, 0 }; var fade: f32 = 1; - var faded_through = false; var shown = to; if (pc[0] != pc[1] and going < 1) { if (merge(u, from.rows, to.rows)) |both| { merged = both.rows; offsets = .{ @floatFromInt(both.from), @floatFromInt(both.to) }; } else { - merged = if (going < 0.5) from.rows else to.rows; - shown = if (going < 0.5) from else to; - fade = @abs(2 * going - 1); - faded_through = true; + // On the map, for the strip, the other column as the advance starts: the strip shows where the pane goes first. + const over = if (ui.mapping) going > 0 else going >= 0.5; + merged = if (over) to.rows else from.rows; + shown = if (over) to else from; + fade = if (ui.mapping) 1 else @abs(2 * going - 1); } } const scroll = std.math.lerp(offsets[0], offsets[1], cursors.glide(going)); @@ -244,9 +245,9 @@ pub const Disasm = struct { lit.route(&.{ .{ 38, ya }, .{ c.jump_lane, ya }, .{ c.jump_lane, yb }, .{ 39, yb } }, theme.color.trail[0], .{ .width = theme.stroke.rule, .head = .{ 7, 8 }, .radius = 4 }); } context.veiled(u, box, now.veil); - // A window going to another column (another function) fades through, and its strip with it. - const column_changes = faded_through and (from.rows.len == 0 or to.rows.len == 0 or !(map.inColumn(.disasm, .{ from.rows[0].addr, from.rows[from.rows.len - 1].addr }) and map.inColumn(.disasm, .{ to.rows[0].addr, to.rows[to.rows.len - 1].addr }))); - map.strip(.disasm, if (column_changes) u.faded(map.through(now, now.plan.travel)) else u, box); + // A window going to another column (another function): its strip goes over + // as the advance starts (the strip's drawings are 6 f apart: the column going over is a 6 f crossfade on it, ahead of the pane's fade.) + map.strip(.disasm, u, box); } pub const State = union(enum) { -- cgit v1.3