code wiki / (root) / nx_autorig_mesh.nx

nx_autorig_mesh.nx

buildroot/runtime/nx_autorig_mesh.nx

3877 B79 linesdepth 4pulls 7 transitivereach 2 importersview sourcekind tooltopic autorig
docsdependenciesstructsconstsfunctions

about

nx_autorig_mesh.nx -- ONE-CALL SOVEREIGN AUTO-RIG OF A BARE MESH: skeleton then skin weights in a SINGLE invocation, composing nx_curveskel_lib (cs_run) and nx_boneheat_lib (bh_run). This is the DC16 "arbitrary topology" entry point: "run two tools in order" is not a delivered capability, one call is. Blender's Rigify only assembles a control rig from a meta-rig a human PLACES, and UniRig/RigNet predict with a learned model; this is the classical deterministic route, no checkpoint and no data, bare mesh in and a skinned rigged NXA out. It emits the skeleton and the skinned rig as TWO EXPLICIT artifacts -- no hidden sibling writes -- geodesic weights by default. Its neutrality is provable and its gate proves it: the one-call output is BYTE-IDENTICAL to cs_run then bh_run run separately, so this organ adds an entry point and changes no arithmetic. UNITS/format inherited from the composed libs (NXA v1, 0.01 mm). license_tier: ORIGINAL expect_exit: 0

dependencies 2 imports · 2 importers

nx_syscalls.nx nx_curveskel_lib.nx nx_autorig_mesh.nx nx_autorig_creature_gate.nx nx_autorig_mesh_gate.nx

imports: nx_syscalls.nxnx_curveskel_lib.nx

imported by: nx_autorig_creature_gate.nxnx_autorig_mesh_gate.nx

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

main amw sys_write am_atoi 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 ↻ amesh_run cs_run cs_run_cells sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_munmap sys_close cs_puts sys_write ↻ nxa_find nxa_section_entry nxa_magic nxa_check2 nxa_tag4 bh_conf_cells sys_mmap ↻ sys_read_file ↻

structs

none

consts

13const AM_CELLS_DEFAULT: i64 = 64 // bone-heat grid resolution default; overridable, derived from the asset otherwise
14const AM_EXIT_OK: i64 = 0
15const AM_EXIT_USAGE: i64 = 2
16const AM_EXIT_SKEL: i64 = 3 // the skeleton stage refused (a volumeless sheet, an unreadable mesh)
17const AM_EXIT_SKIN: i64 = 4 // the weight stage refused (no skeleton to weight against)

functions

19func amw(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
20func amn(v: i64) -> i64
called by 1: main calls 2: sys_mmapsys_write
33func am_atoi(s: *u8) -> i64
called by 1: main
45func amesh_run(bare: *u8, skel: *u8, skinned: *u8, cells: i64, crep: *i64, brep: *i64) -> i64
called by 3: mainmainmain calls 2: cs_runbh_run
56func main(argc: i64, argv: *i64) -> i64