code wiki / _hdl_build / nx_detail_gate.nx

nx_detail_gate.nx

buildroot/runtime/_hdl_build/nx_detail_gate.nx

6927 B157 linesdepth 4pulls 6 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_detail_gate.nx -- gate for the DETAIL ARCHITECTURE (subdiv+displacement engine + anatomy registry). T1 SUBDIVISION exact: box 8v/12t -> L1 26v/48t -> L2 98v/192t (midpoint dedup = watertight, counts PROVE it) T2 DETAIL FIELD: displace L2 with a bump field (density 96/256, amp 40) -> bumped-vert count in the binomial ballpark, every bump ALONG the normal, magnitude <= amp T3 CRACK-FREE LAW: displacing the SAME geometry twice (same seed) -> byte-identical; different seed -> differs T4 ANATOMY REGISTRY: rows for nipple/areola/MONTGOMERY-GLANDS/vulva/clitoris/anus/pubic-hair; NXA1 pack round-trips byte-exact; corrupt magic REJECTED (anatomy packs = mod-economy content) T5 STL: the subdivided+displaced mesh exports STL (9684B for 192 tris) -- detail geometry is PRINTABLE too license_tier: ORIGINAL expect_exit: 0

dependencies 4 imports · 0 importers

nx_syscalls.nx nx_mesh3.nx nx_subdiv.nx nx_anatomy.nx nx_detail_gate.nx

imports: nx_syscalls.nxnx_mesh3.nxnx_subdiv.nxnx_anatomy.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap m3_bytes m3_init m3_hdr m3_box m3_add_vert m3_hdr ↻ m3_vert m3_add_tri m3_hdr ↻ m3_tri sd_subdivide m3_init ↻ m3_hdr ↻ m3_tri ↻ m3_vert ↻ sd_getvert m3_hdr ↻ m3_vert ↻ m3_add_vert ↻ m3_add_tri ↻ m3_hdr ↻ hw sys_write pn sys_mmap ↻ sys_write ↻ meshsum m3_hdr ↻ m3_vert ↻ m3_vert ↻ sd_displace sd_normals m3_hdr ↻ m3_tri ↻ m3_vert ↻ sd_isqrt m3_hdr ↻ m3_vert ↻

structs

none

consts

none

functions

15func hw(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 1: main calls 1: sys_write
16func pn(v: i64) -> i64
called by 1: main calls 2: sys_mmapsys_write
28func meshsum(mesh: i64) -> i64
called by 1: main calls 2: m3_hdrm3_vert
42func main() -> i64