1# Copyright (c) 2020 The WebRTC project authors. All Rights Reserved. 2# 3# Use of this source code is governed by a BSD-style license 4# that can be found in the LICENSE file in the root of the source 5# tree. An additional intellectual property rights grant can be found 6# in the file PATENTS. All contributing project authors may 7# be found in the AUTHORS file in the root of the source tree. 8 9import("../../../webrtc.gni") 10 11rtc_source_set("transient_suppressor_api") { 12 sources = [ "transient_suppressor.h" ] 13} 14 15rtc_library("transient_suppressor_impl") { 16 visibility = [ 17 ":click_annotate", 18 ":transient_suppression_test", 19 ":transient_suppression_unittests", 20 "..:optionally_built_submodule_creators", 21 ] 22 sources = [ 23 "common.h", 24 "daubechies_8_wavelet_coeffs.h", 25 "dyadic_decimator.h", 26 "moving_moments.cc", 27 "moving_moments.h", 28 "transient_detector.cc", 29 "transient_detector.h", 30 "transient_suppressor_impl.cc", 31 "transient_suppressor_impl.h", 32 "windows_private.h", 33 "wpd_node.cc", 34 "wpd_node.h", 35 "wpd_tree.cc", 36 "wpd_tree.h", 37 ] 38 deps = [ 39 ":transient_suppressor_api", 40 ":voice_probability_delay_unit", 41 "../../../common_audio:common_audio", 42 "../../../common_audio:common_audio_c", 43 "../../../common_audio:fir_filter", 44 "../../../common_audio:fir_filter_factory", 45 "../../../common_audio/third_party/ooura:fft_size_256", 46 "../../../rtc_base:checks", 47 "../../../rtc_base:gtest_prod", 48 "../../../rtc_base:logging", 49 ] 50} 51 52rtc_library("voice_probability_delay_unit") { 53 sources = [ 54 "voice_probability_delay_unit.cc", 55 "voice_probability_delay_unit.h", 56 ] 57 deps = [ "../../../rtc_base:checks" ] 58} 59 60if (rtc_include_tests) { 61 if (!build_with_chromium) { 62 rtc_executable("click_annotate") { 63 testonly = true 64 sources = [ 65 "click_annotate.cc", 66 "file_utils.cc", 67 "file_utils.h", 68 ] 69 deps = [ 70 ":transient_suppressor_impl", 71 "..:audio_processing", 72 "../../../rtc_base/system:file_wrapper", 73 "../../../system_wrappers", 74 ] 75 } 76 77 rtc_executable("transient_suppression_test") { 78 testonly = true 79 sources = [ 80 "file_utils.cc", 81 "file_utils.h", 82 "transient_suppression_test.cc", 83 "voice_probability_delay_unit_unittest.cc", 84 ] 85 deps = [ 86 ":transient_suppressor_api", 87 ":transient_suppressor_impl", 88 ":voice_probability_delay_unit", 89 "..:audio_processing", 90 "../../../common_audio", 91 "../../../rtc_base/system:file_wrapper", 92 "../../../system_wrappers", 93 "../../../test:fileutils", 94 "../../../test:test_support", 95 "../agc:level_estimation", 96 "//testing/gtest", 97 "//third_party/abseil-cpp/absl/flags:flag", 98 "//third_party/abseil-cpp/absl/flags:parse", 99 "//third_party/abseil-cpp/absl/types:optional", 100 ] 101 } 102 } 103 104 rtc_library("transient_suppression_unittests") { 105 testonly = true 106 sources = [ 107 "dyadic_decimator_unittest.cc", 108 "file_utils.cc", 109 "file_utils.h", 110 "file_utils_unittest.cc", 111 "moving_moments_unittest.cc", 112 "transient_detector_unittest.cc", 113 "transient_suppressor_unittest.cc", 114 "voice_probability_delay_unit_unittest.cc", 115 "wpd_node_unittest.cc", 116 "wpd_tree_unittest.cc", 117 ] 118 deps = [ 119 ":transient_suppressor_api", 120 ":transient_suppressor_impl", 121 ":voice_probability_delay_unit", 122 "../../../rtc_base:stringutils", 123 "../../../rtc_base/system:file_wrapper", 124 "../../../test:fileutils", 125 "../../../test:test_support", 126 "//testing/gtest", 127 ] 128 absl_deps = [ 129 "//third_party/abseil-cpp/absl/strings", 130 "//third_party/abseil-cpp/absl/types:optional", 131 ] 132 } 133} 134