Let Opus increase complexity for low bitrates
This change adds code that lets Opus increase the complexity setting
at low bitrates (only relevant for mobile where the default complexity
is not already maximum). The feature is default off.
Also adding a performance test to make sure the complexity adaptation
has desired effect.
BUG=webrtc:6708
Review-Url: https://codereview.webrtc.org/2503443002
Cr-Commit-Position: refs/heads/master@{#15182}
diff --git a/webrtc/modules/audio_coding/BUILD.gn b/webrtc/modules/audio_coding/BUILD.gn
index f6188a0..0e78abf 100644
--- a/webrtc/modules/audio_coding/BUILD.gn
+++ b/webrtc/modules/audio_coding/BUILD.gn
@@ -711,10 +711,17 @@
"../../base:rtc_base_approved",
]
+ defines = []
+
if (rtc_build_opus) {
public_deps = [
rtc_opus_dir,
]
+ if (rtc_opus_variable_complexity) {
+ defines += [ "WEBRTC_OPUS_VARIABLE_COMPLEXITY=1" ]
+ } else {
+ defines += [ "WEBRTC_OPUS_VARIABLE_COMPLEXITY=0" ]
+ }
} else if (build_with_mozilla) {
include_dirs = [ getenv("DIST") + "/include/opus" ]
}