nx_vcodec_stream.nx
buildroot/runtime/nx_vcodec_stream.nx
about
nx_vcodec_stream.nx -- RUNG H8 support: serialize the codec's quantized coefficients to a byte
bitstream and back, so a compressed frame can ride the sovereign QUIC/FEC transport. encode_plane_stream
transforms+quantizes each 4x4 block and writes its 16 coeffs as int16; decode_plane_stream reads them
back and reconstructs. This is the bridge between the codec (H5/H6) and the transport (H7). Pure integer,
sovereign. license_tier: ORIGINAL
dependencies 1 imports · 1 importers
imports: nx_vcodec_color_frame.nx
imported by: nx_vclient_loop_test.nx
structs
| none |
consts
| 7 | const K_MAGIC_32768: i64 = 32768 |
| 8 | const K_MAGIC_65536: i64 = 65536 |
functions
| 10 | func wr16(b: *u8, off: i64, v: i64) -> i64 { b[off]=(v & 0xff) as u8; b[off+1]=((v >> 8) & 0xff) as u8; return 0 } called by 1: encode_plane_stream |
| 11 | func rd16(b: *u8, off: i64) -> i64 { var v: i64=(b[off] as i64) | ((b[off+1] as i64) << 8); if v >= K_MAGIC_32768 { v = v - K_MAGIC_65536 } return v } called by 1: decode_plane_stream |
| 14 | func encode_plane_stream(plane: *u8, W: i64, H: i64, QSTEP: i64, out: *u8) -> i64 |
| 32 | func decode_plane_stream(inb: *u8, W: i64, H: i64, QSTEP: i64, rec: *u8) -> i64 |
| 50 | func main() -> i64 { return 0 } |