1SDL_MixAudio(3) SDL API Reference SDL_MixAudio(3)
2
3
4
6 SDL_MixAudio - Mix audio data
7
9 #include "SDL.h"
10
11 void SDL_MixAudio(Uint8 *dst, Uint8 *src, Uint32 len, int volume);
12
14 This function takes two audio buffers of len bytes each of the playing
15 audio format and mixes them, performing addition, volume adjustment,
16 and overflow clipping. The volume ranges from 0 to SDL_MIX_MAXVOLUME
17 and should be set to the maximum value for full audio volume. Note this
18 does not change hardware volume. This is provided for convenience --
19 you can mix your own audio data.
20
21 Note:
22
23 Do not use this function for mixing together more than two
24 streams of sample data. The output from repeated application of
25 this function may be distorted by clipping, because there is no
26 accumulator with greater range than the input (not to mention
27 this being an inefficient way of doing it). Use mixing functions
28 from SDL_mixer, OpenAL, or write your own mixer instead.
29
31 SDL_OpenAudio
32
33
34
35SDL Tue 11 Sep 2001, 22:58 SDL_MixAudio(3)