STRUCT V4L2_VP9_SEGMENTATION(9)
π NAME π
okay so welcome to the struct v4l2_vp9_segmentation(9) page, straight out of the Kernel API Manual β we're doing the VP9 segmentation parameters today, and honestly? kind of iconic.
short version, for the bestie who just got here: this struct is where all the segmentation info lives. it's giving "the group chat roster for your video frame" fr fr.
β¨ SYNOPSIS β¨
here's the whole vibe laid out π (copy it exact, don't touch the formatting, it's perfect as-is):
struct v4l2_vp9_segmentation {
__s16 feature_data[8][4];
__u8 feature_enabled[8];
__u8 tree_probs[7];
__u8 pred_probs[3];
__u8 flags;
__u8 reserved[5];
};
π«Ά MEMBERS π«Ά
okay bestie, let's meet the whole cast. every single one of them, no skips πΈ
feature_dataβ this is the data attached to each feature. big yikes energy if you forget this: a data entry is only valid if the feature is enabled. the array shall be indexed with the segment number as the first dimension (0..7) and one ofV4L2_VP9_SEG_{}as the second dimension. so like, segment first, feature second. don't flip it, i'm begging πfeature_enabledβ a bitmask defining which features are enabled in each segment β¨ the value for each segment is a combination ofV4L2_VP9_SEGMENT_FEATURE_ENABLED(id)values whereidis one ofV4L2_VP9_SEG_LVL_{}. it's a whole little bitmask situation, she's organized πtree_probsβ specifies the probability values to be used when decoding a Segment-ID π₯ see the5.15. Segmentation mapsection of the VP9 specification for more details. the spec is right there, go read it, i believe in you π«Άpred_probsβ specifies the probability values to be used when decoding a Predicted-Segment-ID π see the6.4.14. Get segment id syntaxsection of :ref:vp9for more details. yes, predicted. it's a different thing. she's mysterious like that.flagsβ combination ofV4L2_VP9_SEGMENTATION_FLAG_{}flags β mix and match, live your truthreservedβ padding field. should be zeroed by applications. like, actually zero it. no cap. this is the "clean your room before guests come over" of struct fields π§Ή
π DESCRIPTION π
okay so what does the whole thing do? it encodes the quantization parameters π
and for the full lore, see section 7.2.10 Segmentation params syntax of the VP9 specification β she's got the details, i'm just the messenger β¨
π₯ SEE ALSO π₯
bestie. sit down. this list is LONG and every single one of them is here, in order, untouched. it's giving "tag yourself i'm struct v4l2_vp9_quantization(9)" π
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_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_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)
okay that's the whole page, you ate it up, no crumbs π go forth and segment responsibly π¦
byeee π«Ά
this has been the struct v4l2_vp9_segmentation(9) page, sourced from ./include/uapi/linux, dated October 2026 β she's a classic, she's timeless, she's literally the whole manual page π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms