code wiki / _hdl_build / nx_jpeg_rst_gate.nx
nx_jpeg_rst_gate.nx
buildroot/runtime/_hdl_build/nx_jpeg_rst_gate.nx
about
nx_jpeg_rst_gate.nx -- gate for JPEG restart-marker (DRI/RSTn) support, BOTH sides: jw_write_jpeg_ri
EMITS restart intervals and the baseline decoder CONSUMES them (nx_jpeg_decode -> walk_mcus_ri ->
_decoder_consume_rst). A synthetic round-trip alone cannot catch a shared wrong assumption (an encoder
and a decoder that BOTH forgot the DC-predictor reset still round-trip clean), so T7 decodes a REAL
third-party-encoded restart-marker JPEG (knowledge/photoreal_refs/lidia/lidia_nature_02.jpg, ~500 RSTn,
previously DECODE_FAIL rc=102 -- debt 1090) as the independent witness. T6 is the bite tooth: a
corrupted marker must FAIL the decode while the clean stream passes. Inherits nx_gate_verdict.
license_tier: ORIGINAL expect_exit: 0
dependencies 10 imports · 0 importers
imports: nx_syscalls.nxnx_gate_verdict.nxnx_h264_bitwriter.nxnx_dct8.nxnx_quant_table.nxnx_zigzag.nxnx_jpeg_huff_enc.nxnx_jpeg_block_enc.nxnx_jpeg_write.nxnx_jpeg_ascii.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
| 20 | func rj_abs(v: i64) -> i64 { if v<0 { return 0-v } return v } called by 1: main |
| 21 | func rj_u16(b: *u8, o: i64) -> i64 { return ((b[o] as i64)<<8) | (b[o+1] as i64) } called by 1: main |
| 23 | func main() -> i64 |