Reland "Isolating APM API build target: making :api an actual target."
This reverts commit 61c6e5643e7ea058e653956980a90e033249c055.
Reason for revert: downstream projects prepared for this change
Original change's description:
> Revert "Isolating APM API build target: making :api an actual target."
>
> This reverts commit a7f77a7c05b5d26520fd01a773ffb2c8b15b60ff.
>
> Reason for revert: breaking downstream
>
> Original change's description:
> > Isolating APM API build target: making :api an actual target.
> >
> > This CL is part of a refactoring work to unblock other CLs
> > that would generate a circular dependency when including
> > modules/audio_processing. It will also allow to easily move
> > the APM interface part under //api.
> >
> > More in detail, this change moves the APM interface files from
> > the build target modules/audio_processing to
> > modules/audio_processing:api. It also adds :api as dependency
> > where needed.
> >
> > Bug: webrtc:9535
> > Change-Id: I72829e22d08ba4d75985f0421e6e8bf0216ebecd
> > Reviewed-on: https://webrtc-review.googlesource.com/c/109501
> > Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> > Reviewed-by: Kári Helgason <kthelgason@webrtc.org>
> > Reviewed-by: Niels Moller <nisse@webrtc.org>
> > Reviewed-by: Sam Zackrisson <saza@webrtc.org>
> > Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
> > Cr-Commit-Position: refs/heads/master@{#25539}
>
> TBR=saza@webrtc.org,alessiob@webrtc.org,kwiberg@webrtc.org,nisse@webrtc.org,kthelgason@webrtc.org
>
> Change-Id: I974c6237311e7c06970aa62e5f6940f3aa80113d
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: webrtc:9535
> Reviewed-on: https://webrtc-review.googlesource.com/c/109820
> Reviewed-by: Alessio Bazzica <alessiob@webrtc.org>
> Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25540}
TBR=saza@webrtc.org,alessiob@webrtc.org,kwiberg@webrtc.org,nisse@webrtc.org,kthelgason@webrtc.org
Change-Id: Ic8ed4cc3baf43d639ce13cae256c007728c3ad92
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:9535
Reviewed-on: https://webrtc-review.googlesource.com/c/109884
Reviewed-by: Alessio Bazzica <alessiob@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25547}
diff --git a/api/BUILD.gn b/api/BUILD.gn
index 4aa42d4..e3cff31 100644
--- a/api/BUILD.gn
+++ b/api/BUILD.gn
@@ -354,6 +354,7 @@
]
deps = [
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/audio_processing:audioproc_f_impl",
]
diff --git a/audio/BUILD.gn b/audio/BUILD.gn
index 078d6ab..4b2ec61 100644
--- a/audio/BUILD.gn
+++ b/audio/BUILD.gn
@@ -72,6 +72,7 @@
"../modules/audio_coding:audio_network_adaptor_config",
"../modules/audio_device",
"../modules/audio_processing",
+ "../modules/audio_processing:api",
"../modules/bitrate_controller:bitrate_controller",
"../modules/pacing:pacing",
"../modules/remote_bitrate_estimator:remote_bitrate_estimator",
diff --git a/call/BUILD.gn b/call/BUILD.gn
index db82884..c49fc88 100644
--- a/call/BUILD.gn
+++ b/call/BUILD.gn
@@ -38,6 +38,7 @@
"../api/audio_codecs:audio_codecs_api",
"../api/transport:network_control",
"../modules/audio_device:audio_device",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/audio_processing:audio_processing_statistics",
"../rtc_base:audio_format_to_string",
diff --git a/examples/BUILD.gn b/examples/BUILD.gn
index d136e96..cc6db5d 100644
--- a/examples/BUILD.gn
+++ b/examples/BUILD.gn
@@ -505,6 +505,7 @@
"../api/audio_codecs:builtin_audio_encoder_factory",
"../logging:rtc_event_log_impl_base",
"../media:rtc_audio_video",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../pc:libjingle_peerconnection",
"../rtc_base:rtc_base",
@@ -722,6 +723,7 @@
"../api/video_codecs:builtin_video_encoder_factory",
"../media:rtc_audio_video",
"../modules/audio_device:audio_device",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/video_capture:video_capture_module",
"../pc:libjingle_peerconnection",
@@ -845,6 +847,7 @@
"../media:rtc_media",
"../media:rtc_media_base",
"../modules/audio_device:audio_device",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/video_capture:video_capture_module",
"../pc:libjingle_peerconnection",
diff --git a/examples/androidnativeapi/BUILD.gn b/examples/androidnativeapi/BUILD.gn
index 5568eb1..dc27d75 100644
--- a/examples/androidnativeapi/BUILD.gn
+++ b/examples/androidnativeapi/BUILD.gn
@@ -53,6 +53,7 @@
"//media:rtc_audio_video",
"//media:rtc_internal_video_codecs",
"//modules/audio_processing",
+ "//modules/audio_processing:api",
"//modules/utility:utility",
"//pc:libjingle_peerconnection",
"//rtc_base:rtc_base",
diff --git a/media/BUILD.gn b/media/BUILD.gn
index 8eaa23c..85121d2 100644
--- a/media/BUILD.gn
+++ b/media/BUILD.gn
@@ -278,6 +278,7 @@
defines = []
libs = []
deps = [
+ "../modules/audio_processing:api",
"../modules/audio_processing/aec_dump:aec_dump",
"../modules/video_coding:video_codec_interface",
"../modules/video_coding:video_coding",
@@ -446,6 +447,7 @@
"../call:video_stream_api",
"../common_video:common_video",
"../modules/audio_coding:rent_a_codec",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/rtp_rtcp:rtp_rtcp_format",
"../modules/video_coding:video_codec_interface",
@@ -541,6 +543,7 @@
"../api/test/video:function_video_factory",
"../api/units:time_delta",
"../api/video:video_frame_i420",
+ "../modules/audio_processing:api",
"../modules/audio_processing:mocks",
"../modules/rtp_rtcp",
"../modules/video_coding:video_codec_interface",
diff --git a/modules/audio_mixer/BUILD.gn b/modules/audio_mixer/BUILD.gn
index 0bb3ae1..fb8bfa6 100644
--- a/modules/audio_mixer/BUILD.gn
+++ b/modules/audio_mixer/BUILD.gn
@@ -48,6 +48,7 @@
"../../system_wrappers",
"../../system_wrappers:metrics",
"../audio_processing",
+ "../audio_processing:api",
"../audio_processing:apm_logging",
"../audio_processing:audio_frame_view",
"../audio_processing/agc2:fixed_digital",
diff --git a/modules/audio_processing/BUILD.gn b/modules/audio_processing/BUILD.gn
index 53744b8..a244c84 100644
--- a/modules/audio_processing/BUILD.gn
+++ b/modules/audio_processing/BUILD.gn
@@ -38,13 +38,27 @@
]
}
-# Temporary dummy target for the APM interface.
rtc_source_set("api") {
visibility = [ "*" ]
-
- # TODO(bugs.webrtc.org/9535): Adapt downstream projects and populate.
- sources = []
- deps = []
+ sources = [
+ "include/audio_processing.cc",
+ "include/audio_processing.h",
+ ]
+ deps = [
+ ":audio_frame_view",
+ ":audio_generator_interface",
+ ":audio_processing_statistics",
+ ":config",
+ ":gain_control_interface",
+ "../../api/audio:aec3_config",
+ "../../api/audio:echo_control",
+ "../../rtc_base:deprecation",
+ "../../rtc_base:macromagic",
+ "../../rtc_base:ptr_util",
+ "../../rtc_base:rtc_base_approved",
+ "../../rtc_base/system:rtc_export",
+ "//third_party/abseil-cpp/absl/types:optional",
+ ]
}
rtc_static_library("audio_processing") {
@@ -76,11 +90,6 @@
"gain_controller2.h",
"include/aec_dump.cc",
"include/aec_dump.h",
-
- # TODO(bugs.webrtc.org/9535): Adapt downstream projects and remove
- # include/audio_processing.cc/h.
- "include/audio_processing.cc",
- "include/audio_processing.h",
"level_estimator_impl.cc",
"level_estimator_impl.h",
"low_cut_filter.cc",
@@ -333,6 +342,7 @@
"include/mock_audio_processing.h",
]
deps = [
+ ":api",
":audio_processing",
":audio_processing_statistics",
"../../test:test_support",
@@ -511,6 +521,7 @@
]
deps = [
+ ":api",
":audio_generator_factory",
":audio_processing",
":file_audio_generator",
@@ -555,6 +566,7 @@
deps = [
":analog_mic_simulation",
+ ":api",
":apm_logging",
":audio_processing",
":audioproc_debug_proto",
@@ -585,6 +597,7 @@
"test/audioproc_float_main.cc",
]
deps = [
+ ":api",
":audio_processing",
"../../api:audioproc_f_api",
"../../rtc_base:rtc_base_approved",
@@ -610,6 +623,7 @@
]
deps = [
+ ":api",
":audio_processing",
"../../api:array_view",
"../../api/audio:audio_frame_api",
@@ -694,6 +708,7 @@
]
deps = [
+ ":api",
":audio_processing",
":audioproc_debug_proto",
":audioproc_protobuf_utils",
diff --git a/modules/audio_processing/aec_dump/BUILD.gn b/modules/audio_processing/aec_dump/BUILD.gn
index 5b55526..d4262ca 100644
--- a/modules/audio_processing/aec_dump/BUILD.gn
+++ b/modules/audio_processing/aec_dump/BUILD.gn
@@ -43,6 +43,7 @@
deps = [
":mock_aec_dump",
+ "..:api",
"../",
"../../../rtc_base:rtc_base_approved",
"//testing/gtest",
diff --git a/pc/BUILD.gn b/pc/BUILD.gn
index 7663f8b..2001fbb 100644
--- a/pc/BUILD.gn
+++ b/pc/BUILD.gn
@@ -258,6 +258,7 @@
"../media:rtc_audio_video",
"../media:rtc_media_base",
"../modules/audio_device:audio_device",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../rtc_base:rtc_base",
"../rtc_base:rtc_base_approved",
@@ -424,6 +425,7 @@
"../media:rtc_media_base",
"../media:rtc_media_tests_utils",
"../modules/audio_device:audio_device",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../p2p:p2p_test_utils",
"../rtc_base:checks",
@@ -539,6 +541,7 @@
"../media:rtc_data", # TODO(phoglund): AFAIK only used for one sctp constant.
"../media:rtc_media_base",
"../media:rtc_media_tests_utils",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/utility:utility",
"../p2p:p2p_test_utils",
diff --git a/sdk/BUILD.gn b/sdk/BUILD.gn
index 98de1a3..31a7901 100644
--- a/sdk/BUILD.gn
+++ b/sdk/BUILD.gn
@@ -919,6 +919,7 @@
"../media:rtc_media_base",
"../modules:module_api",
"../modules/audio_device:audio_device_api",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/video_coding:video_codec_interface",
"../pc:create_pc_factory",
@@ -1188,6 +1189,7 @@
"../media:rtc_media_base",
"../modules:module_api",
"../modules/audio_device:audio_device_api",
+ "../modules/audio_processing:api",
"../modules/audio_processing:audio_processing",
"../modules/video_coding:video_codec_interface",
"../rtc_base:rtc_base_tests_utils",
diff --git a/sdk/android/BUILD.gn b/sdk/android/BUILD.gn
index fff8dc3..d5df5ad 100644
--- a/sdk/android/BUILD.gn
+++ b/sdk/android/BUILD.gn
@@ -561,6 +561,7 @@
":builtin_audio_codecs_jni",
"../../api/audio_codecs:builtin_audio_decoder_factory",
"../../api/audio_codecs:builtin_audio_encoder_factory",
+ "../../modules/audio_processing:api",
"../../modules/audio_processing:audio_processing",
"../../rtc_base:rtc_base_approved",
]
@@ -1011,6 +1012,7 @@
"../../logging:rtc_event_log_api",
"../../media:rtc_audio_video",
"../../modules/audio_device:audio_device",
+ "../../modules/audio_processing:api",
"../../modules/audio_processing:audio_processing",
]
}
@@ -1491,6 +1493,7 @@
"../../media:rtc_media_base",
"../../modules/audio_device:audio_device",
"../../modules/audio_device:mock_audio_device",
+ "../../modules/audio_processing:api",
"../../modules/audio_processing:audio_processing",
"../../modules/utility:utility",
"../../pc:libjingle_peerconnection",
diff --git a/test/fuzzers/BUILD.gn b/test/fuzzers/BUILD.gn
index ae26420..1909c8a 100644
--- a/test/fuzzers/BUILD.gn
+++ b/test/fuzzers/BUILD.gn
@@ -469,6 +469,7 @@
":fuzz_data_helper",
"../../api/audio:audio_frame_api",
"../../modules/audio_processing",
+ "../../modules/audio_processing:api",
"../../rtc_base:checks",
"../../rtc_base:rtc_base_approved",
"//third_party/abseil-cpp/absl/types:optional",
@@ -483,6 +484,7 @@
":audio_processing_fuzzer_helper",
"../../api/audio:aec3_factory",
"../../modules/audio_processing",
+ "../../modules/audio_processing:api",
"../../modules/audio_processing/aec3",
"../../modules/audio_processing/aec_dump",
"../../modules/audio_processing/aec_dump:aec_dump_impl",
@@ -503,6 +505,7 @@
deps = [
":fuzz_data_helper",
"../../modules/audio_processing",
+ "../../modules/audio_processing:api",
"../../rtc_base:rtc_base_approved",
"../../rtc_base:safe_minmax",
"//third_party/abseil-cpp/absl/memory",