Skip to content

Commit

Permalink
Disabling openmax_dl
Browse files Browse the repository at this point in the history
Bug: webrtc:9071
Change-Id: I858d78f8121193186828fb75f625d4738d4913eb
Reviewed-on: https://webrtc-review.googlesource.com/69641
Commit-Queue: Alessio Bazzica <[email protected]>
Reviewed-by: Henrik Andreassson <[email protected]>
Reviewed-by: Mirko Bonadei <[email protected]>
Cr-Commit-Position: refs/heads/master@{#23001}
  • Loading branch information
alebzk authored and Commit Bot committed Apr 24, 2018
1 parent f4f0cbb commit 00ec2d9
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 23 deletions.
8 changes: 0 additions & 8 deletions common_audio/real_fourier.cc
Original file line number Diff line number Diff line change
Expand Up @@ -14,22 +14,14 @@
#include "common_audio/signal_processing/include/signal_processing_library.h"
#include "rtc_base/checks.h"

#ifdef RTC_USE_OPENMAX_DL
#include "common_audio/real_fourier_openmax.h"
#endif

namespace webrtc {

using std::complex;

const size_t RealFourier::kFftBufferAlignment = 32;

std::unique_ptr<RealFourier> RealFourier::Create(int fft_order) {
#if defined(RTC_USE_OPENMAX_DL)
return std::unique_ptr<RealFourier>(new RealFourierOpenmax(fft_order));
#else
return std::unique_ptr<RealFourier>(new RealFourierOoura(fft_order));
#endif
}

int RealFourier::FftOrder(size_t length) {
Expand Down
4 changes: 4 additions & 0 deletions common_audio/real_fourier_openmax.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
* be found in the AUTHORS file in the root of the source tree.
*/

// TODO(http://bugs.webrtc.org/9071): Required by downstream projects.
#ifdef RTC_USE_OPENMAX_DL

#include "common_audio/real_fourier_openmax.h"

#include <cstdlib>
Expand Down Expand Up @@ -67,3 +70,4 @@ void RealFourierOpenmax::Inverse(const complex<float>* src, float* dest) const {

} // namespace webrtc

#endif // 0
7 changes: 4 additions & 3 deletions common_audio/real_fourier_openmax.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,8 @@
#ifndef COMMON_AUDIO_REAL_FOURIER_OPENMAX_H_
#define COMMON_AUDIO_REAL_FOURIER_OPENMAX_H_

#ifndef RTC_USE_OPENMAX_DL
#error "Only include this header if RTC_USE_OPENMAX_DL is defined."
#endif
// TODO(http://bugs.webrtc.org/9071): Required by downstream projects.
#ifdef RTC_USE_OPENMAX_DL

#include <complex>

Expand Down Expand Up @@ -44,4 +43,6 @@ class RealFourierOpenmax : public RealFourier {

} // namespace webrtc

#endif // RTC_USE_OPENMAX_DL

#endif // COMMON_AUDIO_REAL_FOURIER_OPENMAX_H_
6 changes: 1 addition & 5 deletions common_audio/real_fourier_unittest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -72,11 +72,7 @@ class RealFourierTest : public ::testing::Test {
const RealFourier::fft_cplx_scoper cplx_buffer_;
};

using FftTypes = ::testing::Types<
#if defined(RTC_USE_OPENMAX_DL)
RealFourierOpenmax,
#endif
RealFourierOoura>;
using FftTypes = ::testing::Types<RealFourierOoura>;
TYPED_TEST_CASE(RealFourierTest, FftTypes);

TYPED_TEST(RealFourierTest, SimpleForwardTransform) {
Expand Down
12 changes: 5 additions & 7 deletions webrtc.gni
Original file line number Diff line number Diff line change
Expand Up @@ -167,11 +167,13 @@ declare_args() {
rtc_build_libsrtp = !build_with_mozilla
rtc_build_libvpx = !build_with_mozilla
rtc_libvpx_build_vp9 = !build_with_mozilla
rtc_build_openmax_dl = !build_with_mozilla
rtc_build_opus = !build_with_mozilla
rtc_build_ssl = !build_with_mozilla
rtc_build_usrsctp = !build_with_mozilla

# TODO(http://bugs.webrtc.org/9071): Remove flag when openmax_dl is deleted.
rtc_build_openmax_dl = false

# Enable libevent task queues on platforms that support it.
# rtc_link_task_queue_impl must be set to true for this to
# have an effect.
Expand All @@ -183,12 +185,8 @@ declare_args() {
rtc_build_libevent = !build_with_mozilla
}

if (!is_ios && (current_cpu != "arm" || arm_version >= 7) &&
current_cpu != "mips64el" && !build_with_mozilla) {
rtc_use_openmax_dl = true
} else {
rtc_use_openmax_dl = false
}
# TODO(http://bugs.webrtc.org/9071): Remove flag when openmax_dl is deleted.
rtc_use_openmax_dl = false

# Build sources requiring GTK. NOTICE: This is not present in Chrome OS
# build environments, even if available for Chromium builds.
Expand Down

0 comments on commit 00ec2d9

Please sign in to comment.