| 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_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ | 11 #ifndef WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ |
| 12 #define WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ | 12 #define WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ |
| 13 | 13 |
| 14 #include <vector> | 14 #include <vector> |
| 15 | 15 |
| 16 #include "webrtc/common_types.h" | 16 #include "webrtc/common_types.h" |
| 17 #include "webrtc/modules/audio_coding/main/acm2/acm_codec_database.h" | 17 #include "webrtc/modules/audio_coding/main/acm2/acm_codec_database.h" |
| 18 #include "webrtc/modules/audio_coding/main/interface/audio_coding_module_typedef
s.h" | 18 #include "webrtc/modules/audio_coding/main/interface/audio_coding_module_typedef
s.h" |
| 19 #include "webrtc/modules/audio_coding/neteq/interface/neteq.h" | 19 #include "webrtc/modules/audio_coding/neteq/interface/neteq.h" |
| 20 #include "webrtc/modules/interface/module.h" | 20 #include "webrtc/modules/interface/module.h" |
| 21 #include "webrtc/system_wrappers/interface/clock.h" | 21 #include "webrtc/system_wrappers/interface/clock.h" |
| 22 #include "webrtc/typedefs.h" | 22 #include "webrtc/typedefs.h" |
| 23 | 23 |
| 24 namespace webrtc { | 24 namespace webrtc { |
| 25 | 25 |
| 26 // forward declarations | 26 // forward declarations |
| 27 struct CodecInst; | 27 struct CodecInst; |
| 28 struct WebRtcRTPHeader; | 28 struct WebRtcRTPHeader; |
| 29 class AudioFrame; | |
| 30 class RTPFragmentationHeader; | |
| 31 class AudioEncoderMutable; | 29 class AudioEncoderMutable; |
| 32 class AudioDecoder; | 30 class AudioDecoder; |
| 31 class AudioFrame; |
| 32 class RtcEventLog; |
| 33 class RTPFragmentationHeader; |
| 33 | 34 |
| 34 #define WEBRTC_10MS_PCM_AUDIO 960 // 16 bits super wideband 48 kHz | 35 #define WEBRTC_10MS_PCM_AUDIO 960 // 16 bits super wideband 48 kHz |
| 35 | 36 |
| 36 // Callback class used for sending data ready to be packetized | 37 // Callback class used for sending data ready to be packetized |
| 37 class AudioPacketizationCallback { | 38 class AudioPacketizationCallback { |
| 38 public: | 39 public: |
| 39 virtual ~AudioPacketizationCallback() {} | 40 virtual ~AudioPacketizationCallback() {} |
| 40 | 41 |
| 41 virtual int32_t SendData(FrameType frame_type, | 42 virtual int32_t SendData(FrameType frame_type, |
| 42 uint8_t payload_type, | 43 uint8_t payload_type, |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 | 79 |
| 79 class AudioCodingModule { | 80 class AudioCodingModule { |
| 80 protected: | 81 protected: |
| 81 AudioCodingModule() {} | 82 AudioCodingModule() {} |
| 82 | 83 |
| 83 public: | 84 public: |
| 84 struct Config { | 85 struct Config { |
| 85 Config() | 86 Config() |
| 86 : id(0), | 87 : id(0), |
| 87 neteq_config(), | 88 neteq_config(), |
| 88 clock(Clock::GetRealTimeClock()) {} | 89 clock(Clock::GetRealTimeClock()), |
| 90 event_log(nullptr) {} |
| 89 | 91 |
| 90 int id; | 92 int id; |
| 91 NetEq::Config neteq_config; | 93 NetEq::Config neteq_config; |
| 92 Clock* clock; | 94 Clock* clock; |
| 95 RtcEventLog* event_log; |
| 93 }; | 96 }; |
| 94 | 97 |
| 95 /////////////////////////////////////////////////////////////////////////// | 98 /////////////////////////////////////////////////////////////////////////// |
| 96 // Creation and destruction of a ACM. | 99 // Creation and destruction of a ACM. |
| 97 // | 100 // |
| 98 // The second method is used for testing where a simulated clock can be | 101 // The second method is used for testing where a simulated clock can be |
| 99 // injected into ACM. ACM will take the ownership of the object clock and | 102 // injected into ACM. ACM will take the ownership of the object clock and |
| 100 // delete it when destroyed. | 103 // delete it when destroyed. |
| 101 // | 104 // |
| 102 static AudioCodingModule* Create(int id); | 105 static AudioCodingModule* Create(int id); |
| (...skipping 939 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1042 virtual std::vector<uint16_t> GetNackList(int round_trip_time_ms) const = 0; | 1045 virtual std::vector<uint16_t> GetNackList(int round_trip_time_ms) const = 0; |
| 1043 | 1046 |
| 1044 // Returns the timing statistics for calls to Get10MsAudio. | 1047 // Returns the timing statistics for calls to Get10MsAudio. |
| 1045 virtual void GetDecodingCallStatistics( | 1048 virtual void GetDecodingCallStatistics( |
| 1046 AudioDecodingCallStats* call_stats) const = 0; | 1049 AudioDecodingCallStats* call_stats) const = 0; |
| 1047 }; | 1050 }; |
| 1048 | 1051 |
| 1049 } // namespace webrtc | 1052 } // namespace webrtc |
| 1050 | 1053 |
| 1051 #endif // WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ | 1054 #endif // WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ |
| OLD | NEW |