[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

5.1 Mix_Chunk

 
typedef struct Mix_Chunk {
    int allocated;
    Uint8 *abuf;
    Uint32 alen;
    Uint8 volume;     /* Per-sample volume, 0-128 */
} Mix_Chunk;

allocated
a boolean indicating whether to free abuf when the chunk is freed.
0 if the memory was not allocated and thus not owned by this chunk.
1 if the memory was allocated and is thus owned by this chunk.
abuf
Pointer to the sample data, which is in the output format and sample rate.
alen
Length of abuf in bytes.
volume
0 = silent, 128 = max volume. This takes effect when mixing.

The internal format for an audio chunk. This stores the sample data, the length in bytes of that data, and the volume to use when mixing the sample.

See Also:
4.2.7 Mix_VolumeChunk, 4.3.16 Mix_GetChunk, 4.2.3 Mix_LoadWAV, 4.2.4 Mix_LoadWAV_RW, 4.2.8 Mix_FreeChunk, 5.2 Mix_Music



This document was generated on November, 13 2009 using texi2html