code wiki / _hdl_build / nx_craft_erosion_shot_gate.nx

nx_craft_erosion_shot_gate.nx

buildroot/runtime/_hdl_build/nx_craft_erosion_shot_gate.nx

14169 B225 linesdepth 8pulls 42 transitivereach 0 importersview sourcekind gate/prooftopic craft
docsdependenciesstructsconstsfunctions

about

nx_craft_erosion_shot_gate.nx -- IS THE PUBLISHED BEFORE/AFTER PAIR ACTUALLY A PAIR? (2026-08-25) THE SUBJECT IS THE PUBLISHED PIXELS, AND THAT IS DELIBERATE. The operator validates by LOOKING, so the thing that must be true is a property of the four PNGs sitting in the docroot: they decode, they are pictures of the shipped module's own frame, the craft pair DIFFER, both sides are VARIED, and the control world -- one asked for with no relief at all -- produces two PIXEL-IDENTICAL frames. This gate decodes the exact bytes a browser will decode, with the estate's own decoder, and asserts those five things. * WHY IT DOES NOT RE-RENDER, STATED PLAINLY RATHER THAN LEFT AS A GAP. Re-deriving the pair means worldgen, and worldgen through the wasm INTERPRETER was MEASURED at init_ms=119382 for ONE scenario (nx_craft_erosion_shot, 2026-08-25, plus 4.84 ms per ray of render on top). Four scenarios is roughly 10 minutes at the coarsest resolution the module offers. No roster deadline in this estate admits that -- the slow roster's own beat allows 60000 ms -- so a re-rendering gate could not be run by anything, and a gate nobody runs is a comment. The heavy live proof already EXISTS and is not duplicated here: nx_wasm_craft_vm_gate runs the shipped wasm and measures that the ground itself moves (talus 154/256, 509 of 576 lattice heights moved, rugosity 88 -> 75 permil) and that the renderer paints a varied frame. This gate owns the layer that one cannot see: whether the pictures on the page are real, different, and honestly captioned. * AND THE PAIRING IS A FREE CROSS-CHECK, NOT A DUPLICATE RULER. The producer counts differing pixels in the wasm FRAMEBUFFER; this gate counts them in the DECODED PNG. They are two instruments over one claim with the encoder in between, so a disagreement between the two numbers locates a defect in the encode/publish path that neither could find alone. Both numbers are printed so the comparison is available to a reader without re-running anything. license_tier: ORIGINAL expect_exit: 0

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_wasm_craft.nx nx_png_decoder.nx nx_gate_verdict.nx nx_craft_erosion_shot_gate.nx

imports: nx_syscalls.nxnx_wasm_craft.nxnx_png_decoder.nxnx_gate_verdict.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main gv_ctr sys_mmap nxa_die sys_write sys_exit nxa_lock_take nxa_lock_addr sys_write ↻ nxa_lock_give nxa_lock_addr ↻ nxa_report_overrun sys_write ↻ nxa_dump_printable sys_write ↻ nxa_dump_sizes sys_write ↻ gv_head gv_puts sys_write ↻ eg_load sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_munmap sys_close nx_png_decode sys_mmap ↻ _png_check_signature _png_read_u32_be nx_crc32 nx_crc32_update nx_crc32_init nx_crc32_table_at _png_n_channels _png_bytes_per_pixel _png_n_channels ↻

structs

none

consts

47const EG_CRAFT_OFF: *u8 = "sites/nishifamily/world/erosion_craft_off.png"
48const EG_CRAFT_ON: *u8 = "sites/nishifamily/world/erosion_craft_on.png"
49const EG_FLAT_OFF: *u8 = "sites/nishifamily/world/erosion_flat_off.png"
50const EG_FLAT_ON: *u8 = "sites/nishifamily/world/erosion_flat_on.png"
51const EG_SUBJECTS: i64 = 4
52const EG_BOX: i64 = 16
53const EG_PERMIL: i64 = 1000
54const EG_FLATVAL: i64 = 77 // the single value the synthetic FLAT frame is filled with. Any

functions

58func eg_w(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
called by 2: eg_describemain calls 1: sys_write
59func eg_n(v: i64) -> i64 { gv_num(v); return 0 }
called by 2: eg_describemain calls 1: gv_num
63func eg_load(path: *u8) -> *NxPngResult
76func eg_qstep(w: i64, h: i64) -> i64
called by 2: eg_describemain
90func eg_is_flat(px: *u8, n: i64) -> i64
called by 1: main
98func eg_diff_px(a: *NxPngResult, b: *NxPngResult) -> i64
called by 1: main
118func eg_describe(tag: *u8, r: *NxPngResult) -> i64
called by 1: main calls 3: eg_weg_neg_qstep
128func main() -> i64