code wiki / _hdl_build / nx_vcodec_bframe_ceiling.nx
nx_vcodec_bframe_ceiling.nx
buildroot/runtime/_hdl_build/nx_vcodec_bframe_ceiling.nx
about
nx_vcodec_bframe_ceiling.nx -- measure the B-FRAME ceiling, decoder-transparent. B-frames (bidirectional prediction)
are x264's single biggest lever and the residual decomposition points here: our P-frames are ~5-9x behind x264 while
intra is only 2.6x, and sub-pel (6-tap re-audit) is dead -> the gap is STRUCTURAL prediction. A B-frame predicts each
block as the AVERAGE of a best-match in a PAST ref and a best-match in a FUTURE ref: averaging cancels noise, and (the
big win) reveal/occlusion regions that one direction cannot predict are covered by the other. This probe, on the aptly
named bframe_test, integer-searches each interior 16x16 block against both the previous AND next CLEAN frame, and
compares the residual of uni-directional (past-only, what our codec does today) vs bi-directional (past+future avg).
A large bi<uni cut = B-frames are THE lever and the (pervasive, VOD-only) enc+dec+reorder build is justified; a small
cut = look elsewhere (multi-ref, partitions). Pure measurement on clean originals => no bitstream, no parity risk. license_tier: ORIGINAL
dependencies 2 imports · 0 importers
imports: nx_syscalls.nxnx_vmotion.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
| 12 | const K_MAGIC_2026: i64 = 2026 |
| 14 | const NW: i64 = 576 |
| 15 | const NH: i64 = 1024 |
functions
| 17 | func gw(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 } |
| 18 | func gn(v: i64) -> i64 |
| 24 | func bi_sad(cur: *u8, past: *u8, fut: *u8, W: i64, cx: i64, cy: i64, called by 1: main |
| 43 | func main() -> i64 |