code wiki / (root) / nx_contactsheet.nx

nx_contactsheet.nx

buildroot/runtime/nx_contactsheet.nx

6859 B196 linesdepth 11pulls 51 transitivereach 0 importersview sourcekind tool
docsdependenciesstructsconstsfunctions

about

nx_contactsheet.nx -- VISUAL VALIDATION: render a whole gathered corpus as ONE tiled PNG. Numbers prove a pipeline ran; pixels prove it ran CORRECTLY. Every tile here is decoded through OUR decoder (nx_img_to_rgb -> the same path the fingerprinter uses), box-average downscaled and composited. So the sheet is simultaneously (a) a look at the corpus and (b) proof the decode path yields real pixels: a broken decoder produces noise or a hole, not a recognisable thumbnail. usage: nx_contactsheet <dir> <out.png> [tile_px] [cols]

dependencies 5 imports · 0 importers

nx_str.nx nx_syscalls.nx nx_dir.nx nx_img_to_rgb.nx nx_png_write.nx nx_contactsheet.nx

imports: nx_str.nxnx_syscalls.nxnx_dir.nxnx_img_to_rgb.nxnx_png_write.nx

imported by: nobody (leaf or entry point)

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

main cs_atoi sys_mmap nx_dir_list nx_openat nx_dirent_read nx_dirent_iter nx_dir_is_dotlike nx_dir_name_strlen nx_dir_arena_copy_name cs_puts sys_write nx_str_len cs_pi sys_mmap ↻ sys_write ↻ sys_exit nx_dir_row_at nx_dir_row_is_regular_file cs_cat nx_img_to_rgb sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close nx_img_bytes_to_rgb sys_mmap ↻ nx_jpeg_decode_rgb sys_mmap ↻ nx_jpeg_dec_ctx_init sys_mmap ↻ _jpeg_ascii_probe_sof sys_mmap ↻ nx_jpeg_seg_init nx_jpeg_seg_next nx_jpeg_classify_marker nx_jpeg_marker_is_lengthle

structs

none

consts

16const CS_MAXROWS: i64 = 4096
17const CS_ARENA: i64 = 1048576
18const CS_PATH: i64 = 4096
19const CS_PAD: i64 = 4

functions

21func cs_puts(s: *u8) -> i64 { sys_write(1, s, nx_str_len(s)); return 0 }
called by 1: main calls 2: sys_writenx_str_len
23func cs_pi(v: i64) -> i64
called by 1: main calls 2: sys_mmapsys_write
37func cs_cat(dst: *u8, off: i64, s: *u8) -> i64 { var i: i64 = 0; while s[i] != (0 as u8) { dst[off+i] = s[i]; i = i + 1 } return off + i }
called by 1: main
39func cs_atoi(s: *u8) -> i64
called by 1: main
51func cs_draw(sheet: *u8, SW: i64, ox: i64, oy: i64, fw: i64, fh: i64, src: *u8, sw: i64, sh: i64) -> i64
called by 1: main
94func main(argc: i64, argv: *i64) -> i64