STRUCT V4L2_CTRL_H264_PPS(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct v4l2_ctrl_h264_pps(9)

okay bestie, so this is a page straight out of the Kernel API Manual and it's all about struct v4l2_ctrl_h264_pps β€” literally the H264 picture parameter set and nothing else. it's giving ✨codec internals✨ and honestly? kinda iconic.


🌸 NAME 🌸

struct v4l2_ctrl_h264_pps β€” the H264 picture parameter set, no cap πŸ’–


πŸŽ€ SYNOPSIS πŸŽ€

struct v4l2_ctrl_h264_pps {
    __u8 pic_parameter_set_id;
    __u8 seq_parameter_set_id;
    __u8 num_slice_groups_minus1;
    __u8 num_ref_idx_l0_default_active_minus1;
    __u8 num_ref_idx_l1_default_active_minus1;
    __u8 weighted_bipred_idc;
    __s8 pic_init_qp_minus26;
    __s8 pic_init_qs_minus26;
    __s8 chroma_qp_index_offset;
    __s8 second_chroma_qp_index_offset;
    __u16 flags;
 };

look at her. eleven members. main character energy fr fr 🫢


πŸ¦‹ Members πŸ¦‹

  • pic_parameter_set_id β€” see H264 specification. πŸ‘€
  • seq_parameter_set_id β€” see H264 specification. πŸ‘€
  • num_slice_groups_minus1 β€” see H264 specification. πŸ‘€
  • num_ref_idx_l0_default_active_minus1 β€” see H264 specification. πŸ‘€
  • num_ref_idx_l1_default_active_minus1 β€” see H264 specification. πŸ‘€
  • weighted_bipred_idc β€” see H264 specification. πŸ‘€
  • pic_init_qp_minus26 β€” see H264 specification. πŸ‘€
  • pic_init_qs_minus26 β€” see H264 specification. πŸ‘€
  • chroma_qp_index_offset β€” see H264 specification. πŸ‘€
  • second_chroma_qp_index_offset β€” see H264 specification. πŸ‘€
  • flags β€” see V4L2_H264_PPS_FLAG_{}. 🚩
like… yes, every single one says "see H264 specification" 😭 that's the whole vibe of this struct, bestie. the spec is the source of truth and we respect her.

✨ Description ✨

okay so here's the tea πŸ“ β€” except where noted, all the members on this picture parameter set structure match the picture parameter set syntax as specified by the H264 specification. literally all of them. slay.

in particular (and this is the part you actually need to remember, iykyk), the V4L2_H264_PPS_FLAG_SCALING_MATRIX_PRESENT flag has a specific meaning. this flag should be set if a non-flat scaling matrix applies to the picture. πŸ“βœ¨

and when that happens? applications are expected to use V4L2_CID_STATELESS_H264_SCALING_MATRIX to pass the values of the non-flat matrices. like, that's the whole assignment. don't skip it πŸ™ˆ


πŸ‘‘ SEE ALSO πŸ‘‘

so many friends in the group chat, let's go πŸŽ‰ first up, from the 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_scaling_matrix(9)
  • struct v4l2_ctrl_h264_pred_weights(9)
  • struct v4l2_h264_reference(9)
  • struct v4l2_ctrl_h264_slice_params(9)
  • struct v4l2_h264_dpb_entry(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)

that's the whole squad, ate and left no crumbs πŸ”₯


and that's the page, bestie πŸ§šπŸ’œ this came from ./include/uapi/linux, dated October 2026, and it's filed under struct v4l2_ctrl_h264_pps(9). go forth and set your flags correctly, periodt. πŸ’…πŸŒˆ

πŸ“¦ where this page comes from