code wiki / _hdl_build / nx_gltf_load_gate.nx
nx_gltf_load_gate.nx
buildroot/runtime/_hdl_build/nx_gltf_load_gate.nx
about
nx_gltf_load_gate.nx -- ★NATIVE sovereign glTF viewer gate: load our exported nishi_being.glb back into the Nishi
renderer and render it (round-trip on OUR OWN stack), AND ★D1 FAIL-CLOSED teeth (debt 1785902685, 2026-08-12):
T5-T10 feed malformed/unsupported glbs assembled AT RUNTIME in /tmp -> the loader must REFUSE with the exact NAMED
reason, never segfault. T7 is the POSITIVE CONTROL (a valid minimal Khronos-shaped glb with u16 indices MUST load)
so a refuse-everything guard cannot pass. gv-migrated (D001): verdict comes from nx_gate_verdict, exit carries it.
license_tier: ORIGINAL expect_exit: 0
dependencies 5 imports · 0 importers
imports: nx_syscalls.nxnx_png.nxnx_trimesh.nxnx_gltf_load.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
structs
| none |
consts
| 157 | const BG: i64 = 24 + 26*256 + 34*65536 |
| 158 | const W: i64 = 300 |
| 159 | const H: i64 = 460 |
functions
| 13 | func clearfb(fb: *i64, n: i64, c: i64) -> i64 { var i: i64=0; while i<n { fb[i]=c; i=i+1 } return 0 } called by 1: main |
| 14 | func filled(fb: *i64, n: i64, bg: i64) -> i64 { var c: i64=0; var i: i64=0; while i<n { if fb[i]!=bg { c=c+1 } i=i+1 } return c } called by 1: main |
| 17 | func gstreq(a: *u8, b: *u8) -> i64 |
| 28 | func gwfile(path: *u8, b: *u8, n: i64) -> i64 |
| 35 | func gw32(b: *u8, at: i64, v: i64) -> i64 |
| 42 | func gw16(b: *u8, at: i64, v: i64) -> i64 |
| 47 | func gputs(b: *u8, at: i64, s: *u8) -> i64 |
| 52 | func gputn(b: *u8, at: i64, v: i64) -> i64 |
| 64 | func mkglb(path: *u8, ct: i64, io: i64, ia: i64, ibb: i64, ic: i64) -> i64 |
| 98 | func refuse_tooth(path: *u8, want: *u8) -> i64 |
| 114 | func mk2glb(path: *u8) -> i64 |
| 161 | func main() -> i64 |