| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| 11 #ifndef WEBRTC_VOICE_ENGINE_OUTPUT_MIXER_H_ | 11 #ifndef WEBRTC_VOICE_ENGINE_OUTPUT_MIXER_H_ |
| 12 #define WEBRTC_VOICE_ENGINE_OUTPUT_MIXER_H_ | 12 #define WEBRTC_VOICE_ENGINE_OUTPUT_MIXER_H_ |
| 13 | 13 |
| 14 #include "webrtc/base/criticalsection.h" |
| 14 #include "webrtc/common_audio/resampler/include/push_resampler.h" | 15 #include "webrtc/common_audio/resampler/include/push_resampler.h" |
| 15 #include "webrtc/common_types.h" | 16 #include "webrtc/common_types.h" |
| 16 #include "webrtc/modules/audio_conference_mixer/include/audio_conference_mixer.h
" | 17 #include "webrtc/modules/audio_conference_mixer/include/audio_conference_mixer.h
" |
| 17 #include "webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_d
efines.h" | 18 #include "webrtc/modules/audio_conference_mixer/include/audio_conference_mixer_d
efines.h" |
| 18 #include "webrtc/modules/utility/include/file_recorder.h" | 19 #include "webrtc/modules/utility/include/file_recorder.h" |
| 19 #include "webrtc/voice_engine/dtmf_inband.h" | 20 #include "webrtc/voice_engine/dtmf_inband.h" |
| 20 #include "webrtc/voice_engine/level_indicator.h" | 21 #include "webrtc/voice_engine/level_indicator.h" |
| 21 #include "webrtc/voice_engine/voice_engine_defines.h" | 22 #include "webrtc/voice_engine/voice_engine_defines.h" |
| 22 | 23 |
| 23 namespace webrtc { | 24 namespace webrtc { |
| 24 | 25 |
| 25 class AudioProcessing; | 26 class AudioProcessing; |
| 26 class CriticalSectionWrapper; | |
| 27 class FileWrapper; | 27 class FileWrapper; |
| 28 class VoEMediaProcess; | 28 class VoEMediaProcess; |
| 29 | 29 |
| 30 namespace voe { | 30 namespace voe { |
| 31 | 31 |
| 32 class Statistics; | 32 class Statistics; |
| 33 | 33 |
| 34 class OutputMixer : public AudioMixerOutputReceiver, | 34 class OutputMixer : public AudioMixerOutputReceiver, |
| 35 public FileCallback | 35 public FileCallback |
| 36 { | 36 { |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 101 void RecordFileEnded(int32_t id); | 101 void RecordFileEnded(int32_t id); |
| 102 | 102 |
| 103 private: | 103 private: |
| 104 OutputMixer(uint32_t instanceId); | 104 OutputMixer(uint32_t instanceId); |
| 105 int InsertInbandDtmfTone(); | 105 int InsertInbandDtmfTone(); |
| 106 | 106 |
| 107 // uses | 107 // uses |
| 108 Statistics* _engineStatisticsPtr; | 108 Statistics* _engineStatisticsPtr; |
| 109 AudioProcessing* _audioProcessingModulePtr; | 109 AudioProcessing* _audioProcessingModulePtr; |
| 110 | 110 |
| 111 // owns | 111 rtc::CriticalSection _callbackCritSect; |
| 112 CriticalSectionWrapper& _callbackCritSect; | |
| 113 // protect the _outputFileRecorderPtr and _outputFileRecording | 112 // protect the _outputFileRecorderPtr and _outputFileRecording |
| 114 CriticalSectionWrapper& _fileCritSect; | 113 rtc::CriticalSection _fileCritSect; |
| 115 AudioConferenceMixer& _mixerModule; | 114 AudioConferenceMixer& _mixerModule; |
| 116 AudioFrame _audioFrame; | 115 AudioFrame _audioFrame; |
| 117 // Converts mixed audio to the audio device output rate. | 116 // Converts mixed audio to the audio device output rate. |
| 118 PushResampler<int16_t> resampler_; | 117 PushResampler<int16_t> resampler_; |
| 119 // Converts mixed audio to the audio processing rate. | 118 // Converts mixed audio to the audio processing rate. |
| 120 PushResampler<int16_t> audioproc_resampler_; | 119 PushResampler<int16_t> audioproc_resampler_; |
| 121 AudioLevel _audioLevel; // measures audio level for the combined signal | 120 AudioLevel _audioLevel; // measures audio level for the combined signal |
| 122 DtmfInband _dtmfGenerator; | 121 DtmfInband _dtmfGenerator; |
| 123 int _instanceId; | 122 int _instanceId; |
| 124 VoEMediaProcess* _externalMediaCallbackPtr; | 123 VoEMediaProcess* _externalMediaCallbackPtr; |
| 125 bool _externalMedia; | 124 bool _externalMedia; |
| 126 float _panLeft; | 125 float _panLeft; |
| 127 float _panRight; | 126 float _panRight; |
| 128 int _mixingFrequencyHz; | 127 int _mixingFrequencyHz; |
| 129 FileRecorder* _outputFileRecorderPtr; | 128 FileRecorder* _outputFileRecorderPtr; |
| 130 bool _outputFileRecording; | 129 bool _outputFileRecording; |
| 131 }; | 130 }; |
| 132 | 131 |
| 133 } // namespace voe | 132 } // namespace voe |
| 134 | 133 |
| 135 } // namespace werbtc | 134 } // namespace werbtc |
| 136 | 135 |
| 137 #endif // VOICE_ENGINE_OUTPUT_MIXER_H_ | 136 #endif // VOICE_ENGINE_OUTPUT_MIXER_H_ |
| OLD | NEW |