You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

261 lines
9.9 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. # Copyright (c) 2016 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. import("../webrtc.gni")
  9. import("audio_coding/audio_coding.gni")
  10. group("modules") {
  11. deps = [
  12. "audio_coding",
  13. "audio_device",
  14. "audio_mixer",
  15. "audio_processing",
  16. "congestion_controller",
  17. "pacing",
  18. "remote_bitrate_estimator",
  19. "rtp_rtcp",
  20. "utility",
  21. "video_coding",
  22. "video_processing",
  23. ]
  24. if (rtc_desktop_capture_supported) {
  25. deps += [ "desktop_capture" ]
  26. }
  27. }
  28. rtc_source_set("module_api_public") {
  29. sources = [
  30. "include/module_common_types_public.h",
  31. ]
  32. deps = [
  33. "..:webrtc_common",
  34. "//third_party/abseil-cpp/absl/types:optional",
  35. ]
  36. }
  37. rtc_library("module_api") {
  38. visibility = [ "*" ]
  39. sources = [
  40. "include/module.h",
  41. "include/module_common_types.cc",
  42. "include/module_common_types.h",
  43. ]
  44. deps = [
  45. "../rtc_base:safe_conversions",
  46. "../rtc_base/system:rtc_export",
  47. ]
  48. }
  49. rtc_source_set("module_fec_api") {
  50. visibility = [ "*" ]
  51. sources = [
  52. "include/module_fec_types.h",
  53. ]
  54. }
  55. if (rtc_include_tests) {
  56. modules_tests_resources = [
  57. "../resources/audio_coding/testfile32kHz.pcm",
  58. "../resources/audio_coding/teststereo32kHz.pcm",
  59. "../resources/foreman_cif.yuv",
  60. ]
  61. if (is_ios) {
  62. bundle_data("modules_tests_bundle_data") {
  63. testonly = true
  64. sources = modules_tests_resources
  65. outputs = [
  66. "{{bundle_resources_dir}}/{{source_file_part}}",
  67. ]
  68. }
  69. }
  70. rtc_test("modules_tests") {
  71. testonly = true
  72. deps = [
  73. "../test:test_main",
  74. "../test:video_test_common",
  75. "audio_coding:audio_coding_modules_tests",
  76. "rtp_rtcp:rtp_rtcp_modules_tests",
  77. "video_coding:video_coding_modules_tests",
  78. "//testing/gtest",
  79. ]
  80. if (rtc_desktop_capture_supported) {
  81. deps += [ "desktop_capture:desktop_capture_modules_tests" ]
  82. }
  83. data = modules_tests_resources
  84. if (is_android) {
  85. deps += [
  86. # NOTE(brandtr): Including Java classes seems only to be possible from
  87. # rtc_test targets. Therefore we include this target here, instead of
  88. # in video_coding_modules_tests, where it is actually used.
  89. "../sdk/android:libjingle_peerconnection_java",
  90. "//testing/android/native_test:native_test_native_code",
  91. ]
  92. shard_timeout = 900
  93. }
  94. if (is_ios) {
  95. deps += [ ":modules_tests_bundle_data" ]
  96. }
  97. }
  98. modules_unittests_resources = [
  99. "../resources/audio_coding/neteq_opus.rtp",
  100. "../resources/audio_coding/neteq_opus_dtx.rtp",
  101. "../resources/audio_coding/neteq_universal_new.rtp",
  102. "../resources/audio_coding/speech_mono_16kHz.pcm",
  103. "../resources/audio_coding/speech_mono_32_48kHz.pcm",
  104. "../resources/audio_coding/speech_4_channels_48k_one_second.wav",
  105. "../resources/audio_coding/testfile32kHz.pcm",
  106. "../resources/audio_coding/testfile_fake_stereo_32kHz.pcm",
  107. "../resources/audio_coding/teststereo32kHz.pcm",
  108. "../resources/audio_device/audio_short16.pcm",
  109. "../resources/audio_device/audio_short44.pcm",
  110. "../resources/audio_device/audio_short48.pcm",
  111. "../resources/audio_processing/agc/agc_audio.pcm",
  112. "../resources/audio_processing/agc/agc_no_circular_buffer.dat",
  113. "../resources/audio_processing/agc/agc_pitch_gain.dat",
  114. "../resources/audio_processing/agc/agc_pitch_lag.dat",
  115. "../resources/audio_processing/agc/agc_spectral_peak.dat",
  116. "../resources/audio_processing/agc/agc_vad.dat",
  117. "../resources/audio_processing/agc/agc_voicing_prob.dat",
  118. "../resources/audio_processing/agc/agc_with_circular_buffer.dat",
  119. "../resources/audio_processing/output_data_fixed.pb",
  120. "../resources/audio_processing/output_data_float.pb",
  121. "../resources/audio_processing/output_data_mac.pb",
  122. "../resources/audio_processing/transient/ajm-macbook-1-spke16m.pcm",
  123. "../resources/audio_processing/transient/audio16kHz.pcm",
  124. "../resources/audio_processing/transient/audio32kHz.pcm",
  125. "../resources/audio_processing/transient/audio48kHz.pcm",
  126. "../resources/audio_processing/transient/audio8kHz.pcm",
  127. "../resources/audio_processing/transient/detect16kHz.dat",
  128. "../resources/audio_processing/transient/detect32kHz.dat",
  129. "../resources/audio_processing/transient/detect48kHz.dat",
  130. "../resources/audio_processing/transient/detect8kHz.dat",
  131. "../resources/audio_processing/transient/double-utils.dat",
  132. "../resources/audio_processing/transient/float-utils.dat",
  133. "../resources/audio_processing/transient/suppressed16kHz.pcm",
  134. "../resources/audio_processing/transient/suppressed32kHz.pcm",
  135. "../resources/audio_processing/transient/suppressed8kHz.pcm",
  136. "../resources/audio_processing/transient/wpd0.dat",
  137. "../resources/audio_processing/transient/wpd1.dat",
  138. "../resources/audio_processing/transient/wpd2.dat",
  139. "../resources/audio_processing/transient/wpd3.dat",
  140. "../resources/audio_processing/transient/wpd4.dat",
  141. "../resources/audio_processing/transient/wpd5.dat",
  142. "../resources/audio_processing/transient/wpd6.dat",
  143. "../resources/audio_processing/transient/wpd7.dat",
  144. "../resources/deflicker_before_cif_short.yuv",
  145. "../resources/far16_stereo.pcm",
  146. "../resources/far32_stereo.pcm",
  147. "../resources/far44_stereo.pcm",
  148. "../resources/far48_stereo.pcm",
  149. "../resources/far8_stereo.pcm",
  150. "../resources/foremanColorEnhanced_cif_short.yuv",
  151. "../resources/foreman_cif.yuv",
  152. "../resources/foreman_cif_short.yuv",
  153. "../resources/near16_stereo.pcm",
  154. "../resources/near32_stereo.pcm",
  155. "../resources/near44_stereo.pcm",
  156. "../resources/near48_stereo.pcm",
  157. "../resources/near8_stereo.pcm",
  158. "../resources/ref03.aecdump",
  159. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke1_0_AST.bin",
  160. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke1_0_TOF.bin",
  161. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke1_1_AST.bin",
  162. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke1_1_TOF.bin",
  163. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke2_0_AST.bin",
  164. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke2_0_TOF.bin",
  165. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke2_1_AST.bin",
  166. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingChoke2_1_TOF.bin",
  167. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingDelay1_0_AST.bin",
  168. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingDelay1_0_TOF.bin",
  169. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingLoss1_0_AST.bin",
  170. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_IncreasingLoss1_0_TOF.bin",
  171. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_Multi1_1_AST.bin",
  172. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_Multi1_1_TOF.bin",
  173. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyChoke_0_AST.bin",
  174. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyChoke_0_TOF.bin",
  175. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyChoke_1_AST.bin",
  176. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyChoke_1_TOF.bin",
  177. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyDelay_0_AST.bin",
  178. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyDelay_0_TOF.bin",
  179. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyLoss_0_AST.bin",
  180. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_SteadyLoss_0_TOF.bin",
  181. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_UnlimitedSpeed_0_AST.bin",
  182. "../resources/remote_bitrate_estimator/VideoSendersTest_BweTest_UnlimitedSpeed_0_TOF.bin",
  183. "../resources/short_mixed_mono_48.dat",
  184. "../resources/short_mixed_mono_48_arm.dat",
  185. "../resources/short_mixed_mono_48.pcm",
  186. "../resources/short_mixed_stereo_48.dat",
  187. "../resources/short_mixed_stereo_48.pcm",
  188. "../resources/voice_engine/audio_tiny48.wav",
  189. ]
  190. if (is_ios) {
  191. bundle_data("modules_unittests_bundle_data") {
  192. testonly = true
  193. sources = modules_unittests_resources
  194. outputs = [
  195. "{{bundle_resources_dir}}/{{source_file_part}}",
  196. ]
  197. }
  198. }
  199. rtc_test("modules_unittests") {
  200. testonly = true
  201. defines = []
  202. sources = [
  203. "module_common_types_unittest.cc",
  204. ]
  205. deps = [
  206. ":module_api",
  207. ":module_api_public",
  208. "../test:test_main",
  209. "../test:test_support",
  210. "audio_coding:audio_coding_unittests",
  211. "audio_device:audio_device_unittests",
  212. "audio_mixer:audio_mixer_unittests",
  213. "audio_processing:audio_processing_unittests",
  214. "audio_processing/aec3:aec3_unittests",
  215. "congestion_controller:congestion_controller_unittests",
  216. "pacing:pacing_unittests",
  217. "remote_bitrate_estimator:remote_bitrate_estimator_unittests",
  218. "rtp_rtcp:rtp_rtcp_unittests",
  219. "utility:utility_unittests",
  220. "video_coding:video_coding_unittests",
  221. "video_processing:video_processing_unittests",
  222. ]
  223. if (rtc_desktop_capture_supported) {
  224. deps += [ "desktop_capture:desktop_capture_unittests" ]
  225. }
  226. data = modules_unittests_resources
  227. if (is_android) {
  228. deps += [
  229. "../sdk/android:libjingle_peerconnection_java",
  230. "//testing/android/native_test:native_test_support",
  231. ]
  232. shard_timeout = 900
  233. }
  234. if (is_ios) {
  235. info_plist = "../test/ios/Info.plist"
  236. deps += [ ":modules_unittests_bundle_data" ]
  237. configs += [ "..:common_objc" ]
  238. ldflags = [ "-ObjC" ]
  239. }
  240. }
  241. }