00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef _AFLIBAUDIOMIXER_H_
00024 #define _AFLIBAUDIOMIXER_H_
00025
00026 #ifdef HAVE_CONFIG_H
00027 #include <config.h>
00028 #endif
00029
00030 #include "aflibAudio.h"
00031 #include "aflibMixerItem.h"
00032 #include <set>
00033 using std::set;
00034
00057 class aflibAudioMixer : public aflibAudio {
00058
00059 public:
00060
00061
00062 aflibAudioMixer(
00063 aflibAudio& audio);
00064
00065 aflibAudioMixer();
00066
00067 ~aflibAudioMixer();
00068
00069 aflibStatus
00070 addMix(
00071 int input,
00072 int in_chan,
00073 int out_chan,
00074 int amp);
00075
00076 aflibStatus
00077 delMix(
00078 int input,
00079 int in_chan,
00080 int out_chan);
00081
00082 void
00083 delAllMix();
00084
00085 int
00086 getNumOfMixs();
00087
00088 aflibStatus
00089 getMix(
00090 int mix_num,
00091 int& input,
00092 int& in_chan,
00093 int& out_chan,
00094 int& amp);
00095
00096 void
00097 setInputConfig(const aflibConfig& cfg);
00098
00099 aflibStatus
00100 compute_segment(
00101 list<aflibData *>& data,
00102 long long position = -1) ;
00103
00105 const char *
00106 getName() const { return "aflibAudioMixer";};
00107
00108 bool
00109 isDataSizeSupported(aflib_data_size size);
00110
00111 bool
00112 isEndianSupported(aflib_data_endian end);
00113
00114 bool
00115 isSampleRateSupported(int& rate);
00116
00117
00118 private:
00119
00120 aflibAudioMixer(const aflibAudioMixer& op);
00121
00122 const aflibAudioMixer&
00123 operator=(const aflibAudioMixer& op);
00124
00125 void
00126 parentWasDestroyed(int parent_id);
00127
00128
00129 set < aflibMixerItem, less<aflibMixerItem> > _mix_item;
00130
00131 };
00132
00133 #endif