Unified · Split
| @@ -1,3 +1,8 @@ | ||
| 1 | +2008-01-21 Erik de Castro Lopo <erikd AT mega-nerd DOT com> | |
| 2 | + | |
| 3 | + * examples/audio_out.c | |
| 4 | + Apply patch from Yair K. to fix compiles with OSS v4. | |
| 5 | + | |
| 1 | 6 | 2007-07-07 Erik de Castro Lopo <erikd AT mega-nerd DOT com> |
| 2 | 7 | |
| 3 | 8 | * acinclude.m4 |
| @@ -91,17 +91,17 @@ linux_open (int channels, int samplerate) · 90 unmodified lines | ||
| 91 | 91 | } ; |
| 92 | 92 | |
| 93 | 93 | fmt = CPU_IS_BIG_ENDIAN ? AFMT_S16_BE : AFMT_S16_LE ; |
| 94 | − if (ioctl (linux_out->fd, SOUND_PCM_SETFMT, &fmt) != 0) | |
| 94 | + if (ioctl (linux_out->fd, SNDCTL_DSP_SETFMT, &fmt) != 0) | |
| 95 | 95 | { perror ("linux_open_dsp_device : set format ") ; |
| 96 | 96 | exit (1) ; |
| 97 | 97 | } ; |
| 98 | 98 | |
| 99 | − if ((error = ioctl (linux_out->fd, SOUND_PCM_WRITE_CHANNELS, &channels)) != 0) | |
| 99 | + if ((error = ioctl (linux_out->fd, SNDCTL_DSP_CHANNELS, &channels)) != 0) | |
| 100 | 100 | { perror ("linux_open : channels ") ; |
| 101 | 101 | exit (1) ; |
| 102 | 102 | } ; |
| 103 | 103 | |
| 104 | − if ((error = ioctl (linux_out->fd, SOUND_PCM_WRITE_RATE, &samplerate)) != 0) | |
| 104 | + if ((error = ioctl (linux_out->fd, SNDCTL_DSP_SPEED, &samplerate)) != 0) | |
| 105 | 105 | { perror ("linux_open : sample rate ") ; |
| 106 | 106 | exit (1) ; |
| 107 | 107 | } ; |