snd_pcm_format_width(9)
π snd_pcm_format_width(9) β from the Kernel API Manual β¨
okay so bestie, listen β this is snd_pcm_format_width, a little function from the Kernel API Manual that does exactly one iconic thing: it tells you how wide a PCM format is in bits. that's it. that's the whole vibe. π
π¦ NAME π¦
snd_pcm_format_width β return the bit-width of the format. literally just that, no cap π
β¨ SYNOPSIS β¨
int snd_pcm_format_width (snd_pcm_format_t format );
yep, that's the whole signature, she's cute and she's short π«Ά
πΈ ARGUMENTS πΈ
formatβ the format you want to check π that's the one and only argument, bestie, just hand over the format and let her do her thing.
β RETURN β
she gives you back the bit-width of the format β slay π β or, if the format is unknown, a negative error code. so like, if you get a negative number back, that's your sign the format wasn't a real one π no guessing, check it fr fr.
π₯ SEE ALSO π₯
- Kernel file
./sound/core/pcm_misc.c snd_pcm_format_signed(9)snd_pcm_format_unsigned(9)snd_pcm_format_linear(9)snd_pcm_format_little_endian(9)snd_pcm_format_big_endian(9)snd_pcm_format_physical_width(9)snd_pcm_format_size(9)snd_pcm_format_silence_64(9)snd_pcm_format_set_silence(9)snd_pcm_hw_limit_rates(9)snd_pcm_rate_to_rate_bit(9)snd_pcm_rate_bit_to_rate(9)snd_pcm_rate_mask_intersect(9)
the whole friend group, honestly π go read them all, iykyk π
and that's the page!! π this lil beauty lives in ./sound/core, dated October 2026, and it goes by snd_pcm_format_width(9) β mwah, periodt πβ¨
π¦ 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