Lines Matching refs:format
239 int snd_pcm_format_signed(snd_pcm_format_t format) in snd_pcm_format_signed() argument
242 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_signed()
244 if ((val = pcm_formats[(INT)format].signd) < 0) in snd_pcm_format_signed()
258 int snd_pcm_format_unsigned(snd_pcm_format_t format) in snd_pcm_format_unsigned() argument
262 val = snd_pcm_format_signed(format); in snd_pcm_format_unsigned()
276 int snd_pcm_format_linear(snd_pcm_format_t format) in snd_pcm_format_linear() argument
278 return snd_pcm_format_signed(format) >= 0; in snd_pcm_format_linear()
290 int snd_pcm_format_little_endian(snd_pcm_format_t format) in snd_pcm_format_little_endian() argument
293 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_little_endian()
295 if ((val = pcm_formats[(INT)format].le) < 0) in snd_pcm_format_little_endian()
309 int snd_pcm_format_big_endian(snd_pcm_format_t format) in snd_pcm_format_big_endian() argument
313 val = snd_pcm_format_little_endian(format); in snd_pcm_format_big_endian()
328 int snd_pcm_format_width(snd_pcm_format_t format) in snd_pcm_format_width() argument
331 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_width()
333 if ((val = pcm_formats[(INT)format].width) == 0) in snd_pcm_format_width()
347 int snd_pcm_format_physical_width(snd_pcm_format_t format) in snd_pcm_format_physical_width() argument
350 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_physical_width()
352 if ((val = pcm_formats[(INT)format].phys) == 0) in snd_pcm_format_physical_width()
367 ssize_t snd_pcm_format_size(snd_pcm_format_t format, size_t samples) in snd_pcm_format_size() argument
369 int phys_width = snd_pcm_format_physical_width(format); in snd_pcm_format_size()
383 const unsigned char *snd_pcm_format_silence_64(snd_pcm_format_t format) in snd_pcm_format_silence_64() argument
385 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_silence_64()
387 if (! pcm_formats[(INT)format].phys) in snd_pcm_format_silence_64()
389 return pcm_formats[(INT)format].silence; in snd_pcm_format_silence_64()
404 int snd_pcm_format_set_silence(snd_pcm_format_t format, void *data, unsigned int samples) in snd_pcm_format_set_silence() argument
409 if ((INT)format < 0 || (INT)format > (INT)SNDRV_PCM_FORMAT_LAST) in snd_pcm_format_set_silence()
413 width = pcm_formats[(INT)format].phys; /* physical width */ in snd_pcm_format_set_silence()
414 pat = pcm_formats[(INT)format].silence; in snd_pcm_format_set_silence()
418 if (pcm_formats[(INT)format].signd == 1 || width <= 8) { in snd_pcm_format_set_silence()