STRUCT PIXEL_YUV_U16(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ struct pixel_yuv_u16(9) ✨

okay so bestie, welcome to Kernel API Manual β€” today's main character is a little struct from the kernel world and honestly? she's serving πŸ’…


🌸 NAME 🌸

struct pixel_yuv_u16 β€” the internal representation of a pixel color. that's it, that's her whole job. no cap, she just holds a color on the inside πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

struct pixel_yuv_u16 {
    u16 y, u, v;
 };

look at that. three u16s, chillin' in a struct, living their best lives together 🫢


πŸ’– Members πŸ’–

  • y β€” the luma value, stored in 16 bits, without padding, using machine endianness. she's the brightness baddie of the trio ⭐
  • u β€” the blue difference chroma value, stored in 16 bits, without padding, using machine endianness. blue chroma said "i'm the moment" πŸ’™
  • v β€” the red difference chroma value, stored in 16 bits, without padding, using machine endianness. red chroma, aka the other half of the chroma duo, also iconic πŸ”₯
ngl the "without padding, using machine endianness" part applies to literally all three of them β€” so don't go assuming anything about byte layout beyond that, bestie. fr fr.

🌈 SEE ALSO 🌈

  • Kernel file ./drivers/gpu/drm/vkms/tests/vkms_format_test.c β€” go read the test file, iykyk πŸ‘€

and that's the whole vibe check, bestie πŸ§šπŸ’œ this lil' page came from ./drivers/gpu/drm/vkms/tests, dated October 2026 β€” slay, periodt πŸŽ€βœ¨

πŸ“¦ where this page comes from