OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2014 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 #include "webrtc/api/audio_codecs/audio_encoder.h" | 11 #include "webrtc/api/audio_codecs/audio_encoder.h" |
12 | 12 |
13 #include "webrtc/rtc_base/checks.h" | 13 #include "webrtc/rtc_base/checks.h" |
14 #include "webrtc/rtc_base/trace_event.h" | 14 #include "webrtc/rtc_base/trace_event.h" |
15 | 15 |
16 namespace webrtc { | 16 namespace webrtc { |
17 | 17 |
18 AudioEncoder::EncodedInfo::EncodedInfo() = default; | 18 AudioEncoder::EncodedInfo::EncodedInfo() = default; |
19 AudioEncoder::EncodedInfo::EncodedInfo(const EncodedInfo&) = default; | 19 AudioEncoder::EncodedInfo::EncodedInfo(const EncodedInfo&) = default; |
20 AudioEncoder::EncodedInfo::EncodedInfo(EncodedInfo&&) = default; | 20 AudioEncoder::EncodedInfo::EncodedInfo(EncodedInfo&&) = default; |
21 AudioEncoder::EncodedInfo::~EncodedInfo() = default; | 21 AudioEncoder::EncodedInfo::~EncodedInfo() = default; |
22 AudioEncoder::EncodedInfo& AudioEncoder::EncodedInfo::operator=( | 22 AudioEncoder::EncodedInfo& AudioEncoder::EncodedInfo::operator=( |
23 const EncodedInfo&) = default; | 23 const EncodedInfo&) = default; |
24 AudioEncoder::EncodedInfo& AudioEncoder::EncodedInfo::operator=(EncodedInfo&&) = | 24 AudioEncoder::EncodedInfo& AudioEncoder::EncodedInfo::operator=(EncodedInfo&&) = |
25 default; | 25 default; |
26 | 26 |
| 27 AudioEncoder::AudioEncoderStats::AudioEncoderStats() = default; |
| 28 AudioEncoder::AudioEncoderStats::~AudioEncoderStats() = default; |
| 29 AudioEncoder::AudioEncoderStats::AudioEncoderStats(const AudioEncoderStats&) = |
| 30 default; |
| 31 |
27 int AudioEncoder::RtpTimestampRateHz() const { | 32 int AudioEncoder::RtpTimestampRateHz() const { |
28 return SampleRateHz(); | 33 return SampleRateHz(); |
29 } | 34 } |
30 | 35 |
31 AudioEncoder::EncodedInfo AudioEncoder::Encode( | 36 AudioEncoder::EncodedInfo AudioEncoder::Encode( |
32 uint32_t rtp_timestamp, | 37 uint32_t rtp_timestamp, |
33 rtc::ArrayView<const int16_t> audio, | 38 rtc::ArrayView<const int16_t> audio, |
34 rtc::Buffer* encoded) { | 39 rtc::Buffer* encoded) { |
35 TRACE_EVENT0("webrtc", "AudioEncoder::Encode"); | 40 TRACE_EVENT0("webrtc", "AudioEncoder::Encode"); |
36 RTC_CHECK_EQ(audio.size(), | 41 RTC_CHECK_EQ(audio.size(), |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 int target_audio_bitrate_bps, | 93 int target_audio_bitrate_bps, |
89 rtc::Optional<int64_t> bwe_period_ms) {} | 94 rtc::Optional<int64_t> bwe_period_ms) {} |
90 | 95 |
91 void AudioEncoder::OnReceivedRtt(int rtt_ms) {} | 96 void AudioEncoder::OnReceivedRtt(int rtt_ms) {} |
92 | 97 |
93 void AudioEncoder::OnReceivedOverhead(size_t overhead_bytes_per_packet) {} | 98 void AudioEncoder::OnReceivedOverhead(size_t overhead_bytes_per_packet) {} |
94 | 99 |
95 void AudioEncoder::SetReceiverFrameLengthRange(int min_frame_length_ms, | 100 void AudioEncoder::SetReceiverFrameLengthRange(int min_frame_length_ms, |
96 int max_frame_length_ms) {} | 101 int max_frame_length_ms) {} |
97 | 102 |
| 103 AudioEncoder::AudioEncoderStats AudioEncoder::GetStats() const { |
| 104 return AudioEncoder::AudioEncoderStats(); |
| 105 } |
| 106 |
98 } // namespace webrtc | 107 } // namespace webrtc |
OLD | NEW |