2012-01-25 19:21:13 +00:00
|
|
|
# Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
|
2011-07-07 08:21:25 +00:00
|
|
|
#
|
|
|
|
|
# Use of this source code is governed by a BSD-style license
|
|
|
|
|
# that can be found in the LICENSE file in the root of the source
|
|
|
|
|
# tree. An additional intellectual property rights grant can be found
|
|
|
|
|
# in the file PATENTS. All contributing project authors may
|
|
|
|
|
# be found in the AUTHORS file in the root of the source tree.
|
|
|
|
|
|
|
|
|
|
{
|
2013-11-11 17:20:27 +00:00
|
|
|
'variables': {
|
|
|
|
|
'audio_processing_dependencies': [
|
2014-10-10 08:36:56 +00:00
|
|
|
'<(webrtc_root)/base/base.gyp:rtc_base_approved',
|
2013-11-11 17:20:27 +00:00
|
|
|
'<(webrtc_root)/common_audio/common_audio.gyp:common_audio',
|
|
|
|
|
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
|
|
|
|
|
],
|
2014-02-11 04:48:27 +00:00
|
|
|
'shared_generated_dir': '<(SHARED_INTERMEDIATE_DIR)/audio_processing/asm_offsets',
|
2013-11-11 17:20:27 +00:00
|
|
|
},
|
2011-07-07 08:21:25 +00:00
|
|
|
'targets': [
|
|
|
|
|
{
|
|
|
|
|
'target_name': 'audio_processing',
|
2012-09-08 19:27:24 +00:00
|
|
|
'type': 'static_library',
|
|
|
|
|
'variables': {
|
|
|
|
|
# Outputs some low-level debug files.
|
|
|
|
|
'aec_debug_dump%': 0,
|
2014-09-23 11:21:39 +00:00
|
|
|
'agc_debug_dump%': 0,
|
2013-09-25 23:17:38 +00:00
|
|
|
|
|
|
|
|
# Disables the usual mode where we trust the reported system delay
|
|
|
|
|
# values the AEC receives. The corresponding define is set appropriately
|
|
|
|
|
# in the code, but it can be force-enabled here for testing.
|
|
|
|
|
'aec_untrusted_delay_for_testing%': 0,
|
2012-09-08 19:27:24 +00:00
|
|
|
},
|
2011-07-07 08:21:25 +00:00
|
|
|
'dependencies': [
|
2013-11-11 17:20:27 +00:00
|
|
|
'<@(audio_processing_dependencies)',
|
2011-07-07 08:21:25 +00:00
|
|
|
],
|
|
|
|
|
'sources': [
|
2012-09-08 19:27:24 +00:00
|
|
|
'aec/include/echo_cancellation.h',
|
|
|
|
|
'aec/echo_cancellation.c',
|
|
|
|
|
'aec/echo_cancellation_internal.h',
|
|
|
|
|
'aec/aec_core.h',
|
|
|
|
|
'aec/aec_core.c',
|
2013-02-20 22:38:47 +00:00
|
|
|
'aec/aec_core_internal.h',
|
2012-09-08 19:27:24 +00:00
|
|
|
'aec/aec_rdft.h',
|
|
|
|
|
'aec/aec_rdft.c',
|
|
|
|
|
'aec/aec_resampler.h',
|
|
|
|
|
'aec/aec_resampler.c',
|
|
|
|
|
'aecm/include/echo_control_mobile.h',
|
|
|
|
|
'aecm/echo_control_mobile.c',
|
|
|
|
|
'aecm/aecm_core.c',
|
|
|
|
|
'aecm/aecm_core.h',
|
|
|
|
|
'agc/include/gain_control.h',
|
|
|
|
|
'agc/analog_agc.c',
|
|
|
|
|
'agc/analog_agc.h',
|
|
|
|
|
'agc/digital_agc.c',
|
|
|
|
|
'agc/digital_agc.h',
|
2011-07-07 08:21:25 +00:00
|
|
|
'audio_buffer.cc',
|
|
|
|
|
'audio_buffer.h',
|
|
|
|
|
'audio_processing_impl.cc',
|
|
|
|
|
'audio_processing_impl.h',
|
2014-11-26 20:21:38 +00:00
|
|
|
'channel_buffer.cc',
|
|
|
|
|
'channel_buffer.h',
|
2014-04-22 21:00:04 +00:00
|
|
|
'common.h',
|
2011-07-07 08:21:25 +00:00
|
|
|
'echo_cancellation_impl.cc',
|
|
|
|
|
'echo_cancellation_impl.h',
|
|
|
|
|
'echo_control_mobile_impl.cc',
|
|
|
|
|
'echo_control_mobile_impl.h',
|
|
|
|
|
'gain_control_impl.cc',
|
|
|
|
|
'gain_control_impl.h',
|
|
|
|
|
'high_pass_filter_impl.cc',
|
|
|
|
|
'high_pass_filter_impl.h',
|
2012-09-08 19:27:24 +00:00
|
|
|
'include/audio_processing.h',
|
2011-07-07 08:21:25 +00:00
|
|
|
'level_estimator_impl.cc',
|
|
|
|
|
'level_estimator_impl.h',
|
|
|
|
|
'noise_suppression_impl.cc',
|
|
|
|
|
'noise_suppression_impl.h',
|
|
|
|
|
'processing_component.cc',
|
|
|
|
|
'processing_component.h',
|
2014-11-14 22:18:10 +00:00
|
|
|
'splitting_filter.cc',
|
|
|
|
|
'splitting_filter.h',
|
2014-05-05 18:22:21 +00:00
|
|
|
'rms_level.cc',
|
|
|
|
|
'rms_level.h',
|
2014-01-30 09:50:46 +00:00
|
|
|
'typing_detection.cc',
|
|
|
|
|
'typing_detection.h',
|
2012-09-08 19:27:24 +00:00
|
|
|
'utility/delay_estimator.c',
|
|
|
|
|
'utility/delay_estimator.h',
|
|
|
|
|
'utility/delay_estimator_internal.h',
|
|
|
|
|
'utility/delay_estimator_wrapper.c',
|
|
|
|
|
'utility/delay_estimator_wrapper.h',
|
|
|
|
|
'utility/fft4g.c',
|
|
|
|
|
'utility/fft4g.h',
|
|
|
|
|
'utility/ring_buffer.c',
|
|
|
|
|
'utility/ring_buffer.h',
|
2011-07-07 08:21:25 +00:00
|
|
|
'voice_detection_impl.cc',
|
|
|
|
|
'voice_detection_impl.h',
|
2011-08-03 21:08:51 +00:00
|
|
|
],
|
2012-09-08 19:27:24 +00:00
|
|
|
'conditions': [
|
|
|
|
|
['aec_debug_dump==1', {
|
|
|
|
|
'defines': ['WEBRTC_AEC_DEBUG_DUMP',],
|
|
|
|
|
}],
|
2013-09-25 23:17:38 +00:00
|
|
|
['aec_untrusted_delay_for_testing==1', {
|
|
|
|
|
'defines': ['WEBRTC_UNTRUSTED_DELAY',],
|
|
|
|
|
}],
|
2014-09-23 11:21:39 +00:00
|
|
|
['agc_debug_dump==1', {
|
|
|
|
|
'defines': ['WEBRTC_AGC_DEBUG_DUMP',],
|
|
|
|
|
}],
|
2012-09-08 19:27:24 +00:00
|
|
|
['enable_protobuf==1', {
|
|
|
|
|
'dependencies': ['audioproc_debug_proto'],
|
|
|
|
|
'defines': ['WEBRTC_AUDIOPROC_DEBUG_DUMP'],
|
|
|
|
|
}],
|
|
|
|
|
['prefer_fixed_point==1', {
|
|
|
|
|
'defines': ['WEBRTC_NS_FIXED'],
|
|
|
|
|
'sources': [
|
|
|
|
|
'ns/include/noise_suppression_x.h',
|
|
|
|
|
'ns/noise_suppression_x.c',
|
|
|
|
|
'ns/nsx_core.c',
|
|
|
|
|
'ns/nsx_core.h',
|
|
|
|
|
'ns/nsx_defines.h',
|
|
|
|
|
],
|
2014-01-16 07:22:01 +00:00
|
|
|
'conditions': [
|
2014-11-21 16:28:32 +00:00
|
|
|
['target_arch=="mipsel" and mips_arch_variant!="r6" and android_webview_build==0', {
|
2014-01-16 07:22:01 +00:00
|
|
|
'sources': [
|
|
|
|
|
'ns/nsx_core_mips.c',
|
|
|
|
|
],
|
|
|
|
|
}, {
|
|
|
|
|
'sources': [
|
|
|
|
|
'ns/nsx_core_c.c',
|
|
|
|
|
],
|
|
|
|
|
}],
|
|
|
|
|
],
|
2012-09-08 19:27:24 +00:00
|
|
|
}, {
|
|
|
|
|
'defines': ['WEBRTC_NS_FLOAT'],
|
|
|
|
|
'sources': [
|
|
|
|
|
'ns/defines.h',
|
|
|
|
|
'ns/include/noise_suppression.h',
|
|
|
|
|
'ns/noise_suppression.c',
|
|
|
|
|
'ns/ns_core.c',
|
|
|
|
|
'ns/ns_core.h',
|
|
|
|
|
'ns/windows_private.h',
|
|
|
|
|
],
|
|
|
|
|
}],
|
|
|
|
|
['target_arch=="ia32" or target_arch=="x64"', {
|
|
|
|
|
'dependencies': ['audio_processing_sse2',],
|
|
|
|
|
}],
|
2014-11-26 17:01:40 +00:00
|
|
|
['(target_arch=="arm" and arm_version==7) or target_arch=="armv7" or target_arch=="arm64"', {
|
2012-09-08 19:27:24 +00:00
|
|
|
'dependencies': ['audio_processing_neon',],
|
|
|
|
|
}],
|
2014-11-21 16:28:32 +00:00
|
|
|
['target_arch=="mipsel" and mips_arch_variant!="r6" and android_webview_build==0', {
|
2013-11-11 20:10:01 +00:00
|
|
|
'sources': [
|
|
|
|
|
'aecm/aecm_core_mips.c',
|
|
|
|
|
],
|
2014-02-21 00:13:31 +00:00
|
|
|
'conditions': [
|
|
|
|
|
['mips_fpu==1', {
|
|
|
|
|
'sources': [
|
|
|
|
|
'aec/aec_core_mips.c',
|
|
|
|
|
'aec/aec_rdft_mips.c',
|
|
|
|
|
],
|
|
|
|
|
}],
|
|
|
|
|
],
|
2013-11-11 20:10:01 +00:00
|
|
|
}, {
|
|
|
|
|
'sources': [
|
|
|
|
|
'aecm/aecm_core_c.c',
|
|
|
|
|
],
|
|
|
|
|
}],
|
2012-09-08 19:27:24 +00:00
|
|
|
],
|
2013-01-29 06:45:22 +00:00
|
|
|
# TODO(jschuh): Bug 1348: fix size_t to int truncations.
|
|
|
|
|
'msvs_disabled_warnings': [ 4267, ],
|
2011-08-03 21:08:51 +00:00
|
|
|
},
|
2011-12-03 00:03:31 +00:00
|
|
|
],
|
|
|
|
|
'conditions': [
|
|
|
|
|
['enable_protobuf==1', {
|
|
|
|
|
'targets': [
|
|
|
|
|
{
|
|
|
|
|
'target_name': 'audioproc_debug_proto',
|
|
|
|
|
'type': 'static_library',
|
2012-09-08 19:27:24 +00:00
|
|
|
'sources': ['debug.proto',],
|
2011-12-03 00:03:31 +00:00
|
|
|
'variables': {
|
|
|
|
|
'proto_in_dir': '.',
|
|
|
|
|
# Workaround to protect against gyp's pathname relativization when
|
|
|
|
|
# this file is included by modules.gyp.
|
|
|
|
|
'proto_out_protected': 'webrtc/audio_processing',
|
|
|
|
|
'proto_out_dir': '<(proto_out_protected)',
|
|
|
|
|
},
|
2012-09-08 19:27:24 +00:00
|
|
|
'includes': ['../../build/protoc.gypi',],
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
}],
|
|
|
|
|
['target_arch=="ia32" or target_arch=="x64"', {
|
|
|
|
|
'targets': [
|
|
|
|
|
{
|
|
|
|
|
'target_name': 'audio_processing_sse2',
|
|
|
|
|
'type': 'static_library',
|
|
|
|
|
'sources': [
|
|
|
|
|
'aec/aec_core_sse2.c',
|
|
|
|
|
'aec/aec_rdft_sse2.c',
|
|
|
|
|
],
|
|
|
|
|
'cflags': ['-msse2',],
|
|
|
|
|
'xcode_settings': {
|
|
|
|
|
'OTHER_CFLAGS': ['-msse2',],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
}],
|
2014-11-26 17:01:40 +00:00
|
|
|
['(target_arch=="arm" and arm_version==7) or target_arch=="armv7" or target_arch=="arm64"', {
|
2012-11-07 22:34:31 +00:00
|
|
|
'targets': [{
|
|
|
|
|
'target_name': 'audio_processing_neon',
|
|
|
|
|
'type': 'static_library',
|
|
|
|
|
'includes': ['../../build/arm_neon.gypi',],
|
|
|
|
|
'dependencies': [
|
2013-04-30 23:43:26 +00:00
|
|
|
'<(webrtc_root)/common_audio/common_audio.gyp:common_audio',
|
2012-11-07 22:34:31 +00:00
|
|
|
],
|
|
|
|
|
'sources': [
|
2014-06-13 14:50:23 +00:00
|
|
|
'aec/aec_core_neon.c',
|
2014-06-30 12:05:18 +00:00
|
|
|
'aec/aec_rdft_neon.c',
|
2012-11-07 22:34:31 +00:00
|
|
|
'aecm/aecm_core_neon.c',
|
|
|
|
|
'ns/nsx_core_neon.c',
|
|
|
|
|
],
|
|
|
|
|
'conditions': [
|
2014-08-29 17:41:13 +00:00
|
|
|
# Disable LTO in audio_processing_neon target due to compiler bug
|
|
|
|
|
['use_lto==1', {
|
|
|
|
|
'cflags!': [
|
|
|
|
|
'-flto',
|
|
|
|
|
'-ffat-lto-objects',
|
|
|
|
|
],
|
|
|
|
|
}],
|
2012-11-07 22:34:31 +00:00
|
|
|
],
|
|
|
|
|
}],
|
2011-12-03 00:03:31 +00:00
|
|
|
}],
|
2011-07-07 08:21:25 +00:00
|
|
|
],
|
|
|
|
|
}
|