vsp1_adjust_color_space(9)
π vsp1_adjust_color_space (9) β the kernel API manual, bestie edition π
okay so real talk, this is a page from the Kernel API Manual and it's about one VERY specific little helper, vsp1_adjust_color_space. she's not famous, she's not doing the most, but she's doing her job and honestly? obsessed. β¨
πΈ NAME πΈ
vsp1_adjust_color_space β literally just adjusting the color space fields in a format. that's it. that's the whole gig. π
π¦ SYNOPSIS π¦
void vsp1_adjust_color_space (u32 code , u32 *colorspace , u8 *xfer_func
, u8 *encoding , u8 *quantization );
likeβ¦ five whole parameters. she's thorough. no cap. π₯
β¨ ARGUMENTS β¨
codeβ the media bus code πcolorspaceβ the colorspace πxfer_funcβ the transfer function π§encodingβ the encoding πquantizationβ the quantization β
(not me listing them all because we do NOT skip the boring parts here, bestie π«Ά)
π DESCRIPTION π
okay so here's the vibe check on what this function actually does: it adjusts all the color space fields of a video device of subdev format structure β and it does that while taking into account three things, in case you were wondering:
- the requested format
- the requested color space
- the limitations of the VSP1
and like, it should be used in the video device and subdev set format handlers. that's where she lives. main character energy only. π
now the tea about what's configurable vs. what's not:
- the
colorspaceandxfer_funcfields are freely configurable, because they are out of scope for VSP processing β so do whatever, bestie, it's not her problem πΈ - the
encodingandquantizationare hardcoded for non-YUV formats π (yeah, sorry, fixed, no takebacks) and can be configured for YUV formats β¨
so basically: YUV formats get options, non-YUV formats get the default treatment. iykyk. π
π₯ SEE ALSO π₯
- Kernel file
./drivers/media/platform/renesas/vsp1/vsp1_pipe.cπ¦ vsp1_get_format_info(9)πvsp1_get_format_info_by_index(9)π
like the whole squad, fr fr. π«Ά
β οΈ quick aside! the page says this function is meant to be used in the video device and subdev set format handlers β so if you're calling it from somewhere random, that's giving "did not read the docs" energy π
okay that's the page!! π one last thing: this lil beauty comes from ./drivers/media/platform/renes... (that's the source string, truncated on the page as-is, don't come for me π) and it's dated October 2026, and the whole page signs off as vsp1_adjust_color_space(9) because of course it does β she's the moment. πβ¨π
π¦ 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