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 17 matching lines...) Expand all Loading... |
28 // codec->Release(); | 28 // codec->Release(); |
29 // VoiceEngine::Delete(voe); | 29 // VoiceEngine::Delete(voe); |
30 // | 30 // |
31 #ifndef WEBRTC_VOICE_ENGINE_VOE_CODEC_H | 31 #ifndef WEBRTC_VOICE_ENGINE_VOE_CODEC_H |
32 #define WEBRTC_VOICE_ENGINE_VOE_CODEC_H | 32 #define WEBRTC_VOICE_ENGINE_VOE_CODEC_H |
33 | 33 |
34 #include "webrtc/common_types.h" | 34 #include "webrtc/common_types.h" |
35 | 35 |
36 namespace webrtc { | 36 namespace webrtc { |
37 | 37 |
| 38 class RtcEventLog; |
38 class VoiceEngine; | 39 class VoiceEngine; |
39 | 40 |
40 class WEBRTC_DLLEXPORT VoECodec { | 41 class WEBRTC_DLLEXPORT VoECodec { |
41 public: | 42 public: |
42 // Factory for the VoECodec sub-API. Increases an internal | 43 // Factory for the VoECodec sub-API. Increases an internal |
43 // reference counter if successful. Returns NULL if the API is not | 44 // reference counter if successful. Returns NULL if the API is not |
44 // supported or if construction fails. | 45 // supported or if construction fails. |
45 static VoECodec* GetInterface(VoiceEngine* voiceEngine); | 46 static VoECodec* GetInterface(VoiceEngine* voiceEngine); |
46 | 47 |
47 // Releases the VoECodec sub-API and decreases an internal | 48 // Releases the VoECodec sub-API and decreases an internal |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 // TODO(minyue): Make SetOpusMaxPlaybackRate() pure virtual when | 125 // TODO(minyue): Make SetOpusMaxPlaybackRate() pure virtual when |
125 // fakewebrtcvoiceengine in talk is ready. | 126 // fakewebrtcvoiceengine in talk is ready. |
126 virtual int SetOpusMaxPlaybackRate(int channel, int frequency_hz) { | 127 virtual int SetOpusMaxPlaybackRate(int channel, int frequency_hz) { |
127 return -1; | 128 return -1; |
128 } | 129 } |
129 | 130 |
130 // If send codec is Opus on a specified |channel|, set its DTX. Returns 0 if | 131 // If send codec is Opus on a specified |channel|, set its DTX. Returns 0 if |
131 // success, and -1 if failed. | 132 // success, and -1 if failed. |
132 virtual int SetOpusDtx(int channel, bool enable_dtx) = 0; | 133 virtual int SetOpusDtx(int channel, bool enable_dtx) = 0; |
133 | 134 |
| 135 // Get a pointer to the event logging object associated with this Voice |
| 136 // Engine. |
| 137 virtual RtcEventLog* GetEventLog() = 0; |
| 138 |
134 protected: | 139 protected: |
135 VoECodec() {} | 140 VoECodec() {} |
136 virtual ~VoECodec() {} | 141 virtual ~VoECodec() {} |
137 }; | 142 }; |
138 | 143 |
139 } // namespace webrtc | 144 } // namespace webrtc |
140 | 145 |
141 #endif // WEBRTC_VOICE_ENGINE_VOE_CODEC_H | 146 #endif // WEBRTC_VOICE_ENGINE_VOE_CODEC_H |
OLD | NEW |