blob: 6d411edda176c4e61badabdf9c379c6227091ceb [file] [log] [blame]
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +00001# Copyright (c) 2014 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
jackychen8f9902a2015-11-26 02:59:48 -08009import("//build/config/arm.gni")
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000010import("../../build/webrtc.gni")
11
kjellander@webrtc.org72273912015-02-23 19:08:31 +000012build_video_processing_sse2 = current_cpu == "x86" || current_cpu == "x64"
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000013
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000014source_set("video_processing") {
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000015 sources = [
Henrik Kjellander0f59a882015-11-18 22:31:24 +010016 "brightness_detection.cc",
17 "brightness_detection.h",
18 "content_analysis.cc",
19 "content_analysis.h",
20 "deflickering.cc",
21 "deflickering.h",
22 "frame_preprocessor.cc",
23 "frame_preprocessor.h",
24 "include/video_processing.h",
25 "include/video_processing_defines.h",
26 "spatial_resampler.cc",
27 "spatial_resampler.h",
jackychen8f9902a2015-11-26 02:59:48 -080028 "util/denoiser_filter.cc",
29 "util/denoiser_filter.h",
30 "util/denoiser_filter_c.cc",
31 "util/denoiser_filter_c.h",
32 "util/skin_detection.cc",
33 "util/skin_detection.h",
Henrik Kjellander0f59a882015-11-18 22:31:24 +010034 "video_decimator.cc",
35 "video_decimator.h",
jackychen8f9902a2015-11-26 02:59:48 -080036 "video_denoiser.cc",
37 "video_denoiser.h",
Henrik Kjellander0f59a882015-11-18 22:31:24 +010038 "video_processing_impl.cc",
39 "video_processing_impl.h",
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000040 ]
41
42 deps = [
43 "../../common_audio",
44 "../../common_video",
45 "../../modules/utility",
46 "../../system_wrappers",
47 ]
48 if (build_video_processing_sse2) {
49 deps += [ ":video_processing_sse2" ]
50 }
jackychen8f9902a2015-11-26 02:59:48 -080051 if (rtc_build_with_neon) {
52 deps += [ ":video_processing_neon" ]
53 }
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000054
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +000055 configs += [ "../..:common_config" ]
56 public_configs = [ "../..:common_inherited_config" ]
57
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000058 if (is_clang) {
59 # Suppress warnings from Chrome's Clang plugins.
60 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
61 configs -= [ "//build/config/clang:find_bad_constructs" ]
62 }
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000063}
64
65if (build_video_processing_sse2) {
66 source_set("video_processing_sse2") {
Henrik Kjellander57e5fd22015-05-25 12:55:39 +020067 sources = [
Henrik Kjellander0f59a882015-11-18 22:31:24 +010068 "content_analysis_sse2.cc",
jackychen8f9902a2015-11-26 02:59:48 -080069 "util/denoiser_filter_sse2.cc",
70 "util/denoiser_filter_sse2.h",
Henrik Kjellander57e5fd22015-05-25 12:55:39 +020071 ]
kjellander@webrtc.org4a251992014-08-18 17:56:28 +000072
kjellander@webrtc.orgf21ea912014-09-28 17:37:22 +000073 configs += [ "../..:common_config" ]
74 public_configs = [ "../..:common_inherited_config" ]
kjellander@webrtc.org42ee5b52014-08-25 14:15:35 +000075
76 if (is_clang) {
77 # Suppress warnings from Chrome's Clang plugins.
78 # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
79 configs -= [ "//build/config/clang:find_bad_constructs" ]
80 }
kjellander@webrtc.org4a251992014-08-18 17:56:28 +000081
stefan@webrtc.org73823ca2014-07-07 11:46:43 +000082 if (is_posix) {
83 cflags = [ "-msse2" ]
84 }
85 }
kjellander@webrtc.org1227ab82014-06-23 19:21:07 +000086}
jackychen8f9902a2015-11-26 02:59:48 -080087
88if (rtc_build_with_neon) {
89 source_set("video_processing_neon") {
90 sources = [
91 "util/denoiser_filter_neon.cc",
92 "util/denoiser_filter_neon.h",
93 ]
94 if (current_cpu != "arm64") {
95 configs -= [ "//build/config/compiler:compiler_arm_fpu" ]
96 cflags = [ "-mfpu=neon" ]
97 }
Magnus Jedvert8779a772015-11-27 12:02:52 +010098 configs += [ "../..:common_config" ]
99 public_configs = [ "../..:common_inherited_config" ]
jackychen8f9902a2015-11-26 02:59:48 -0800100 }
101}