At Mon, 30 Jun 2003 18:49:31 +0200, Denis Sbragion wrote: > > Hello, > > may be unrelated or not. I noticed that in aplay.c (0.9.4), at line 818, > the sample rate setting is obtained with: > > rate = hwparams.rate; > err = snd_pcm_hw_params_set_rate_near(handle, params, &hwparams.rate, 0); > > Is it correct to use a reference (&) to set the sample rate?
yes. the API was changed quite ago. the old API returns the sample rate, while the new API replaces the resultant rate on the given pointer. ATM, as default still the old API is chosen unless you define ALSA_PCM_NEW_HW_PARAMS_API. you shouldn't assume this in future, though. it's recommended to write with the new API. in the reference manual, only the new API is described, btw. Takashi ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01 _______________________________________________ Alsa-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/alsa-devel