Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(484)

Unified Diff: webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc

Issue 2024633002: AudioDecoder: New method SampleRateHz, + implementations for our codecs (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc
diff --git a/webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc b/webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc
index 9757b4a0100674095353e9e20e43f986a1b3aba8..0f85215b4d01e459c1ff69248b74565a2acab066 100644
--- a/webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc
+++ b/webrtc/modules/audio_coding/codecs/g711/audio_decoder_pcm.cc
@@ -16,6 +16,10 @@ namespace webrtc {
void AudioDecoderPcmU::Reset() {}
+int AudioDecoderPcmU::SampleRateHz() const {
+ return sample_rate_hz_;
+}
+
size_t AudioDecoderPcmU::Channels() const {
return num_channels_;
}
@@ -40,6 +44,10 @@ int AudioDecoderPcmU::PacketDuration(const uint8_t* encoded,
void AudioDecoderPcmA::Reset() {}
+int AudioDecoderPcmA::SampleRateHz() const {
+ return sample_rate_hz_;
+}
+
size_t AudioDecoderPcmA::Channels() const {
return num_channels_;
}

Powered by Google App Engine
This is Rietveld 408576698