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 |
(...skipping 11 matching lines...) Expand all Loading... |
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; | 29 class AudioFrame; |
30 class RTPFragmentationHeader; | 30 class RTPFragmentationHeader; |
31 class AudioEncoderMutable; | 31 class AudioEncoderMutable; |
| 32 class AudioDecoder; |
32 | 33 |
33 #define WEBRTC_10MS_PCM_AUDIO 960 // 16 bits super wideband 48 kHz | 34 #define WEBRTC_10MS_PCM_AUDIO 960 // 16 bits super wideband 48 kHz |
34 | 35 |
35 // Callback class used for sending data ready to be packetized | 36 // Callback class used for sending data ready to be packetized |
36 class AudioPacketizationCallback { | 37 class AudioPacketizationCallback { |
37 public: | 38 public: |
38 virtual ~AudioPacketizationCallback() {} | 39 virtual ~AudioPacketizationCallback() {} |
39 | 40 |
40 virtual int32_t SendData(FrameType frame_type, | 41 virtual int32_t SendData(FrameType frame_type, |
41 uint8_t payload_type, | 42 uint8_t payload_type, |
(...skipping 527 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
569 // | 570 // |
570 // Input: | 571 // Input: |
571 // -receive_codec : parameters of the codec to be registered, c.f. | 572 // -receive_codec : parameters of the codec to be registered, c.f. |
572 // common_types.h for the definition of | 573 // common_types.h for the definition of |
573 // CodecInst. | 574 // CodecInst. |
574 // | 575 // |
575 // Return value: | 576 // Return value: |
576 // -1 if failed to register the codec | 577 // -1 if failed to register the codec |
577 // 0 if the codec registered successfully. | 578 // 0 if the codec registered successfully. |
578 // | 579 // |
579 virtual int32_t RegisterReceiveCodec( | 580 virtual int RegisterReceiveCodec(const CodecInst& receive_codec) = 0; |
580 const CodecInst& receive_codec) = 0; | 581 |
| 582 virtual int RegisterExternalReceiveCodec(int rtp_payload_type, |
| 583 AudioDecoder* external_decoder, |
| 584 int sample_rate_hz, |
| 585 int num_channels) = 0; |
581 | 586 |
582 /////////////////////////////////////////////////////////////////////////// | 587 /////////////////////////////////////////////////////////////////////////// |
583 // int32_t UnregisterReceiveCodec() | 588 // int32_t UnregisterReceiveCodec() |
584 // Unregister the codec currently registered with a specific payload type | 589 // Unregister the codec currently registered with a specific payload type |
585 // from the list of possible receive codecs. | 590 // from the list of possible receive codecs. |
586 // | 591 // |
587 // Input: | 592 // Input: |
588 // -payload_type : The number representing the payload type to | 593 // -payload_type : The number representing the payload type to |
589 // unregister. | 594 // unregister. |
590 // | 595 // |
(...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1162 virtual std::vector<uint16_t> GetNackList(int round_trip_time_ms) const = 0; | 1167 virtual std::vector<uint16_t> GetNackList(int round_trip_time_ms) const = 0; |
1163 | 1168 |
1164 // Returns the timing statistics for calls to Get10MsAudio. | 1169 // Returns the timing statistics for calls to Get10MsAudio. |
1165 virtual void GetDecodingCallStatistics( | 1170 virtual void GetDecodingCallStatistics( |
1166 AudioDecodingCallStats* call_stats) const = 0; | 1171 AudioDecodingCallStats* call_stats) const = 0; |
1167 }; | 1172 }; |
1168 | 1173 |
1169 } // namespace webrtc | 1174 } // namespace webrtc |
1170 | 1175 |
1171 #endif // WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ | 1176 #endif // WEBRTC_MODULES_AUDIO_CODING_MAIN_INTERFACE_AUDIO_CODING_MODULE_H_ |
OLD | NEW |