STRUCT VDEC_H264_SLICE_INST(9)
π NAME π
struct vdec_h264_slice_inst β the h264 decoder instance, bestie. that's the whole vibe β¨
πΈ SYNOPSIS πΈ
okay so this is the struct, and no i did not skip a single field, we're listing everything:
struct vdec_h264_slice_inst {
unsigned int slice_dec_num;
struct mtk_vcodec_dec_ctx *ctx;
struct mtk_vcodec_mem pred_buf;
struct mtk_vcodec_mem mv_buf[H264_MAX_MV_NUM];
struct vdec_vpu_inst vpu;
union {
struct {
struct vdec_h264_slice_vsi *vsi;
struct vdec_h264_slice_vsi *vsi_core;
struct vdec_h264_slice_vsi vsi_ctx;
};
struct {
struct vdec_h264_slice_vsi_ext *vsi_ext;
struct vdec_h264_slice_vsi_ext *vsi_core_ext;
struct vdec_h264_slice_vsi_ext vsi_ctx_ext;
};
};
struct vdec_h264_slice_lat_dec_param h264_slice_param;
unsigned int resolution_changed;
unsigned int realloc_mv_buf;
unsigned int cap_num_planes;
struct v4l2_h264_dpb_entry dpb[16];
bool is_field_bitstream;
int (*decode)(void *h_vdec, struct mtk_vcodec_mem *bs, struct vdec_fb *unused, bool *res_chg);
};
likeβ¦ look at it. she's structured. she's iconic. π
π Members π
okay breaking down every single one, no cap:
slice_dec_numβ the number of frames to be decoded. that's it, that's the count πctxβ points tomtk_vcodec_dec_ctx. your context bestie π«Άpred_bufβ the HW working prediction buffermv_bufβ the HW working motion vector buffervpuβ a VPU instance, slay{unnamed_union}β anonymous. she has no name, she simply is π{unnamed_struct}β anonymous (the first one, the non-ext crowd)vsiβ the vsi used for latvsi_coreβ the vsi used for corevsi_ctxβ the vsi data for this decoding context{unnamed_struct}β anonymous (again β second one, the extended elect β¨)vsi_extβ the extended vsi used for latvsi_core_extβ the extended vsi used for corevsi_ctx_extβ the extended vsi data for this decoding contexth264_slice_paramβ the parameters that the hardware uses to decode. literally the whole instruction manual for the silicon π₯resolution_changedβ resolution changed πrealloc_mv_bufβ reallocate the mv buffercap_num_planesβ number of capture queue planedpbβ the decoded picture buffer, used to store reference buffer informationis_field_bitstreamβ > heads up bestie: field bitstream is not supported, only frame. so if you were thinking about fieldsβ¦ don't πdecodeβ the lat decoder pointer, for different architectures. one pointer, many architectures, main character energy π
π¦ SEE ALSO π¦
- Kernel file
./drivers/media/platform/mediatek/vcodec/decoder/vdec/vdec_h264_req_multi_if.c enum vdec_h264_core_dec_err_type(9)struct vdec_h264_slice_lat_dec_param(9)struct vdec_h264_slice_info(9)struct vdec_h264_slice_vsi(9)struct vdec_h264_slice_share_info(9)struct vdec_h264_slice_fb(9)struct vdec_h264_slice_info_ext(9)struct vdec_h264_slice_vsi_ext(9)
like, read them. iykyk π
and that's the page!! sourced from./drivers/media/platform/media..., dated October 2026, and yes the footer still saysstruct vdec_h264_slice_inst(9)because some things are eternal π
okay bye bestie, go decode something gorgeous πΈπ§β
π¦ 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