code wiki / _hdl_build / nx_stl_view_html.nx

nx_stl_view_html.nx

buildroot/runtime/_hdl_build/nx_stl_view_html.nx

8844 B121 linesdepth 3pulls 3 transitivereach 2 importersview sourcekind librarytopic stl
docsdependenciesstructsconstsfunctions

about

nx_stl_view_html.nx -- "SEE THE CAD OF THE STL" rung (operator: a polyrook.com-class browser view of an STL that can later be edited). SOVEREIGN: the team emits its OWN self-contained HTML + hand-authored WebGL orbit viewer -- NO three.js, nothing injected. Composes nx_fab_slice's struct-free STL readers (fstl_tri_count / fstl_vert_um). Output is a single .html: embedded triangle geometry (mm) as a JS array + a flat-shaded orbit/zoom renderer that auto-fits the model. Editing (sculpt/boolean/repair) = the NEXT rung, backlog. LAWS: struct-free, integer-only in NishiLang (the browser does float math, not us). license_tier: ORIGINAL

dependencies 2 imports · 2 importers

nx_fab_slice.nx nx_syscalls.nx nx_stl_view_html.nx nx_stl_view_demo.nx nx_stl_view_html_test.nx

imports: nx_fab_slice.nxnx_syscalls.nx

imported by: nx_stl_view_demo.nxnx_stl_view_html_test.nx

structs

none

consts

none

functions

13func sv_cat(dst: *u8, off: i64, s: *u8) -> i64
called by 1: nx_stl_view_emit
20func sv_cati(dst: *u8, o: i64, vin: i64) -> i64
called by 2: sv_catmmnx_stl_view_emit calls 1: sys_mmap
33func sv_catmm(dst: *u8, o: i64, vin: i64) -> i64
called by 1: sv_emit_geometry calls 1: sv_cati
48func sv_emit_geometry(stl: *u8, ntri: i64, out: *u8, o: i64) -> i64
70func nx_stl_view_emit(stl: *u8, out: *u8) -> i64