STRUCT V4L2_H264_DPB_ENTRY(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ struct v4l2_h264_dpb_entry(9) ✨

okay so bestie, welcome to the Kernel API Manual πŸŽ€ β€” this is the page for struct v4l2_h264_dpb_entry, and honestly? it's giving backstage-pass-to-the-video-decode-green-room. let's get into it πŸ’…


🌸 NAME 🌸

struct v4l2_h264_dpb_entry β€” the H264 decoded picture buffer entry. yes. that's the whole name. she's a struct, she's an entry, she lives in the DPB. iconic behavior fr fr 🫢


πŸ¦‹ SYNOPSIS πŸ¦‹

here's the whole vibe, laid out exactly as-is, no cap:

struct v4l2_h264_dpb_entry {
    __u64 reference_ts;
    __u32 pic_num;
    __u16 frame_num;
    __u8 fields;
    __u8 reserved[5];
    __s32 top_field_order_cnt;
    __s32 bottom_field_order_cnt;
    __u32 flags;
 };

that's her. that's the struct. study her, love her πŸ’–


πŸ‘‘ Members πŸ‘‘

okay this is the main character section, so let's go member by member, no skipping, we don't do that here 🌈

  • reference_ts β€” the timestamp of the V4L2 capture buffer you're using as a reference. literally the "who is she" of your buffer 😌. this timestamp refers to the timestamp field in struct v4l2_buffer. and if you've got a struct timeval sitting around, you use v4l2_timeval_to_ns to convert it into a __u64. that's the glow-up, periodt.
  • pic_num β€” matches the PicNum variable that gets assigned during the reference picture lists construction process. iykyk πŸ”₯
  • frame_num β€” the frame identifier, and it matches the frame_num syntax element. same name, same energy, no notes πŸ’…
  • fields β€” tells you how the DPB entry is referenced. valid values are V4L2_H264_{}_REF. that's the whole list, don't come for me πŸŽ€
  • reserved β€” padding field. and bestie, this one should be zeroed by applications. zero it. don't make it weird πŸ™ˆ
  • top_field_order_cnt β€” matches the TopFieldOrderCnt picture value. top tier, literally ⭐
  • bottom_field_order_cnt β€” matches the BottomFieldOrderCnt picture value. and quick note because it's important: the picture field is indicated by v4l2_buffer.field. so yeah, go check that πŸ‘€
  • flags β€” see V4L2_H264_DPB_ENTRY_FLAG_{}. that's where the flag lore lives 🧚

πŸ’œ SEE ALSO πŸ’œ

the whole friend group, and yes i'm listing every single one because they all deserve their moment ✨

kernel file ./include/uapi/linux/v4l2-controls.h

enum v4l2_mpeg_video_av1_profile(9), enum v4l2_mpeg_video_av1_level(9), enum v4l2_stateless_h264_decode_mode(9), enum v4l2_stateless_h264_start_code(9), struct v4l2_ctrl_h264_sps(9), struct v4l2_ctrl_h264_pps(9), struct v4l2_ctrl_h264_scaling_matrix(9), struct v4l2_ctrl_h264_pred_weights(9), struct v4l2_h264_reference(9), struct v4l2_ctrl_h264_slice_params(9), struct v4l2_ctrl_h264_decode_params(9), struct v4l2_ctrl_fwht_params(9), struct v4l2_vp8_segment(9), struct v4l2_vp8_loop_filter(9), struct v4l2_vp8_quantization(9), struct v4l2_vp8_entropy(9), struct v4l2_vp8_entropy_coder_state(9), struct v4l2_ctrl_vp8_frame(9), struct v4l2_ctrl_mpeg2_sequence(9), struct v4l2_ctrl_mpeg2_picture(9), struct v4l2_ctrl_mpeg2_quantisation(9), struct v4l2_ctrl_hevc_sps(9), struct v4l2_ctrl_hevc_pps(9), struct v4l2_hevc_dpb_entry(9), struct v4l2_hevc_pred_weight_table(9), struct v4l2_ctrl_hevc_slice_params(9), struct v4l2_ctrl_hevc_decode_params(9), struct v4l2_ctrl_hevc_scaling_matrix(9), struct v4l2_vp9_loop_filter(9), struct v4l2_vp9_quantization(9), struct v4l2_vp9_segmentation(9), struct v4l2_ctrl_vp9_frame(9), struct v4l2_vp9_mv_probs(9), struct v4l2_ctrl_vp9_compressed_hdr(9), struct v4l2_ctrl_av1_sequence(9), struct v4l2_ctrl_av1_tile_group_entry(9), enum v4l2_av1_warp_model(9), enum v4l2_av1_reference_frame(9), struct v4l2_av1_global_motion(9), enum v4l2_av1_frame_restoration_type(9), struct v4l2_av1_loop_restoration(9), struct v4l2_av1_cdef(9), enum v4l2_av1_segment_feature(9), struct v4l2_av1_segmentation(9), struct v4l2_av1_loop_filter(9), struct v4l2_av1_quantization(9), struct v4l2_av1_tile_info(9), enum v4l2_av1_frame_type(9), enum v4l2_av1_interpolation_filter(9), enum v4l2_av1_tx_mode(9), struct v4l2_ctrl_av1_frame(9), struct v4l2_ctrl_av1_film_grain(9)


ok that's the whole page!! every field, every flag, every single reference β€” all accounted for, we don't leave the girlies behind πŸ’–

and before you go, the receipts 🧾: this page lives under ./include/uapi/linux, it's from October 2026, and it's filed as struct v4l2_h264_dpb_entry(9). mwah, slay, bye bestie πŸ’…βœ¨πŸŒΈ

πŸ“¦ where this page comes from