mixer.h
changeset 1496 3d0b86f5dcb8
parent 337 66647f97e7c0
child 1498 cbe7edba0316
equal deleted inserted replaced
1495:c8a61d136f26 1496:3d0b86f5dcb8
       
     1 #ifndef MIXER_H
       
     2 #define MIXER_H
       
     3 
       
     4 typedef struct Mixer Mixer;
       
     5 typedef struct MixerChannel MixerChannel;
       
     6 
       
     7 enum {
       
     8 	MX_AUTOFREE = 1,
       
     9 //	MX_8BIT = 2,
       
    10 //	MX_STEREO = 4,
       
    11 //	MX_UNSIGNED = 8,
       
    12 };
       
    13 
       
    14 VARDEF Mixer *_mixer;
       
    15 
       
    16 bool MxInitialize(uint rate);
       
    17 void MxMixSamples(Mixer *mx, void *buffer, uint samples);
       
    18 
       
    19 MixerChannel *MxAllocateChannel(Mixer *mx);
       
    20 void MxSetChannelRawSrc(MixerChannel *mc, int8 *mem, uint size, uint rate, uint flags);
       
    21 void MxSetChannelVolume(MixerChannel *mc, uint left, uint right);
       
    22 void MxActivate(MixerChannel*);
       
    23 
       
    24 #endif