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

Unified Diff: webrtc/api/audio_codecs/BUILD.gn

Issue 2997713002: Reimplement the builtin audio codec factories using the new stuff in api/ (Closed)
Patch Set: . Created 3 years, 4 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/api/audio_codecs/BUILD.gn
diff --git a/webrtc/api/audio_codecs/BUILD.gn b/webrtc/api/audio_codecs/BUILD.gn
index 2174fb1063b0f3a3c89b9a8e4a673de31e7c1f0c..3ed63965b27442e3475adb92ec490f5c115005e6 100644
--- a/webrtc/api/audio_codecs/BUILD.gn
+++ b/webrtc/api/audio_codecs/BUILD.gn
@@ -38,9 +38,46 @@ rtc_static_library("builtin_audio_decoder_factory") {
]
deps = [
":audio_codecs_api",
- "../../modules/audio_coding:builtin_audio_decoder_factory_internal",
"../../rtc_base:rtc_base_approved",
+ "L16:audio_decoder_L16",
+ "g711:audio_decoder_g711",
]
+ defines = []
+ if (rtc_include_ilbc) {
+ deps += [ "ilbc:audio_decoder_ilbc" ]
+ defines += [ "WEBRTC_USE_BUILTIN_ILBC=1" ]
+ } else {
+ defines += [ "WEBRTC_USE_BUILTIN_ILBC=0" ]
+ }
+ if (rtc_include_opus) {
+ deps += [ "opus:audio_decoder_opus" ]
+ defines += [ "WEBRTC_USE_BUILTIN_OPUS=1" ]
+ } else {
+ defines += [ "WEBRTC_USE_BUILTIN_OPUS=0" ]
+ }
+ if (build_with_mozilla) {
+ defines += [
+ "WEBRTC_USE_BUILTIN_G722=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=0",
+ ]
+ } else {
+ if (current_cpu == "arm") {
+ deps += [ "isac:audio_decoder_isac_fix" ]
+ defines += [
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=1",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=0",
+ ]
+ } else {
+ deps += [ "isac:audio_decoder_isac_float" ]
+ defines += [
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=1",
+ ]
+ }
+ deps += [ "g722:audio_decoder_g722" ]
+ defines += [ "WEBRTC_USE_BUILTIN_G722=1" ]
+ }
}
rtc_static_library("builtin_audio_encoder_factory") {
@@ -50,7 +87,44 @@ rtc_static_library("builtin_audio_encoder_factory") {
]
deps = [
":audio_codecs_api",
- "../../modules/audio_coding:builtin_audio_encoder_factory_internal",
"../../rtc_base:rtc_base_approved",
+ "L16:audio_encoder_L16",
+ "g711:audio_encoder_g711",
]
+ defines = []
+ if (rtc_include_ilbc) {
+ deps += [ "ilbc:audio_encoder_ilbc" ]
+ defines += [ "WEBRTC_USE_BUILTIN_ILBC=1" ]
+ } else {
+ defines += [ "WEBRTC_USE_BUILTIN_ILBC=0" ]
+ }
+ if (rtc_include_opus) {
+ deps += [ "opus:audio_encoder_opus" ]
+ defines += [ "WEBRTC_USE_BUILTIN_OPUS=1" ]
+ } else {
+ defines += [ "WEBRTC_USE_BUILTIN_OPUS=0" ]
+ }
+ if (build_with_mozilla) {
+ defines += [
+ "WEBRTC_USE_BUILTIN_G722=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=0",
+ ]
+ } else {
+ if (current_cpu == "arm") {
+ deps += [ "isac:audio_encoder_isac_fix" ]
+ defines += [
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=1",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=0",
+ ]
+ } else {
+ deps += [ "isac:audio_encoder_isac_float" ]
+ defines += [
+ "WEBRTC_USE_BUILTIN_ISAC_FIX=0",
+ "WEBRTC_USE_BUILTIN_ISAC_FLOAT=1",
+ ]
+ }
+ deps += [ "g722:audio_encoder_g722" ]
+ defines += [ "WEBRTC_USE_BUILTIN_G722=1" ]
+ }
}

Powered by Google App Engine
This is Rietveld 408576698