code wiki / _hdl_build / nx_intra_block_gate.nx
nx_intra_block_gate.nx
buildroot/runtime/_hdl_build/nx_intra_block_gate.nx
about
nx_intra_block_gate.nx -- SOVEREIGN proof of the PATENT-FREE intra keyframe pipeline, end-to-end on
an 8x8 block: pixels -> level-shift -> 2D DCT-II (nx_dct8, foundational expired math: Ahmed-Natarajan-
Rao 1974 / Chen 1977 / Loeffler 1989) -> scalar quantize -> 16-bit serialize -> rANS entropy code
(nx_rans, Duda PUBLIC-DOMAIN) -> [decode] -> dequantize -> inverse 2D DCT -> reconstruct. Every tool
is EXPIRED or PUBLIC-DOMAIN -> reads on no active claim (deep-research verified 2026-06-20). No CABAC,
no patented transform. The entropy stage is proven LOSSLESS (carries the quantized coefficients
bit-exact); the only loss is scalar quantization (measured + reported). All sovereign, no python, no
gcc, integer arithmetic (no f64). GREEN iff 7/7. Durable knowledge/status/intra_block_gate.log.
license_tier: ORIGINAL
dependencies 4 imports · 0 importers
imports: nx_syscalls.nxnx_gate_emit_lib.nxnx_dct8.nxnx_rans.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
| none |
functions
| 15 | func g_num(v: i64) -> i64 { let bb: *u8=sys_mmap(28); var m: i64=v; if m<0{m=0-m;sys_write(1,"-" as *u8,1)}; let t: *u8=sys_mmap(28); var k: i64=0; if m==0{t[0]=(48 as u8);k=1}; while m>0{t[k]=((48+(m%10)) as u8);m=m/10;k=k+1}; var i: i64=0; while i<k{bb[i]=t[k-1-i];i=i+1}; sys_write(1,bb,k); return 0 } |
| 16 | func g_w(fd: i64, s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(fd,s,n); return 0 } |
| 17 | func g_wn(fd: i64, v: i64) -> i64 { let bb: *u8=sys_mmap(28); var m: i64=v; let t: *u8=sys_mmap(28); var k: i64=0; if m==0{t[0]=(48 as u8);k=1}; while m>0{t[k]=((48+(m%10)) as u8);m=m/10;k=k+1}; var i: i64=0; while i<k{bb[i]=t[k-1-i];i=i+1}; sys_write(fd,bb,k); return 0 } |
| 18 | func iabs(v: i64) -> i64 { if v<0 { return 0-v } return v } called by 1: run_pipeline |
| 19 | func qround(v: i64, q: i64) -> i64 { if v>=0 { return (v + q/2)/q } return 0 - (((0-v) + q/2)/q) } called by 1: run_pipeline |
| 22 | func ser16(qc: *i64, out: *u8) -> i64 called by 1: run_pipeline |
| 28 | func deser16(bytes: *u8, qc: *i64) -> i64 called by 1: run_pipeline |
| 36 | func run_pipeline(block: *i64, DM: *i64, scratch: *i64, ti: *i64, to: *i64, Q: i64, sb: i64, results: *i64) -> i64 |
| 94 | func main() -> i64 |