Re: Changing the sample rate/channels of an already opened PCM stream

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Clemens,

* Clemens Ladisch <cladisch@xxxxxxxxxxxx> wrote:
> Ed Schouten wrote:
> > I have been trying to get the device to reset so I can change the sample
> > rate, but for some reason, it just gets ignored. Can someone explain me
> > how it's possible to reset the sample rate after preparing the handle?
> 
> The various snd_pcm_hw_params_set_xxx() functions choose some value for
> a parameter that has not yet been set, but they do not change a
> parameter once it has been set.  To reset all parameters in a hw_params
> container, call snd_pcm_hw_params_any() again.

Calling snd_pcm_hw_params_any() before changing the sample rate did the
trick. Thanks a lot! :-)

Yours,
-- 
 Ed Schouten <ed@xxxxxx>
 WWW: http://g-rave.nl/

Attachment: pgpScP2vrFP8o.pgp
Description: PGP signature

_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux