Added build flag around the Intelligibility enhancer performance test code
BUG=chromium:641931 Review-Url: https://codereview.webrtc.org/2294093004 Cr-Commit-Position: refs/heads/master@{#14202}
This commit is contained in:
@ -776,6 +776,13 @@ if (rtc_include_tests) {
|
||||
"//testing/gmock",
|
||||
"//testing/gtest",
|
||||
]
|
||||
|
||||
if (rtc_enable_intelligibility_enhancer) {
|
||||
defines = [ "WEBRTC_INTELLIGIBILITY_ENHANCER=1" ]
|
||||
} else {
|
||||
defines = [ "WEBRTC_INTELLIGIBILITY_ENHANCER=0" ]
|
||||
}
|
||||
|
||||
if (is_android) {
|
||||
deps += [ "//testing/android/native_test:native_test_native_code" ]
|
||||
data = webrtc_perf_tests_resources
|
||||
|
||||
@ -29,6 +29,14 @@
|
||||
#include "webrtc/system_wrappers/include/sleep.h"
|
||||
#include "webrtc/test/testsupport/perf_test.h"
|
||||
|
||||
// Check to verify that the define for the intelligibility enhancer is properly
|
||||
// set.
|
||||
#if !defined(WEBRTC_INTELLIGIBILITY_ENHANCER) || \
|
||||
(WEBRTC_INTELLIGIBILITY_ENHANCER != 0 && \
|
||||
WEBRTC_INTELLIGIBILITY_ENHANCER != 1)
|
||||
#error "Set WEBRTC_INTELLIGIBILITY_ENHANCER to either 0 or 1"
|
||||
#endif
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
namespace {
|
||||
@ -96,6 +104,7 @@ struct SimulationConfig {
|
||||
}
|
||||
}
|
||||
|
||||
#if WEBRTC_INTELLIGIBILITY_ENHANCER == 1
|
||||
const SettingsType intelligibility_enhancer_settings[] = {
|
||||
SettingsType::kDefaultApmDesktopAndIntelligibilityEnhancer};
|
||||
|
||||
@ -107,6 +116,7 @@ struct SimulationConfig {
|
||||
simulation_configs.push_back(SimulationConfig(sample_rate, settings));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
const SettingsType beamformer_settings[] = {
|
||||
SettingsType::kDefaultApmDesktopAndBeamformer};
|
||||
|
||||
@ -454,6 +454,12 @@
|
||||
'webrtc',
|
||||
],
|
||||
'conditions': [
|
||||
['enable_intelligibility_enhancer==1', {
|
||||
'defines': ['WEBRTC_INTELLIGIBILITY_ENHANCER=1',],
|
||||
}, {
|
||||
'defines': ['WEBRTC_INTELLIGIBILITY_ENHANCER=0',],
|
||||
}],
|
||||
|
||||
['OS=="android"', {
|
||||
'dependencies': [
|
||||
'<(DEPTH)/testing/android/native_test.gyp:native_test_native_code',
|
||||
|
||||
Reference in New Issue
Block a user