Lines Matching defs:hwparams
177 snd_pcm_hw_params_t *hwparams = NULL;
186 if ((err = snd_pcm_hw_params_malloc(&hwparams)) < 0)
192 if ((err = snd_pcm_hw_params_any(pcm, hwparams)) < 0)
198 if ((err = snd_pcm_hw_params_set_access(pcm, hwparams, SND_PCM_ACCESS_RW_INTERLEAVED)) < 0)
206 if ((err = snd_pcm_hw_params_set_format(pcm, hwparams, SND_PCM_FORMAT_S16_LE)) < 0)
214 if ((err = snd_pcm_hw_params_set_format(pcm, hwparams, SND_PCM_FORMAT_S8)) < 0)
222 if ((err = snd_pcm_hw_params_set_rate_resample(pcm, hwparams, 1)) < 0)
230 if ((err = snd_pcm_hw_params_set_rate_near(pcm, hwparams, &rate, 0)) < 0)
237 if ((err = snd_pcm_hw_params_set_channels(pcm, hwparams, pwfx->nChannels)) < 0)
245 if ((err = snd_pcm_hw_params_set_buffer_time_near(pcm, hwparams, &buffertime, 0)) < 0)
251 if ((err = snd_pcm_hw_params(pcm, hwparams)) < 0)
257 snd_pcm_hw_params_free(hwparams);
305 snd_pcm_hw_params_t *hwparams = NULL;
307 if ((err = snd_pcm_hw_params_malloc(&hwparams)) < 0)
313 if ((err = snd_pcm_hw_params_any(pcm_handle, hwparams)) < 0)
318 snd_pcm_hw_params_free(hwparams);