| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 private: | 262 private: |
| 263 struct Decoder { | 263 struct Decoder { |
| 264 int acm_codec_id; | 264 int acm_codec_id; |
| 265 uint8_t payload_type; | 265 uint8_t payload_type; |
| 266 // This field is meaningful for codecs where both mono and | 266 // This field is meaningful for codecs where both mono and |
| 267 // stereo versions are registered under the same ID. | 267 // stereo versions are registered under the same ID. |
| 268 size_t channels; | 268 size_t channels; |
| 269 int sample_rate_hz; | 269 int sample_rate_hz; |
| 270 }; | 270 }; |
| 271 | 271 |
| 272 const rtc::Optional<CodecInst> RtpHeaderToDecoder( | 272 const rtc::Optional<CodecInst> RtpHeaderToDecoder(const RTPHeader& rtp_header, |
| 273 const RTPHeader& rtp_header, | 273 uint8_t first_payload_byte) |
| 274 uint8_t first_payload_byte) const EXCLUSIVE_LOCKS_REQUIRED(crit_sect_); | 274 const RTC_EXCLUSIVE_LOCKS_REQUIRED(crit_sect_); |
| 275 | 275 |
| 276 uint32_t NowInTimestamp(int decoder_sampling_rate) const; | 276 uint32_t NowInTimestamp(int decoder_sampling_rate) const; |
| 277 | 277 |
| 278 rtc::CriticalSection crit_sect_; | 278 rtc::CriticalSection crit_sect_; |
| 279 rtc::Optional<CodecInst> last_audio_decoder_ GUARDED_BY(crit_sect_); | 279 rtc::Optional<CodecInst> last_audio_decoder_ RTC_GUARDED_BY(crit_sect_); |
| 280 rtc::Optional<SdpAudioFormat> last_audio_format_ GUARDED_BY(crit_sect_); | 280 rtc::Optional<SdpAudioFormat> last_audio_format_ RTC_GUARDED_BY(crit_sect_); |
| 281 ACMResampler resampler_ GUARDED_BY(crit_sect_); | 281 ACMResampler resampler_ RTC_GUARDED_BY(crit_sect_); |
| 282 std::unique_ptr<int16_t[]> last_audio_buffer_ GUARDED_BY(crit_sect_); | 282 std::unique_ptr<int16_t[]> last_audio_buffer_ RTC_GUARDED_BY(crit_sect_); |
| 283 CallStatistics call_stats_ GUARDED_BY(crit_sect_); | 283 CallStatistics call_stats_ RTC_GUARDED_BY(crit_sect_); |
| 284 const std::unique_ptr<NetEq> neteq_; // NetEq is thread-safe; no lock needed. | 284 const std::unique_ptr<NetEq> neteq_; // NetEq is thread-safe; no lock needed. |
| 285 const Clock* const clock_; | 285 const Clock* const clock_; |
| 286 bool resampled_last_output_frame_ GUARDED_BY(crit_sect_); | 286 bool resampled_last_output_frame_ RTC_GUARDED_BY(crit_sect_); |
| 287 rtc::Optional<int> last_packet_sample_rate_hz_ GUARDED_BY(crit_sect_); | 287 rtc::Optional<int> last_packet_sample_rate_hz_ RTC_GUARDED_BY(crit_sect_); |
| 288 }; | 288 }; |
| 289 | 289 |
| 290 } // namespace acm2 | 290 } // namespace acm2 |
| 291 | 291 |
| 292 } // namespace webrtc | 292 } // namespace webrtc |
| 293 | 293 |
| 294 #endif // WEBRTC_MODULES_AUDIO_CODING_ACM2_ACM_RECEIVER_H_ | 294 #endif // WEBRTC_MODULES_AUDIO_CODING_ACM2_ACM_RECEIVER_H_ |
| OLD | NEW |