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

Unified Diff: webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h

Issue 2429503002: Simplifying audio network adaptor by moving receiver frame length range to ctor. (Closed)
Patch Set: nicer solution Created 4 years, 2 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/opus/audio_encoder_opus.h
diff --git a/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h b/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h
index 342668e78002976165d3d453256cc321680fb606..81ca17f7e08bf14d4577de9332f49f9871eb0cf5 100644
--- a/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h
+++ b/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.h
@@ -49,6 +49,7 @@ class AudioEncoderOpus final : public AudioEncoder {
int max_playback_rate_hz = 48000;
int complexity = kDefaultComplexity;
bool dtx_enabled = false;
+ std::vector<int> supported_frame_lengths_ms;
const Clock* clock = nullptr;
private:
@@ -102,6 +103,9 @@ class AudioEncoderOpus final : public AudioEncoder {
void OnReceivedRtt(int rtt_ms) override;
void SetReceiverFrameLengthRange(int min_frame_length_ms,
int max_frame_length_ms) override;
+ rtc::ArrayView<const int> supported_frame_lengths_ms() const {
+ return config_.supported_frame_lengths_ms;
+ }
// Getters for testing.
double packet_loss_rate() const { return packet_loss_rate_; }

Powered by Google App Engine
This is Rietveld 408576698