**** This patch should be removed when updating to esound >0.2.32 **** **** patch by Łukasz Mach **** released under the GPL license **** **** updates to the new alsa pcm api used since 0.9.0_rc4 **** (http://bugzilla.gnome.org/show_bug.cgi?id=129709) --- ../esound-0.2.32.orig/audio_alsa09.c Thu Mar 20 09:34:19 2003 +++ ./audio_alsa09.c Sat Dec 20 03:01:11 2003 @@ -136,15 +136,17 @@ alsaerr = -1; return handle; } - - err = snd_pcm_hw_params_set_rate_near(handle, hwparams, speed, 0); + + int t_dir=0; + int t_speed=speed; + err = snd_pcm_hw_params_set_rate_near(handle, hwparams, &t_speed, &t_dir); if (err < 0) { if (alsadbg) fprintf(stderr, "%s\n", snd_strerror(err)); alsaerr = -1; return handle; } - if (err != speed) { + if (t_speed != speed) { if (alsadbg) fprintf(stderr, "Rate not avaliable %i != %i\n", speed, err); alsaerr = -1; @@ -176,8 +178,9 @@ alsaerr = -1; return handle; } - - err = snd_pcm_hw_params_set_buffer_size_near(handle, hwparams, BUFFERSIZE); + + snd_pcm_uframes_t t_bufsize=BUFFERSIZE; + err = snd_pcm_hw_params_set_buffer_size_near(handle, hwparams, &t_bufsize); if (err < 0) { if (alsadbg) fprintf(stderr, "Buffersize:%s\n", snd_strerror(err));