code wiki / (root) / nx_h264_sps.nx

nx_h264_sps.nx

buildroot/runtime/nx_h264_sps.nx

5197 B112 linesdepth 3pulls 3 transitivereach 16 importersview sourcekind librarytopic h264
docsdependenciesstructsconstsfunctions

about

nx_h264_sps.nx -- H.264 Sequence Parameter Set parser (rung 3). Decodes profile/level/resolution straight from the SPS bitstream using the Exp-Golomb keystone (nx_h264_bits). Field order + dimension formulas verified against the Cardinal Peak worked example (SPS 42 00 0a f8 41 a2 -> 128x96). Width = (pic_width_in_mbs_minus1 + 1) * 16 Height = (pic_height_in_map_units_minus1 + 1) * 16 * (2 - frame_mbs_only_flag) minus frame-crop * cropUnit (4:2:0 default). Also ships RBSP de-emulation (remove 00 00 03 emulation-prevention bytes), required before bit-parsing a real NAL payload. HONEST scope: seq_scaling_matrix lists are NOT parsed (flagged in out[8]); VUI ignored (it is last). Baseline/Main/High (no scaling matrix) parse correctly. genealogy_id: itu_t_h264_sec7_3_2_1_1_sps + cardinalpeak_sps_worked_example lineage_id: exp_golomb_sps_fields + mb_dimension_formula license_tier: ORIGINAL

dependencies 2 imports · 16 importers

nx_syscalls.nx nx_h264_bits.nx nx_h264_sps.nx nx_cam_poster.nx nx_h264_bframe_probe.nx nx_h264_bframe_reflist_gate.nx nx_h264_bframe_walk.nx nx_h264_brecon.nx nx_h264_colmv_gate.nx nx_h264_decode_frame.nx nx_h264_mv_recon_gate.nx nx_h264_pframe_probe.nx nx_h264_pframe_recon.nx

diagram shows first 10 each side; +0 more imports, +6 more importers in the complete lists below.

imports: nx_syscalls.nxnx_h264_bits.nx

imported by: nx_cam_poster.nxnx_h264_bframe_probe.nxnx_h264_bframe_reflist_gate.nxnx_h264_bframe_walk.nxnx_h264_brecon.nxnx_h264_colmv_gate.nxnx_h264_decode_frame.nxnx_h264_mv_recon_gate.nxnx_h264_pframe_probe.nxnx_h264_pframe_recon.nxnx_h264_pframe_walk.nxnx_h264_slice_extract.nxnx_h264_sps_gate.nxnx_h264_ts_probe.nxnx_mp4_real_probe.nxnx_ts_lumadiff.nx

structs

none

consts

none

functions

23func nx_h264_unescape_rbsp(src: *u8, len: i64, dst: *u8) -> i64
called by 16: mainmainmainmainmainmain+10
35func nx_h264_is_high(p: i64) -> i64
52func nx_h264_parse_sps(rbsp: *u8, len: i64, out: *i64) -> i64