OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
213 std::map<int, int> red_payload_types; | 213 std::map<int, int> red_payload_types; |
214 }; | 214 }; |
215 | 215 |
216 // Creates and returns an audio encoder stack constructed to the given | 216 // Creates and returns an audio encoder stack constructed to the given |
217 // specification. If the specification isn't compatible with the encoder, it | 217 // specification. If the specification isn't compatible with the encoder, it |
218 // will be changed to match (things will be switched off). The speech encoder | 218 // will be changed to match (things will be switched off). The speech encoder |
219 // will be stolen. If the specification isn't complete, returns nullptr. | 219 // will be stolen. If the specification isn't complete, returns nullptr. |
220 std::unique_ptr<AudioEncoder> RentEncoderStack(StackParameters* param); | 220 std::unique_ptr<AudioEncoder> RentEncoderStack(StackParameters* param); |
221 | 221 |
222 // Creates and returns an iSAC decoder. | 222 // Creates and returns an iSAC decoder. |
223 std::unique_ptr<AudioDecoder> RentIsacDecoder(); | 223 std::unique_ptr<AudioDecoder> RentIsacDecoder(int sample_rate_hz); |
224 | 224 |
225 private: | 225 private: |
226 std::unique_ptr<AudioEncoder> speech_encoder_; | 226 std::unique_ptr<AudioEncoder> speech_encoder_; |
227 std::unique_ptr<AudioEncoder> cng_encoder_; | 227 std::unique_ptr<AudioEncoder> cng_encoder_; |
228 std::unique_ptr<AudioEncoder> red_encoder_; | 228 std::unique_ptr<AudioEncoder> red_encoder_; |
229 rtc::scoped_refptr<LockedIsacBandwidthInfo> isac_bandwidth_info_; | 229 rtc::scoped_refptr<LockedIsacBandwidthInfo> isac_bandwidth_info_; |
230 | 230 |
231 RTC_DISALLOW_COPY_AND_ASSIGN(RentACodec); | 231 RTC_DISALLOW_COPY_AND_ASSIGN(RentACodec); |
232 }; | 232 }; |
233 | 233 |
234 } // namespace acm2 | 234 } // namespace acm2 |
235 } // namespace webrtc | 235 } // namespace webrtc |
236 | 236 |
237 #endif // WEBRTC_MODULES_AUDIO_CODING_ACM2_RENT_A_CODEC_H_ | 237 #endif // WEBRTC_MODULES_AUDIO_CODING_ACM2_RENT_A_CODEC_H_ |
OLD | NEW |