1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
8 # Override to dynamically link the cras (ChromeOS audio) library.
10 # Option e.g. for Linux distributions to link pulseaudio directly
11 # (DT_NEEDED) instead of using dlopen. This helps with automated
12 # detection of ABI mismatches and prevents silent errors.
13 'linux_link_pulseaudio%': 0,
15 ['OS=="android" or OS=="ios"', {
16 # Android and iOS don't use ffmpeg or libvpx.
17 'media_use_ffmpeg%': 0,
18 'media_use_libvpx%': 0,
19 }, { # 'OS!="android" and OS!="ios"'
20 'media_use_ffmpeg%': 1,
21 'media_use_libvpx%': 1,
23 # Enable ALSA and Pulse for runtime selection.
24 ['(OS=="linux" or OS=="freebsd" or OS=="solaris") and (embedded!=1 or (chromecast==1 and target_arch!="arm"))', {
25 # ALSA is always needed for Web MIDI even if the cras is enabled.
39 'pkg-config': '../build/linux/pkg-config-wrapper "<(sysroot)" "<(target_arch)" "<(system_libdir)"',
41 'pkg-config': 'pkg-config'
43 # low memory buffer is used in non-Android based chromecast build due to hardware limitation.
44 ['chromecast==1 and OS!="android"', {
45 'use_low_memory_buffer%': 1,
47 'use_low_memory_buffer%': 0,
57 'target_name': 'media',
58 'type': '<(component)',
60 '../base/base.gyp:base',
61 '../base/base.gyp:base_i18n',
62 '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations',
63 '../crypto/crypto.gyp:crypto',
64 '../gpu/gpu.gyp:command_buffer_common',
65 '../skia/skia.gyp:skia',
66 '../third_party/libyuv/libyuv.gyp:libyuv',
67 '../third_party/opus/opus.gyp:opus',
68 '../ui/events/events.gyp:events_base',
69 '../ui/gfx/gfx.gyp:gfx',
70 '../ui/gfx/gfx.gyp:gfx_geometry',
71 '../url/url.gyp:url_lib',
72 'shared_memory_support',
75 'MEDIA_IMPLEMENTATION',
81 'audio/agc_audio_stream.h',
82 'audio/alsa/alsa_input.cc',
83 'audio/alsa/alsa_input.h',
84 'audio/alsa/alsa_output.cc',
85 'audio/alsa/alsa_output.h',
86 'audio/alsa/alsa_util.cc',
87 'audio/alsa/alsa_util.h',
88 'audio/alsa/alsa_wrapper.cc',
89 'audio/alsa/alsa_wrapper.h',
90 'audio/alsa/audio_manager_alsa.cc',
91 'audio/alsa/audio_manager_alsa.h',
92 'audio/android/audio_manager_android.cc',
93 'audio/android/audio_manager_android.h',
94 'audio/android/audio_record_input.cc',
95 'audio/android/audio_record_input.h',
96 'audio/android/opensles_input.cc',
97 'audio/android/opensles_input.h',
98 'audio/android/opensles_output.cc',
99 'audio/android/opensles_output.h',
100 'audio/android/opensles_wrapper.cc',
101 'audio/audio_device_name.cc',
102 'audio/audio_device_name.h',
103 'audio/audio_device_thread.cc',
104 'audio/audio_device_thread.h',
105 'audio/audio_input_controller.cc',
106 'audio/audio_input_controller.h',
107 'audio/audio_input_device.cc',
108 'audio/audio_input_device.h',
109 'audio/audio_input_ipc.cc',
110 'audio/audio_input_ipc.h',
112 'audio/audio_manager.cc',
113 'audio/audio_manager.h',
114 'audio/audio_manager_base.cc',
115 'audio/audio_manager_base.h',
116 'audio/audio_output_controller.cc',
117 'audio/audio_output_controller.h',
118 'audio/audio_output_device.cc',
119 'audio/audio_output_device.h',
120 'audio/audio_output_dispatcher.cc',
121 'audio/audio_output_dispatcher.h',
122 'audio/audio_output_dispatcher_impl.cc',
123 'audio/audio_output_dispatcher_impl.h',
124 'audio/audio_output_ipc.cc',
125 'audio/audio_output_ipc.h',
126 'audio/audio_output_proxy.cc',
127 'audio/audio_output_proxy.h',
128 'audio/audio_output_resampler.cc',
129 'audio/audio_output_resampler.h',
130 'audio/audio_output_stream_sink.cc',
131 'audio/audio_output_stream_sink.h',
132 'audio/audio_power_monitor.cc',
133 'audio/audio_power_monitor.h',
134 'audio/audio_source_diverter.h',
135 'audio/clockless_audio_sink.cc',
136 'audio/clockless_audio_sink.h',
137 'audio/cras/audio_manager_cras.cc',
138 'audio/cras/audio_manager_cras.h',
139 'audio/cras/cras_input.cc',
140 'audio/cras/cras_input.h',
141 'audio/cras/cras_unified.cc',
142 'audio/cras/cras_unified.h',
143 'audio/fake_audio_input_stream.cc',
144 'audio/fake_audio_input_stream.h',
145 'audio/fake_audio_log_factory.cc',
146 'audio/fake_audio_log_factory.h',
147 'audio/fake_audio_manager.cc',
148 'audio/fake_audio_manager.h',
149 'audio/fake_audio_output_stream.cc',
150 'audio/fake_audio_output_stream.h',
151 'audio/fake_audio_worker.cc',
152 'audio/fake_audio_worker.h',
153 'audio/linux/audio_manager_linux.cc',
154 'audio/mac/audio_auhal_mac.cc',
155 'audio/mac/audio_auhal_mac.h',
156 'audio/mac/audio_device_listener_mac.cc',
157 'audio/mac/audio_device_listener_mac.h',
158 'audio/mac/audio_input_mac.cc',
159 'audio/mac/audio_input_mac.h',
160 'audio/mac/audio_low_latency_input_mac.cc',
161 'audio/mac/audio_low_latency_input_mac.h',
162 'audio/mac/audio_manager_mac.cc',
163 'audio/mac/audio_manager_mac.h',
164 'audio/null_audio_sink.cc',
165 'audio/null_audio_sink.h',
166 'audio/openbsd/audio_manager_openbsd.cc',
167 'audio/openbsd/audio_manager_openbsd.h',
168 'audio/pulse/audio_manager_pulse.cc',
169 'audio/pulse/audio_manager_pulse.h',
170 'audio/pulse/pulse_input.cc',
171 'audio/pulse/pulse_input.h',
172 'audio/pulse/pulse_output.cc',
173 'audio/pulse/pulse_output.h',
174 'audio/pulse/pulse_util.cc',
175 'audio/pulse/pulse_util.h',
176 'audio/sample_rates.cc',
177 'audio/sample_rates.h',
178 'audio/scoped_task_runner_observer.cc',
179 'audio/scoped_task_runner_observer.h',
180 'audio/simple_sources.cc',
181 'audio/simple_sources.h',
182 'audio/sounds/audio_stream_handler.cc',
183 'audio/sounds/audio_stream_handler.h',
184 'audio/sounds/sounds_manager.cc',
185 'audio/sounds/sounds_manager.h',
186 'audio/sounds/wav_audio_handler.cc',
187 'audio/sounds/wav_audio_handler.h',
188 'audio/virtual_audio_input_stream.cc',
189 'audio/virtual_audio_input_stream.h',
190 'audio/virtual_audio_output_stream.cc',
191 'audio/virtual_audio_output_stream.h',
192 'audio/win/audio_device_listener_win.cc',
193 'audio/win/audio_device_listener_win.h',
194 'audio/win/audio_low_latency_input_win.cc',
195 'audio/win/audio_low_latency_input_win.h',
196 'audio/win/audio_low_latency_output_win.cc',
197 'audio/win/audio_low_latency_output_win.h',
198 'audio/win/audio_manager_win.cc',
199 'audio/win/audio_manager_win.h',
200 'audio/win/avrt_wrapper_win.cc',
201 'audio/win/avrt_wrapper_win.h',
202 'audio/win/core_audio_util_win.cc',
203 'audio/win/core_audio_util_win.h',
204 'audio/win/device_enumeration_win.cc',
205 'audio/win/device_enumeration_win.h',
206 'audio/win/wavein_input_win.cc',
207 'audio/win/wavein_input_win.h',
208 'audio/win/waveout_output_win.cc',
209 'audio/win/waveout_output_win.h',
210 'base/audio_block_fifo.cc',
211 'base/audio_block_fifo.h',
212 'base/audio_buffer.cc',
213 'base/audio_buffer.h',
214 'base/audio_buffer_converter.cc',
215 'base/audio_buffer_converter.h',
216 'base/audio_buffer_queue.cc',
217 'base/audio_buffer_queue.h',
218 'base/audio_capturer_source.h',
219 'base/audio_converter.cc',
220 'base/audio_converter.h',
221 'base/audio_decoder.cc',
222 'base/audio_decoder.h',
223 'base/audio_decoder_config.cc',
224 'base/audio_decoder_config.h',
225 'base/audio_discard_helper.cc',
226 'base/audio_discard_helper.h',
227 'base/audio_fifo.cc',
229 'base/audio_hardware_config.cc',
230 'base/audio_hardware_config.h',
231 'base/audio_hash.cc',
233 'base/audio_pull_fifo.cc',
234 'base/audio_pull_fifo.h',
235 'base/audio_renderer.cc',
236 'base/audio_renderer.h',
237 'base/audio_renderer_mixer.cc',
238 'base/audio_renderer_mixer.h',
239 'base/audio_renderer_mixer_input.cc',
240 'base/audio_renderer_mixer_input.h',
241 'base/audio_renderer_sink.h',
242 'base/audio_shifter.cc',
243 'base/audio_shifter.h',
244 'base/audio_splicer.cc',
245 'base/audio_splicer.h',
246 'base/audio_timestamp_helper.cc',
247 'base/audio_timestamp_helper.h',
248 'base/audio_video_metadata_extractor.cc',
249 'base/audio_video_metadata_extractor.h',
250 'base/bind_to_current_loop.h',
251 'base/bit_reader.cc',
253 'base/bit_reader_core.cc',
254 'base/bit_reader_core.h',
255 'base/bitstream_buffer.h',
256 'base/buffering_state.h',
258 'base/byte_queue.cc',
260 'base/cdm_callback_promise.cc',
261 'base/cdm_callback_promise.h',
262 'base/cdm_context.cc',
263 'base/cdm_context.h',
264 'base/cdm_factory.cc',
265 'base/cdm_factory.h',
266 'base/cdm_key_information.cc',
267 'base/cdm_key_information.h',
268 'base/cdm_promise.cc',
269 'base/cdm_promise.h',
270 'base/cdm_promise_adapter.cc',
271 'base/cdm_promise_adapter.h',
272 'base/channel_mixer.cc',
273 'base/channel_mixer.h',
274 'base/channel_mixing_matrix.cc',
275 'base/channel_mixing_matrix.h',
276 'base/container_names.cc',
277 'base/container_names.h',
278 'base/data_buffer.cc',
279 'base/data_buffer.h',
280 'base/data_source.cc',
281 'base/data_source.h',
282 'base/decoder_buffer.cc',
283 'base/decoder_buffer.h',
284 'base/decoder_buffer_queue.cc',
285 'base/decoder_buffer_queue.h',
286 'base/decrypt_config.cc',
287 'base/decrypt_config.h',
292 'base/demuxer_stream.cc',
293 'base/demuxer_stream.h',
294 'base/demuxer_stream_provider.cc',
295 'base/demuxer_stream_provider.h',
298 'base/eme_constants.h',
299 'base/key_system_info.cc',
300 'base/key_system_info.h',
301 'base/key_systems.cc',
302 'base/key_systems.h',
303 'base/key_systems_support_uma.cc',
304 'base/key_systems_support_uma.h',
305 'base/keyboard_event_counter.cc',
306 'base/keyboard_event_counter.h',
307 'base/mac/avfoundation_glue.h',
308 'base/mac/avfoundation_glue.mm',
309 'base/mac/coremedia_glue.h',
310 'base/mac/coremedia_glue.mm',
311 'base/mac/corevideo_glue.h',
312 'base/mac/video_frame_mac.cc',
313 'base/mac/video_frame_mac.h',
314 'base/mac/videotoolbox_glue.h',
315 'base/mac/videotoolbox_glue.mm',
318 'base/media_client.cc',
319 'base/media_client.h',
320 'base/media_file_checker.cc',
321 'base/media_file_checker.h',
322 'base/media_keys.cc',
326 'base/media_log_event.h',
327 'base/media_permission.cc',
328 'base/media_permission.h',
329 'base/media_posix.cc',
330 'base/media_switches.cc',
331 'base/media_switches.h',
333 'base/multi_channel_resampler.cc',
334 'base/multi_channel_resampler.h',
337 'base/pipeline_status.h',
338 'base/player_tracker.cc',
339 'base/player_tracker.h',
344 'base/renderer_factory.cc',
345 'base/renderer_factory.h',
346 'base/sample_format.cc',
347 'base/sample_format.h',
348 'base/seekable_buffer.cc',
349 'base/seekable_buffer.h',
350 'base/serial_runner.cc',
351 'base/serial_runner.h',
352 'base/simd/convert_rgb_to_yuv.h',
353 'base/simd/convert_rgb_to_yuv_c.cc',
354 'base/simd/convert_yuv_to_rgb.h',
355 'base/simd/convert_yuv_to_rgb_c.cc',
356 'base/simd/filter_yuv.h',
357 'base/simd/filter_yuv_c.cc',
358 'base/sinc_resampler.cc',
359 'base/sinc_resampler.h',
360 'base/stream_parser.cc',
361 'base/stream_parser.h',
362 'base/stream_parser_buffer.cc',
363 'base/stream_parser_buffer.h',
366 'base/text_ranges.cc',
367 'base/text_ranges.h',
368 'base/text_renderer.cc',
369 'base/text_renderer.h',
371 'base/text_track_config.cc',
372 'base/text_track_config.h',
373 'base/time_delta_interpolator.cc',
374 'base/time_delta_interpolator.h',
375 'base/time_source.h',
376 'base/user_input_monitor.cc',
377 'base/user_input_monitor.h',
378 'base/user_input_monitor_linux.cc',
379 'base/user_input_monitor_mac.cc',
380 'base/user_input_monitor_win.cc',
381 'base/video_capture_types.cc',
382 'base/video_capture_types.h',
383 'base/video_capturer_source.cc',
384 'base/video_capturer_source.h',
385 'base/video_decoder.cc',
386 'base/video_decoder.h',
387 'base/video_decoder_config.cc',
388 'base/video_decoder_config.h',
389 'base/video_frame.cc',
390 'base/video_frame.h',
391 'base/video_frame_metadata.cc',
392 'base/video_frame_metadata.h',
393 'base/video_frame_pool.cc',
394 'base/video_frame_pool.h',
395 'base/video_renderer.cc',
396 'base/video_renderer.h',
397 'base/video_rotation.h',
398 'base/video_util.cc',
400 'base/wall_clock_time_source.cc',
401 'base/wall_clock_time_source.h',
402 'base/yuv_convert.cc',
403 'base/yuv_convert.h',
404 'blink/skcanvas_video_renderer.cc',
405 'blink/skcanvas_video_renderer.h',
406 'cdm/aes_decryptor.cc',
407 'cdm/aes_decryptor.h',
410 'cdm/default_cdm_factory.cc',
411 'cdm/default_cdm_factory.h',
412 'cdm/json_web_key.cc',
413 'cdm/json_web_key.h',
414 'cdm/key_system_names.cc',
415 'cdm/key_system_names.h',
416 'cdm/player_tracker_impl.cc',
417 'cdm/player_tracker_impl.h',
418 'cdm/proxy_decryptor.cc',
419 'cdm/proxy_decryptor.h',
420 'ffmpeg/ffmpeg_common.cc',
421 'ffmpeg/ffmpeg_common.h',
422 'ffmpeg/ffmpeg_deleters.h',
423 'filters/audio_clock.cc',
424 'filters/audio_clock.h',
425 'filters/audio_file_reader.cc',
426 'filters/audio_file_reader.h',
427 'filters/audio_renderer_algorithm.cc',
428 'filters/audio_renderer_algorithm.h',
429 'filters/blocking_url_protocol.cc',
430 'filters/blocking_url_protocol.h',
431 'filters/chunk_demuxer.cc',
432 'filters/chunk_demuxer.h',
433 'filters/context_3d.h',
434 'filters/decoder_selector.cc',
435 'filters/decoder_selector.h',
436 'filters/decoder_stream.cc',
437 'filters/decoder_stream.h',
438 'filters/decoder_stream_traits.cc',
439 'filters/decoder_stream_traits.h',
440 'filters/decrypting_audio_decoder.cc',
441 'filters/decrypting_audio_decoder.h',
442 'filters/decrypting_demuxer_stream.cc',
443 'filters/decrypting_demuxer_stream.h',
444 'filters/decrypting_video_decoder.cc',
445 'filters/decrypting_video_decoder.h',
446 'filters/default_media_permission.cc',
447 'filters/default_media_permission.h',
448 'filters/ffmpeg_audio_decoder.cc',
449 'filters/ffmpeg_audio_decoder.h',
450 'filters/ffmpeg_bitstream_converter.h',
451 'filters/ffmpeg_demuxer.cc',
452 'filters/ffmpeg_demuxer.h',
453 'filters/ffmpeg_glue.cc',
454 'filters/ffmpeg_glue.h',
455 'filters/ffmpeg_video_decoder.cc',
456 'filters/ffmpeg_video_decoder.h',
457 'filters/file_data_source.cc',
458 'filters/file_data_source.h',
459 'filters/frame_processor.cc',
460 'filters/frame_processor.h',
461 'filters/gpu_video_decoder.cc',
462 'filters/gpu_video_decoder.h',
463 'filters/h264_bit_reader.cc',
464 'filters/h264_bit_reader.h',
465 'filters/h264_parser.cc',
466 'filters/h264_parser.h',
467 'filters/in_memory_url_protocol.cc',
468 'filters/in_memory_url_protocol.h',
469 'filters/jpeg_parser.cc',
470 'filters/jpeg_parser.h',
471 'filters/opus_audio_decoder.cc',
472 'filters/opus_audio_decoder.h',
473 'filters/source_buffer_range.cc',
474 'filters/source_buffer_range.h',
475 'filters/source_buffer_stream.cc',
476 'filters/source_buffer_stream.h',
477 'filters/stream_parser_factory.cc',
478 'filters/stream_parser_factory.h',
479 'filters/video_frame_scheduler.h',
480 'filters/video_frame_scheduler_impl.cc',
481 'filters/video_frame_scheduler_impl.h',
482 'filters/video_frame_scheduler_proxy.cc',
483 'filters/video_frame_scheduler_proxy.h',
484 'filters/vp8_bool_decoder.cc',
485 'filters/vp8_bool_decoder.h',
486 'filters/vp8_parser.cc',
487 'filters/vp8_parser.h',
488 'filters/vpx_video_decoder.cc',
489 'filters/vpx_video_decoder.h',
490 'filters/webvtt_util.h',
491 'filters/wsola_internals.cc',
492 'filters/wsola_internals.h',
493 'formats/common/offset_byte_queue.cc',
494 'formats/common/offset_byte_queue.h',
495 'formats/webm/webm_audio_client.cc',
496 'formats/webm/webm_audio_client.h',
497 'formats/webm/webm_cluster_parser.cc',
498 'formats/webm/webm_cluster_parser.h',
499 'formats/webm/webm_constants.cc',
500 'formats/webm/webm_constants.h',
501 'formats/webm/webm_content_encodings.cc',
502 'formats/webm/webm_content_encodings.h',
503 'formats/webm/webm_content_encodings_client.cc',
504 'formats/webm/webm_content_encodings_client.h',
505 'formats/webm/webm_crypto_helpers.cc',
506 'formats/webm/webm_crypto_helpers.h',
507 'formats/webm/webm_info_parser.cc',
508 'formats/webm/webm_info_parser.h',
509 'formats/webm/webm_parser.cc',
510 'formats/webm/webm_parser.h',
511 'formats/webm/webm_stream_parser.cc',
512 'formats/webm/webm_stream_parser.h',
513 'formats/webm/webm_tracks_parser.cc',
514 'formats/webm/webm_tracks_parser.h',
515 'formats/webm/webm_video_client.cc',
516 'formats/webm/webm_video_client.h',
517 'formats/webm/webm_webvtt_parser.cc',
518 'midi/midi_manager.cc',
519 'midi/midi_manager.h',
520 'midi/midi_manager_alsa.cc',
521 'midi/midi_manager_alsa.h',
522 'midi/midi_manager_android.cc',
523 'midi/midi_manager_mac.cc',
524 'midi/midi_manager_mac.h',
525 'midi/midi_manager_usb.cc',
526 'midi/midi_manager_usb.h',
527 'midi/midi_manager_win.cc',
528 'midi/midi_manager_win.h',
529 'midi/midi_message_queue.cc',
530 'midi/midi_message_queue.h',
531 'midi/midi_message_util.cc',
532 'midi/midi_message_util.h',
533 'midi/midi_port_info.cc',
534 'midi/midi_port_info.h',
535 'midi/midi_scheduler.cc',
536 'midi/midi_scheduler.h',
537 'midi/usb_midi_descriptor_parser.cc',
538 'midi/usb_midi_descriptor_parser.h',
539 'midi/usb_midi_device.h',
540 'midi/usb_midi_device_android.cc',
541 'midi/usb_midi_device_android.h',
542 'midi/usb_midi_device_factory_android.cc',
543 'midi/usb_midi_device_factory_android.h',
544 'midi/usb_midi_input_stream.cc',
545 'midi/usb_midi_input_stream.h',
546 'midi/usb_midi_jack.h',
547 'midi/usb_midi_output_stream.cc',
548 'midi/usb_midi_output_stream.h',
549 'ozone/media_ozone_platform.cc',
550 'ozone/media_ozone_platform.h',
551 'renderers/audio_renderer_impl.cc',
552 'renderers/audio_renderer_impl.h',
553 'renderers/default_renderer_factory.cc',
554 'renderers/default_renderer_factory.h',
555 'renderers/gpu_video_accelerator_factories.h',
556 'renderers/renderer_impl.cc',
557 'renderers/renderer_impl.h',
558 'renderers/video_renderer_impl.cc',
559 'renderers/video_renderer_impl.h',
560 'video/capture/android/video_capture_device_android.cc',
561 'video/capture/android/video_capture_device_android.h',
562 'video/capture/android/video_capture_device_factory_android.cc',
563 'video/capture/android/video_capture_device_factory_android.h',
564 'video/capture/fake_video_capture_device.cc',
565 'video/capture/fake_video_capture_device.h',
566 'video/capture/fake_video_capture_device_factory.cc',
567 'video/capture/fake_video_capture_device_factory.h',
568 'video/capture/file_video_capture_device.cc',
569 'video/capture/file_video_capture_device.h',
570 'video/capture/file_video_capture_device_factory.cc',
571 'video/capture/file_video_capture_device_factory.h',
572 'video/capture/linux/v4l2_capture_delegate.cc',
573 'video/capture/linux/v4l2_capture_delegate.h',
574 'video/capture/linux/v4l2_capture_delegate_multi_plane.cc',
575 'video/capture/linux/v4l2_capture_delegate_multi_plane.h',
576 'video/capture/linux/v4l2_capture_delegate_single_plane.cc',
577 'video/capture/linux/v4l2_capture_delegate_single_plane.h',
578 'video/capture/linux/video_capture_device_chromeos.cc',
579 'video/capture/linux/video_capture_device_chromeos.h',
580 'video/capture/linux/video_capture_device_factory_linux.cc',
581 'video/capture/linux/video_capture_device_factory_linux.h',
582 'video/capture/linux/video_capture_device_linux.cc',
583 'video/capture/linux/video_capture_device_linux.h',
584 'video/capture/mac/platform_video_capturing_mac.h',
585 'video/capture/mac/video_capture_device_avfoundation_mac.h',
586 'video/capture/mac/video_capture_device_avfoundation_mac.mm',
587 'video/capture/mac/video_capture_device_decklink_mac.h',
588 'video/capture/mac/video_capture_device_decklink_mac.mm',
589 'video/capture/mac/video_capture_device_factory_mac.h',
590 'video/capture/mac/video_capture_device_factory_mac.mm',
591 'video/capture/mac/video_capture_device_mac.h',
592 'video/capture/mac/video_capture_device_mac.mm',
593 'video/capture/mac/video_capture_device_qtkit_mac.h',
594 'video/capture/mac/video_capture_device_qtkit_mac.mm',
595 'video/capture/video_capture_device.cc',
596 'video/capture/video_capture_device.h',
597 'video/capture/video_capture_device_factory.cc',
598 'video/capture/video_capture_device_factory.h',
599 'video/capture/video_capture_device_info.cc',
600 'video/capture/video_capture_device_info.h',
601 'video/capture/win/capability_list_win.cc',
602 'video/capture/win/capability_list_win.h',
603 'video/capture/win/filter_base_win.cc',
604 'video/capture/win/filter_base_win.h',
605 'video/capture/win/pin_base_win.cc',
606 'video/capture/win/pin_base_win.h',
607 'video/capture/win/sink_filter_observer_win.h',
608 'video/capture/win/sink_filter_win.cc',
609 'video/capture/win/sink_filter_win.h',
610 'video/capture/win/sink_input_pin_win.cc',
611 'video/capture/win/sink_input_pin_win.h',
612 'video/capture/win/video_capture_device_factory_win.cc',
613 'video/capture/win/video_capture_device_factory_win.h',
614 'video/capture/win/video_capture_device_mf_win.cc',
615 'video/capture/win/video_capture_device_mf_win.h',
616 'video/capture/win/video_capture_device_win.cc',
617 'video/capture/win/video_capture_device_win.h',
618 'video/fake_video_encode_accelerator.cc',
619 'video/fake_video_encode_accelerator.h',
624 'video/video_decode_accelerator.cc',
625 'video/video_decode_accelerator.h',
626 'video/video_encode_accelerator.cc',
627 'video/video_encode_accelerator.h',
628 'formats/webm/webm_webvtt_parser.h'
630 'direct_dependent_settings': {
641 ['media_use_ffmpeg==1', {
643 '../third_party/ffmpeg/ffmpeg.gyp:ffmpeg',
645 }, { # media_use_ffmpeg==0
646 # Exclude the sources that depend on ffmpeg.
648 'base/audio_video_metadata_extractor.cc',
649 'base/audio_video_metadata_extractor.h',
650 'base/container_names.cc',
651 'base/container_names.h',
652 'base/media_file_checker.cc',
653 'base/media_file_checker.h',
654 'base/media_posix.cc',
655 'ffmpeg/ffmpeg_common.cc',
656 'ffmpeg/ffmpeg_common.h',
657 'filters/audio_file_reader.cc',
658 'filters/audio_file_reader.h',
659 'filters/blocking_url_protocol.cc',
660 'filters/blocking_url_protocol.h',
661 'filters/ffmpeg_aac_bitstream_converter.cc',
662 'filters/ffmpeg_aac_bitstream_converter.h',
663 'filters/ffmpeg_audio_decoder.cc',
664 'filters/ffmpeg_audio_decoder.h',
665 'filters/ffmpeg_bitstream_converter.h',
666 'filters/ffmpeg_demuxer.cc',
667 'filters/ffmpeg_demuxer.h',
668 'filters/ffmpeg_glue.cc',
669 'filters/ffmpeg_glue.h',
670 'filters/ffmpeg_h264_to_annex_b_bitstream_converter.cc',
671 'filters/ffmpeg_h264_to_annex_b_bitstream_converter.h',
672 'filters/ffmpeg_video_decoder.cc',
673 'filters/ffmpeg_video_decoder.h',
674 'filters/in_memory_url_protocol.cc',
675 'filters/in_memory_url_protocol.h',
678 'MEDIA_DISABLE_FFMPEG',
680 'direct_dependent_settings': {
682 'MEDIA_DISABLE_FFMPEG',
686 ['media_use_libvpx==1', {
688 '<(DEPTH)/third_party/libvpx/libvpx.gyp:libvpx',
690 }, { # media_use_libvpx==0
692 'MEDIA_DISABLE_LIBVPX',
694 'direct_dependent_settings': {
696 'MEDIA_DISABLE_LIBVPX',
699 # Exclude the sources that depend on libvpx.
701 'filters/vpx_video_decoder.cc',
702 'filters/vpx_video_decoder.h',
705 ['enable_browser_cdms==1', {
707 'base/browser_cdm.cc',
708 'base/browser_cdm.h',
709 'base/browser_cdm_factory.cc',
710 'base/browser_cdm_factory.h',
715 'media_android_jni_headers',
717 'video_capture_android_jni_headers',
722 'base/media_stub.cc',
725 'filters/opus_audio_decoder.cc',
726 'filters/opus_audio_decoder.h',
727 'renderers/default_renderer_factory.cc',
728 'renderers/default_renderer_factory.h',
731 ['android_webview_build==0', {
738 'DISABLE_USER_INPUT_MONITOR',
741 # For VaapiVideoEncodeAccelerator.
742 ['target_arch != "arm" and chromeos == 1', {
744 'filters/h264_bitstream_buffer.cc',
745 'filters/h264_bitstream_buffer.h',
759 ['exclude', '(^|/)alsa/'],
760 ['exclude', '_alsa\\.(h|cc)$'],
765 'audio/openbsd/audio_manager_openbsd.cc',
766 'audio/openbsd/audio_manager_openbsd.h',
768 }, { # else: openbsd==1
770 'video/capture/linux/v4l2_capture_delegate_multi_plane.cc',
771 'video/capture/linux/v4l2_capture_delegate_multi_plane.h',
778 '../build/linux/system.gyp:x11',
779 '../build/linux/system.gyp:xdamage',
780 '../build/linux/system.gyp:xext',
781 '../build/linux/system.gyp:xfixes',
782 '../build/linux/system.gyp:xtst',
783 '../ui/gfx/x/gfx_x11.gyp:gfx_x11',
785 }, { # else: use_x11==0
787 'base/user_input_monitor_linux.cc',
790 'DISABLE_USER_INPUT_MONITOR',
795 '<!@(<(pkg-config) --cflags libcras)',
799 '<!@(<(pkg-config) --libs libcras)',
805 }, { # else: use_cras==0
807 'audio/cras/audio_manager_cras.cc',
808 'audio/cras/audio_manager_cras.h',
809 'audio/cras/cras_input.cc',
810 'audio/cras/cras_input.h',
811 'audio/cras/cras_unified.cc',
812 'audio/cras/cras_unified.h',
819 'platform_list_txt_file': '<(SHARED_INTERMEDIATE_DIR)/ui/ozone/platform_list.txt',
820 'constructor_list_cc_file': '<(INTERMEDIATE_DIR)/media/ozone/constructor_list.cc',
823 # Used for the generated listing header (ui/ozone/platform_list.h)
824 '<(SHARED_INTERMEDIATE_DIR)',
827 '<(constructor_list_cc_file)',
830 '../ui/ozone/ozone.gyp:ozone',
834 # Ozone platform objects are auto-generated using similar
835 # patterns for naming and classes constructors. Here we build the
836 # object MediaOzonePlatform.
837 'action_name': 'generate_constructor_list',
839 'generator_path': '../ui/ozone/generate_constructor_list.py',
843 '<(platform_list_txt_file)',
846 '<(constructor_list_cc_file)',
851 '--platform_list=<(platform_list_txt_file)',
852 '--output_cc=<(constructor_list_cc_file)',
854 '--typename=MediaOzonePlatform',
855 '--include="media/ozone/media_ozone_platform.h"'
861 'ozone/media_ozone_platform.cc',
862 'ozone/media_ozone_platform.h',
867 'audio/cras/audio_manager_cras.cc',
868 'audio/cras/audio_manager_cras.h',
869 'audio/cras/cras_input.cc',
870 'audio/cras/cras_input.h',
871 'audio/cras/cras_unified.cc',
872 'audio/cras/cras_unified.h',
875 ['use_pulseaudio==1', {
877 '<!@(<(pkg-config) --cflags libpulse)',
883 ['linux_link_pulseaudio==0', {
888 'generate_stubs_script': '../tools/generate_stubs/generate_stubs.py',
889 'extra_header': 'audio/pulse/pulse_stub_header.fragment',
890 'sig_files': ['audio/pulse/pulse.sigs'],
891 'outfile_type': 'posix_stubs',
892 'stubs_filename_root': 'pulse_stubs',
893 'project_path': 'media/audio/pulse',
894 'intermediate_dir': '<(INTERMEDIATE_DIR)',
895 'output_root': '<(SHARED_INTERMEDIATE_DIR)/pulse',
902 'action_name': 'generate_stubs',
904 '<(generate_stubs_script)',
909 '<(intermediate_dir)/<(stubs_filename_root).cc',
910 '<(output_root)/<(project_path)/<(stubs_filename_root).h',
913 '<(generate_stubs_script)',
914 '-i', '<(intermediate_dir)',
915 '-o', '<(output_root)/<(project_path)',
916 '-t', '<(outfile_type)',
917 '-e', '<(extra_header)',
918 '-s', '<(stubs_filename_root)',
919 '-p', '<(project_path)',
922 'process_outputs_as_sources': 1,
923 'message': 'Generating Pulse stubs for dynamic loading',
927 # Linux/Solaris need libdl for dlopen() and friends.
928 ['OS=="linux" or OS=="solaris"', {
936 }, { # else: linux_link_pulseaudio==0
939 '<!@(<(pkg-config) --libs-only-L --libs-only-other libpulse)',
942 '<!@(<(pkg-config) --libs-only-l libpulse)',
947 }, { # else: use_pulseaudio==0
949 'audio/pulse/audio_manager_pulse.cc',
950 'audio/pulse/audio_manager_pulse.h',
951 'audio/pulse/pulse_input.cc',
952 'audio/pulse/pulse_input.h',
953 'audio/pulse/pulse_output.cc',
954 'audio/pulse/pulse_output.h',
955 'audio/pulse/pulse_util.cc',
956 'audio/pulse/pulse_util.h',
961 '../third_party/decklink/decklink.gyp:decklink',
965 '$(SDKROOT)/System/Library/Frameworks/AudioToolbox.framework',
966 '$(SDKROOT)/System/Library/Frameworks/AudioUnit.framework',
967 '$(SDKROOT)/System/Library/Frameworks/CoreAudio.framework',
968 '$(SDKROOT)/System/Library/Frameworks/CoreMIDI.framework',
969 '$(SDKROOT)/System/Library/Frameworks/CoreVideo.framework',
970 '$(SDKROOT)/System/Library/Frameworks/OpenGL.framework',
971 '$(SDKROOT)/System/Library/Frameworks/QTKit.framework',
977 '../device/usb/usb.gyp:device_usb',
987 # Specify delayload for media.dll.
997 # Specify delayload for components that link with media.lib.
998 'all_dependent_settings': {
1009 # TODO(wolenetz): Fix size_t to int truncations in win64. See
1010 # http://crbug.com/171009
1012 ['target_arch=="x64"', {
1013 'msvs_disabled_warnings': [ 4267, ],
1017 ['proprietary_codecs==1', {
1019 'filters/ffmpeg_aac_bitstream_converter.cc',
1020 'filters/ffmpeg_aac_bitstream_converter.h',
1021 'filters/ffmpeg_h264_to_annex_b_bitstream_converter.cc',
1022 'filters/ffmpeg_h264_to_annex_b_bitstream_converter.h',
1023 'filters/h264_to_annex_b_bitstream_converter.cc',
1024 'filters/h264_to_annex_b_bitstream_converter.h',
1025 'formats/mp2t/es_adapter_video.cc',
1026 'formats/mp2t/es_adapter_video.h',
1027 'formats/mp2t/es_parser.cc',
1028 'formats/mp2t/es_parser.h',
1029 'formats/mp2t/es_parser_adts.cc',
1030 'formats/mp2t/es_parser_adts.h',
1031 'formats/mp2t/es_parser_h264.cc',
1032 'formats/mp2t/es_parser_h264.h',
1033 'formats/mp2t/es_parser_mpeg1audio.cc',
1034 'formats/mp2t/es_parser_mpeg1audio.h',
1035 'formats/mp2t/mp2t_common.h',
1036 'formats/mp2t/mp2t_stream_parser.cc',
1037 'formats/mp2t/mp2t_stream_parser.h',
1038 'formats/mp2t/timestamp_unroller.cc',
1039 'formats/mp2t/timestamp_unroller.h',
1040 'formats/mp2t/ts_packet.cc',
1041 'formats/mp2t/ts_packet.h',
1042 'formats/mp2t/ts_section.h',
1043 'formats/mp2t/ts_section_pat.cc',
1044 'formats/mp2t/ts_section_pat.h',
1045 'formats/mp2t/ts_section_pes.cc',
1046 'formats/mp2t/ts_section_pes.h',
1047 'formats/mp2t/ts_section_pmt.cc',
1048 'formats/mp2t/ts_section_pmt.h',
1049 'formats/mp2t/ts_section_psi.cc',
1050 'formats/mp2t/ts_section_psi.h',
1051 'formats/mp4/aac.cc',
1052 'formats/mp4/aac.h',
1053 'formats/mp4/avc.cc',
1054 'formats/mp4/avc.h',
1055 'formats/mp4/box_definitions.cc',
1056 'formats/mp4/box_definitions.h',
1057 'formats/mp4/box_reader.cc',
1058 'formats/mp4/box_reader.h',
1059 'formats/mp4/cenc.cc',
1060 'formats/mp4/cenc.h',
1061 'formats/mp4/es_descriptor.cc',
1062 'formats/mp4/es_descriptor.h',
1063 'formats/mp4/mp4_stream_parser.cc',
1064 'formats/mp4/mp4_stream_parser.h',
1065 'formats/mp4/sample_to_group_iterator.cc',
1066 'formats/mp4/sample_to_group_iterator.h',
1067 'formats/mp4/track_run_iterator.cc',
1068 'formats/mp4/track_run_iterator.h',
1069 'formats/mpeg/adts_constants.cc',
1070 'formats/mpeg/adts_constants.h',
1071 'formats/mpeg/adts_stream_parser.cc',
1072 'formats/mpeg/adts_stream_parser.h',
1073 'formats/mpeg/mpeg1_audio_stream_parser.cc',
1074 'formats/mpeg/mpeg1_audio_stream_parser.h',
1075 'formats/mpeg/mpeg_audio_stream_parser_base.cc',
1076 'formats/mpeg/mpeg_audio_stream_parser_base.h',
1079 ['target_arch=="ia32" or target_arch=="x64"', {
1085 'base/simd/convert_yuv_to_rgb_x86.cc',
1088 ['OS!="linux" and OS!="win"', {
1090 'base/keyboard_event_counter.cc',
1091 'base/keyboard_event_counter.h',
1094 ['use_low_memory_buffer==1', {
1096 'filters/source_buffer_platform.h',
1097 'filters/source_buffer_platform_lowmem.cc',
1099 }, { # 'use_low_memory_buffer==0'
1101 'filters/source_buffer_platform.cc',
1102 'filters/source_buffer_platform.h',
1107 '../device/udev_linux/udev.gyp:udev_linux',
1111 'target_conditions': [
1112 ['OS == "ios" and _toolset != "host"', {
1114 # Pull in specific Mac files for iOS (which have been filtered out
1115 # by file name rules).
1116 ['include', '^base/mac/coremedia_glue\\.h$'],
1117 ['include', '^base/mac/coremedia_glue\\.mm$'],
1118 ['include', '^base/mac/corevideo_glue\\.h$'],
1119 ['include', '^base/mac/videotoolbox_glue\\.h$'],
1120 ['include', '^base/mac/videotoolbox_glue\\.mm$'],
1121 ['include', '^base/mac/video_frame_mac\\.h$'],
1122 ['include', '^base/mac/video_frame_mac\\.cc$'],
1125 ], # target_conditions
1128 # GN version: //media:media_unittests
1129 'target_name': 'media_unittests',
1130 'type': '<(gtest_target_type)',
1133 'media_test_support',
1134 'shared_memory_support',
1135 '../base/base.gyp:base',
1136 '../base/base.gyp:base_i18n',
1137 '../base/base.gyp:test_support_base',
1138 '../gpu/gpu.gyp:command_buffer_common',
1139 '../skia/skia.gyp:skia',
1140 '../testing/gmock.gyp:gmock',
1141 '../testing/gtest.gyp:gtest',
1142 '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
1143 '../ui/gfx/gfx.gyp:gfx',
1144 '../ui/gfx/gfx.gyp:gfx_geometry',
1145 '../ui/gfx/gfx.gyp:gfx_test_support',
1146 '../url/url.gyp:url_lib',
1149 'audio/alsa/alsa_output_unittest.cc',
1150 'audio/android/audio_android_unittest.cc',
1151 'audio/audio_input_controller_unittest.cc',
1152 'audio/audio_input_unittest.cc',
1153 'audio/audio_input_volume_unittest.cc',
1154 'audio/audio_low_latency_input_output_unittest.cc',
1155 'audio/audio_manager_unittest.cc',
1156 'audio/audio_output_controller_unittest.cc',
1157 'audio/audio_output_device_unittest.cc',
1158 'audio/audio_output_proxy_unittest.cc',
1159 'audio/audio_parameters_unittest.cc',
1160 'audio/audio_power_monitor_unittest.cc',
1161 'audio/fake_audio_worker_unittest.cc',
1162 'audio/mac/audio_auhal_mac_unittest.cc',
1163 'audio/mac/audio_device_listener_mac_unittest.cc',
1164 'audio/mac/audio_low_latency_input_mac_unittest.cc',
1165 'audio/simple_sources_unittest.cc',
1166 'audio/sounds/audio_stream_handler_unittest.cc',
1167 'audio/sounds/sounds_manager_unittest.cc',
1168 'audio/sounds/test_data.cc',
1169 'audio/sounds/test_data.h',
1170 'audio/sounds/wav_audio_handler_unittest.cc',
1171 'audio/virtual_audio_input_stream_unittest.cc',
1172 'audio/virtual_audio_output_stream_unittest.cc',
1173 'audio/win/audio_device_listener_win_unittest.cc',
1174 'audio/win/audio_low_latency_input_win_unittest.cc',
1175 'audio/win/audio_low_latency_output_win_unittest.cc',
1176 'audio/win/audio_output_win_unittest.cc',
1177 'audio/win/core_audio_util_win_unittest.cc',
1178 'base/android/media_codec_bridge_unittest.cc',
1179 'base/android/media_drm_bridge_unittest.cc',
1180 'base/android/media_source_player_unittest.cc',
1181 'base/audio_block_fifo_unittest.cc',
1182 'base/audio_buffer_converter_unittest.cc',
1183 'base/audio_buffer_queue_unittest.cc',
1184 'base/audio_buffer_unittest.cc',
1185 'base/audio_bus_unittest.cc',
1186 'base/audio_converter_unittest.cc',
1187 'base/audio_discard_helper_unittest.cc',
1188 'base/audio_fifo_unittest.cc',
1189 'base/audio_hardware_config_unittest.cc',
1190 'base/audio_hash_unittest.cc',
1191 'base/audio_pull_fifo_unittest.cc',
1192 'base/audio_renderer_mixer_input_unittest.cc',
1193 'base/audio_renderer_mixer_unittest.cc',
1194 'base/audio_shifter_unittest.cc',
1195 'base/audio_splicer_unittest.cc',
1196 'base/audio_timestamp_helper_unittest.cc',
1197 'base/audio_video_metadata_extractor_unittest.cc',
1198 'base/bind_to_current_loop_unittest.cc',
1199 'base/bit_reader_unittest.cc',
1200 'base/callback_holder.h',
1201 'base/callback_holder_unittest.cc',
1202 'base/channel_mixer_unittest.cc',
1203 'base/channel_mixing_matrix_unittest.cc',
1204 'base/container_names_unittest.cc',
1205 'base/data_buffer_unittest.cc',
1206 'base/decoder_buffer_queue_unittest.cc',
1207 'base/decoder_buffer_unittest.cc',
1208 'base/djb2_unittest.cc',
1209 'base/gmock_callback_support_unittest.cc',
1210 'base/key_systems_unittest.cc',
1211 'base/mac/video_frame_mac_unittests.cc',
1212 'base/media_file_checker_unittest.cc',
1213 'base/multi_channel_resampler_unittest.cc',
1214 'base/pipeline_unittest.cc',
1215 'base/ranges_unittest.cc',
1216 'base/run_all_unittests.cc',
1217 'base/seekable_buffer_unittest.cc',
1218 'base/serial_runner_unittest.cc',
1219 'base/sinc_resampler_unittest.cc',
1220 'base/stream_parser_unittest.cc',
1221 'base/text_ranges_unittest.cc',
1222 'base/text_renderer_unittest.cc',
1223 'base/time_delta_interpolator_unittest.cc',
1224 'base/user_input_monitor_unittest.cc',
1225 'base/vector_math_testing.h',
1226 'base/vector_math_unittest.cc',
1227 'base/video_frame_pool_unittest.cc',
1228 'base/video_frame_unittest.cc',
1229 'base/video_util_unittest.cc',
1230 'base/wall_clock_time_source_unittest.cc',
1231 'base/yuv_convert_unittest.cc',
1232 'blink/skcanvas_video_renderer_unittest.cc',
1233 'cdm/aes_decryptor_unittest.cc',
1234 'cdm/cenc_utils_unittest.cc',
1235 'cdm/json_web_key_unittest.cc',
1236 'ffmpeg/ffmpeg_common_unittest.cc',
1237 'filters/audio_clock_unittest.cc',
1238 'filters/audio_decoder_selector_unittest.cc',
1239 'filters/audio_decoder_unittest.cc',
1240 'filters/audio_file_reader_unittest.cc',
1241 'filters/audio_renderer_algorithm_unittest.cc',
1242 'filters/blocking_url_protocol_unittest.cc',
1243 'filters/chunk_demuxer_unittest.cc',
1244 'filters/decrypting_audio_decoder_unittest.cc',
1245 'filters/decrypting_demuxer_stream_unittest.cc',
1246 'filters/decrypting_video_decoder_unittest.cc',
1247 'filters/fake_demuxer_stream.cc',
1248 'filters/fake_demuxer_stream.h',
1249 'filters/fake_demuxer_stream_unittest.cc',
1250 'filters/fake_video_decoder.cc',
1251 'filters/fake_video_decoder.h',
1252 'filters/fake_video_decoder_unittest.cc',
1253 'filters/ffmpeg_demuxer_unittest.cc',
1254 'filters/ffmpeg_glue_unittest.cc',
1255 'filters/ffmpeg_video_decoder_unittest.cc',
1256 'filters/file_data_source_unittest.cc',
1257 'filters/frame_processor_unittest.cc',
1258 'filters/h264_bit_reader_unittest.cc',
1259 'filters/h264_parser_unittest.cc',
1260 'filters/in_memory_url_protocol_unittest.cc',
1261 'filters/jpeg_parser_unittest.cc',
1262 'filters/source_buffer_stream_unittest.cc',
1263 'filters/video_decoder_selector_unittest.cc',
1264 'filters/video_frame_scheduler_impl_unittest.cc',
1265 'filters/video_frame_scheduler_unittest.cc',
1266 'filters/video_frame_stream_unittest.cc',
1267 'filters/vp8_bool_decoder_unittest.cc',
1268 'filters/vp8_parser_unittest.cc',
1269 'formats/common/offset_byte_queue_unittest.cc',
1270 'formats/webm/cluster_builder.cc',
1271 'formats/webm/cluster_builder.h',
1272 'formats/webm/opus_packet_builder.cc',
1273 'formats/webm/opus_packet_builder.h',
1274 'formats/webm/tracks_builder.cc',
1275 'formats/webm/tracks_builder.h',
1276 'formats/webm/webm_cluster_parser_unittest.cc',
1277 'formats/webm/webm_content_encodings_client_unittest.cc',
1278 'formats/webm/webm_parser_unittest.cc',
1279 'formats/webm/webm_tracks_parser_unittest.cc',
1280 'formats/webm/webm_webvtt_parser_unittest.cc',
1281 'midi/midi_manager_unittest.cc',
1282 'midi/midi_manager_usb_unittest.cc',
1283 'midi/midi_message_queue_unittest.cc',
1284 'midi/midi_message_util_unittest.cc',
1285 'midi/usb_midi_descriptor_parser_unittest.cc',
1286 'midi/usb_midi_input_stream_unittest.cc',
1287 'midi/usb_midi_output_stream_unittest.cc',
1288 'renderers/audio_renderer_impl_unittest.cc',
1289 'renderers/renderer_impl_unittest.cc',
1290 'renderers/video_renderer_impl_unittest.cc',
1291 'test/pipeline_integration_test.cc',
1292 'test/pipeline_integration_test_base.cc',
1293 'video/capture/fake_video_capture_device_unittest.cc',
1294 'video/capture/video_capture_device_unittest.cc',
1295 'video/h264_poc_unittest.cc',
1298 # Needed by media_drm_bridge.cc.
1299 '<(SHARED_INTERMEDIATE_DIR)',
1307 ['media_use_ffmpeg==1', {
1309 '../third_party/ffmpeg/ffmpeg.gyp:ffmpeg',
1311 }, { # media_use_ffmpeg== 0
1313 'base/audio_video_metadata_extractor_unittest.cc',
1314 'base/container_names_unittest.cc',
1315 'base/media_file_checker_unittest.cc',
1316 'ffmpeg/ffmpeg_common_unittest.cc',
1317 'filters/audio_decoder_unittest.cc',
1318 'filters/audio_file_reader_unittest.cc',
1319 'filters/blocking_url_protocol_unittest.cc',
1320 'filters/ffmpeg_aac_bitstream_converter_unittest.cc',
1321 'filters/ffmpeg_demuxer_unittest.cc',
1322 'filters/ffmpeg_glue_unittest.cc',
1323 'filters/ffmpeg_h264_to_annex_b_bitstream_converter_unittest.cc',
1324 'filters/ffmpeg_video_decoder_unittest.cc',
1325 'filters/in_memory_url_protocol_unittest.cc',
1326 'test/pipeline_integration_test.cc',
1327 'test/pipeline_integration_test_base.cc',
1335 ['use_pulseaudio==1', {
1340 ['os_posix==1 and OS!="mac"', {
1342 ['use_allocator!="none"', {
1344 '../base/allocator/allocator.gyp:allocator',
1351 'audio/audio_input_volume_unittest.cc',
1354 '../testing/android/native_test.gyp:native_test_native_code',
1362 'audio/cras/cras_input_unittest.cc',
1363 'audio/cras/cras_unified_unittest.cc',
1371 ['target_arch != "arm" and chromeos == 1 and use_x11 == 1', {
1373 'filters/h264_bitstream_buffer_unittest.cc',
1378 'audio/alsa/alsa_output_unittest.cc',
1379 'audio/audio_low_latency_input_output_unittest.cc',
1382 ['target_arch=="ia32" or target_arch=="x64"', {
1384 'base/simd/convert_rgb_to_yuv_unittest.cc',
1387 ['proprietary_codecs==1', {
1389 'filters/ffmpeg_aac_bitstream_converter_unittest.cc',
1390 'filters/ffmpeg_h264_to_annex_b_bitstream_converter_unittest.cc',
1391 'filters/h264_to_annex_b_bitstream_converter_unittest.cc',
1392 'formats/common/stream_parser_test_base.cc',
1393 'formats/common/stream_parser_test_base.h',
1394 'formats/mp2t/es_adapter_video_unittest.cc',
1395 'formats/mp2t/es_parser_adts_unittest.cc',
1396 'formats/mp2t/es_parser_h264_unittest.cc',
1397 'formats/mp2t/es_parser_mpeg1audio_unittest.cc',
1398 'formats/mp2t/es_parser_test_base.cc',
1399 'formats/mp2t/es_parser_test_base.h',
1400 'formats/mp2t/mp2t_stream_parser_unittest.cc',
1401 'formats/mp2t/timestamp_unroller_unittest.cc',
1402 'formats/mp4/aac_unittest.cc',
1403 'formats/mp4/avc_unittest.cc',
1404 'formats/mp4/box_reader_unittest.cc',
1405 'formats/mp4/es_descriptor_unittest.cc',
1406 'formats/mp4/mp4_stream_parser_unittest.cc',
1407 'formats/mp4/sample_to_group_iterator_unittest.cc',
1408 'formats/mp4/track_run_iterator_unittest.cc',
1409 'formats/mpeg/adts_stream_parser_unittest.cc',
1410 'formats/mpeg/mpeg1_audio_stream_parser_unittest.cc',
1413 # TODO(wolenetz): Fix size_t to int truncations in win64. See
1414 # http://crbug.com/171009
1415 ['OS=="win" and target_arch=="x64"', {
1416 'msvs_disabled_warnings': [ 4267, ],
1420 'midi/midi_manager_mac_unittest.cc',
1421 'video/capture/mac/video_capture_device_factory_mac_unittest.mm',
1426 'midi/midi_manager_alsa_unittest.cc',
1431 '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck',
1437 # GN version: //media:media_perftests
1438 'target_name': 'media_perftests',
1439 'type': '<(gtest_target_type)',
1441 '../base/base.gyp:test_support_base',
1442 '../testing/gmock.gyp:gmock',
1443 '../testing/gtest.gyp:gtest',
1444 '../testing/perf/perf_test.gyp:perf_test',
1445 '../ui/gfx/gfx.gyp:gfx',
1446 '../ui/gfx/gfx.gyp:gfx_test_support',
1447 '../ui/gfx/gfx.gyp:gfx_geometry',
1449 'media_test_support',
1450 'shared_memory_support',
1453 'base/audio_bus_perftest.cc',
1454 'base/audio_converter_perftest.cc',
1455 'base/demuxer_perftest.cc',
1456 'base/run_all_perftests.cc',
1457 'base/sinc_resampler_perftest.cc',
1458 'base/vector_math_perftest.cc',
1459 'base/yuv_convert_perftest.cc',
1460 'test/pipeline_integration_perftest.cc',
1461 'test/pipeline_integration_test_base.cc',
1471 '../testing/android/native_test.gyp:native_test_native_code',
1472 '../ui/gl/gl.gyp:gl',
1475 ['media_use_ffmpeg==1', {
1477 '../third_party/ffmpeg/ffmpeg.gyp:ffmpeg',
1479 }, { # media_use_ffmpeg==0
1481 'base/demuxer_perftest.cc',
1482 'test/pipeline_integration_perftest.cc',
1483 'test/pipeline_integration_test_base.cc',
1489 # GN versions (it is split apart): //media:test_support,
1490 # //media/base:test_support, and //media/audio:test_support
1491 'target_name': 'media_test_support',
1492 'type': 'static_library',
1495 'shared_memory_support',
1496 '../base/base.gyp:base',
1497 '../skia/skia.gyp:skia',
1498 '../testing/gmock.gyp:gmock',
1499 '../testing/gtest.gyp:gtest',
1502 'audio/audio_unittest_util.cc',
1503 'audio/audio_unittest_util.h',
1504 'audio/mock_audio_manager.cc',
1505 'audio/mock_audio_manager.h',
1506 'audio/mock_audio_source_callback.cc',
1507 'audio/mock_audio_source_callback.h',
1508 'audio/test_audio_input_controller_factory.cc',
1509 'audio/test_audio_input_controller_factory.h',
1510 'base/fake_audio_render_callback.cc',
1511 'base/fake_audio_render_callback.h',
1512 'base/fake_audio_renderer_sink.cc',
1513 'base/fake_audio_renderer_sink.h',
1514 'base/fake_text_track_stream.cc',
1515 'base/fake_text_track_stream.h',
1516 'base/gmock_callback_support.h',
1517 'base/mock_audio_renderer_sink.cc',
1518 'base/mock_audio_renderer_sink.h',
1519 'base/mock_demuxer_host.cc',
1520 'base/mock_demuxer_host.h',
1521 'base/mock_filters.cc',
1522 'base/mock_filters.h',
1523 'base/test_data_util.cc',
1524 'base/test_data_util.h',
1525 'base/test_helpers.cc',
1526 'base/test_helpers.h',
1527 'filters/clockless_video_frame_scheduler.cc',
1528 'filters/clockless_video_frame_scheduler.h',
1529 'filters/test_video_frame_scheduler.cc',
1530 'filters/test_video_frame_scheduler.h',
1531 'renderers/mock_gpu_video_accelerator_factories.cc',
1532 'renderers/mock_gpu_video_accelerator_factories.h',
1533 'video/mock_video_decode_accelerator.cc',
1534 'video/mock_video_decode_accelerator.h',
1538 # Minimal target for NaCl and other renderer side media clients which
1539 # only need to send audio data across the shared memory to the browser
1541 # GN version: //media:shared_memory_support
1542 'target_name': 'shared_memory_support',
1543 'type': '<(component)',
1545 '../base/base.gyp:base',
1548 'MEDIA_IMPLEMENTATION',
1554 'shared_memory_support.gypi',
1557 '<@(shared_memory_support_sources)',
1569 ['target_arch!="arm"', {
1572 'target_name': 'media_asm',
1573 'type': 'static_library',
1575 'base/simd/convert_rgb_to_yuv_ssse3.asm',
1576 'base/simd/convert_yuv_to_rgb_sse.asm',
1577 'base/simd/convert_yuva_to_argb_mmx.asm',
1578 'base/simd/empty_register_state_mmx.asm',
1579 'base/simd/linear_scale_yuv_to_rgb_mmx.asm',
1580 'base/simd/linear_scale_yuv_to_rgb_sse.asm',
1581 'base/simd/scale_yuv_to_rgb_mmx.asm',
1582 'base/simd/scale_yuv_to_rgb_sse.asm',
1585 ['component=="shared_library"', {
1587 'yasm_flags': ['-DEXPORT_SYMBOLS'],
1590 ['target_arch=="x64"', {
1591 # Source files optimized for X64 systems.
1593 'base/simd/linear_scale_yuv_to_rgb_mmx_x64.asm',
1594 'base/simd/scale_yuv_to_rgb_sse2_x64.asm',
1597 'yasm_flags': ['-DARCH_X86_64'],
1600 ['OS=="mac" or OS=="ios"', {
1608 # XCode doesn't want to link a pure assembly target and will
1609 # fail to link when it creates an empty file list. So add a
1610 # dummy file keep the linker happy. See http://crbug.com/157073
1611 'base/simd/xcode_hack.c',
1614 ['os_posix==1 and OS!="mac"', {
1617 ['target_arch=="ia32"', {
1622 }, { # target_arch=="x64"
1634 'yasm_output_path': '<(SHARED_INTERMEDIATE_DIR)/media',
1637 # In addition to the same path as source asm, let yasm %include
1638 # search path be relative to src/ per Chromium policy.
1642 '../third_party/x86inc/x86inc.asm',
1643 'base/simd/convert_rgb_to_yuv_ssse3.inc',
1644 'base/simd/convert_yuv_to_rgb_mmx.inc',
1645 'base/simd/convert_yuva_to_argb_mmx.inc',
1646 'base/simd/linear_scale_yuv_to_rgb_mmx.inc',
1647 'base/simd/media_export.asm',
1648 'base/simd/scale_yuv_to_rgb_mmx.inc',
1651 'msvs_2010_disable_uldi_when_referenced': 1,
1653 '../third_party/yasm/yasm_compile.gypi',
1657 'target_name': 'media_sse2',
1658 'type': 'static_library',
1663 'MEDIA_IMPLEMENTATION',
1669 'base/simd/convert_rgb_to_yuv_sse2.cc',
1670 'base/simd/convert_rgb_to_yuv_ssse3.cc',
1671 'base/simd/filter_yuv_sse2.cc',
1679 'target_name': 'player_x11',
1680 'type': 'executable',
1683 'shared_memory_support',
1684 '../base/base.gyp:base',
1685 '../ui/gl/gl.gyp:gl',
1686 '../ui/gfx/gfx.gyp:gfx',
1687 '../ui/gfx/gfx.gyp:gfx_geometry',
1688 '../build/linux/system.gyp:x11',
1689 '../build/linux/system.gyp:xext',
1690 '../build/linux/system.gyp:xrender',
1693 # Linux/Solaris need libdl for dlopen() and friends.
1694 ['OS=="linux" or OS=="solaris"', {
1703 'tools/player_x11/data_source_logger.cc',
1704 'tools/player_x11/data_source_logger.h',
1705 'tools/player_x11/gl_video_renderer.cc',
1706 'tools/player_x11/gl_video_renderer.h',
1707 'tools/player_x11/player_x11.cc',
1708 'tools/player_x11/x11_video_renderer.cc',
1709 'tools/player_x11/x11_video_renderer.h',
1718 'target_name': 'media_unittests_apk',
1725 'test_suite_name': 'media_unittests',
1727 'includes': ['../build/apk_test.gypi'],
1731 'target_name': 'media_perftests_apk',
1738 'test_suite_name': 'media_perftests',
1740 'includes': ['../build/apk_test.gypi'],
1743 # GN: //media/base/android:media_android_jni_headers
1744 'target_name': 'media_android_jni_headers',
1747 'base/android/java/src/org/chromium/media/AudioManagerAndroid.java',
1748 'base/android/java/src/org/chromium/media/AudioRecordInput.java',
1749 'base/android/java/src/org/chromium/media/MediaCodecBridge.java',
1750 'base/android/java/src/org/chromium/media/MediaDrmBridge.java',
1751 'base/android/java/src/org/chromium/media/MediaPlayerBridge.java',
1752 'base/android/java/src/org/chromium/media/MediaPlayerListener.java',
1753 'base/android/java/src/org/chromium/media/UsbMidiDeviceAndroid.java',
1754 'base/android/java/src/org/chromium/media/UsbMidiDeviceFactoryAndroid.java',
1755 'base/android/java/src/org/chromium/media/WebAudioMediaCodecBridge.java',
1758 'jni_gen_package': 'media',
1760 'includes': ['../build/jni_generator.gypi'],
1763 # GN: //media/base/android:video_capture_android_jni_headers
1764 'target_name': 'video_capture_android_jni_headers',
1767 'base/android/java/src/org/chromium/media/VideoCapture.java',
1768 'base/android/java/src/org/chromium/media/VideoCaptureFactory.java',
1771 'jni_gen_package': 'media',
1773 'includes': ['../build/jni_generator.gypi'],
1776 # GN: //media/base/android:android
1777 'target_name': 'player_android',
1778 'type': 'static_library',
1780 'base/android/audio_decoder_job.cc',
1781 'base/android/audio_decoder_job.h',
1782 'base/android/browser_cdm_factory_android.cc',
1783 'base/android/browser_cdm_factory_android.h',
1784 'base/android/demuxer_android.h',
1785 'base/android/demuxer_stream_player_params.cc',
1786 'base/android/demuxer_stream_player_params.h',
1787 'base/android/media_codec_bridge.cc',
1788 'base/android/media_codec_bridge.h',
1789 'base/android/media_common_android.h',
1790 'base/android/media_decoder_job.cc',
1791 'base/android/media_decoder_job.h',
1792 'base/android/media_drm_bridge.cc',
1793 'base/android/media_drm_bridge.h',
1794 'base/android/media_jni_registrar.cc',
1795 'base/android/media_jni_registrar.h',
1796 'base/android/media_player_android.cc',
1797 'base/android/media_player_android.h',
1798 'base/android/media_player_bridge.cc',
1799 'base/android/media_player_bridge.h',
1800 'base/android/media_player_listener.cc',
1801 'base/android/media_player_listener.h',
1802 'base/android/media_player_manager.h',
1803 'base/android/media_resource_getter.cc',
1804 'base/android/media_resource_getter.h',
1805 'base/android/media_source_player.cc',
1806 'base/android/media_source_player.h',
1807 'base/android/media_url_interceptor.h',
1808 'base/android/video_decoder_job.cc',
1809 'base/android/video_decoder_job.h',
1810 'base/android/webaudio_media_codec_bridge.cc',
1811 'base/android/webaudio_media_codec_bridge.h',
1812 'base/android/webaudio_media_codec_info.h',
1815 '../base/base.gyp:base',
1816 '../third_party/widevine/cdm/widevine_cdm.gyp:widevine_cdm_version_h',
1817 '../ui/gl/gl.gyp:gl',
1818 '../url/url.gyp:url_lib',
1819 'media_android_jni_headers',
1822 # Needed by media_drm_bridge.cc.
1823 '<(SHARED_INTERMEDIATE_DIR)',
1826 'MEDIA_IMPLEMENTATION',
1830 # GN: //media/base/android:media_java
1831 'target_name': 'media_java',
1834 '../base/base.gyp:base',
1835 'media_android_captureapitype',
1836 'media_android_imageformat',
1838 'export_dependent_settings': [
1839 '../base/base.gyp:base',
1842 'java_in_dir': 'base/android/java',
1844 'includes': ['../build/java.gypi'],
1847 # GN: //media/base/android:media_android_captureapitype
1848 'target_name': 'media_android_captureapitype',
1851 'source_file': 'video/capture/video_capture_device.h',
1853 'includes': [ '../build/android/java_cpp_enum.gypi' ],
1856 # GN: //media/base/android:media_android_imageformat
1857 'target_name': 'media_android_imageformat',
1860 'source_file': 'video/capture/android/video_capture_device_android.h',
1862 'includes': [ '../build/android/java_cpp_enum.gypi' ],
1866 ['media_use_ffmpeg==1', {
1869 # GN version: //media:ffmpeg_regression_tests
1870 'target_name': 'ffmpeg_regression_tests',
1871 'type': 'executable',
1873 '../base/base.gyp:test_support_base',
1874 '../testing/gmock.gyp:gmock',
1875 '../testing/gtest.gyp:gtest',
1876 '../third_party/ffmpeg/ffmpeg.gyp:ffmpeg',
1877 '../ui/gfx/gfx.gyp:gfx_geometry',
1879 'media_test_support',
1882 'base/run_all_unittests.cc',
1883 'ffmpeg/ffmpeg_regression_tests.cc',
1884 'test/pipeline_integration_test_base.cc',
1887 ['os_posix==1 and OS!="mac"', {
1889 ['use_allocator!="none"', {
1891 '../base/allocator/allocator.gyp:allocator',
1903 # Minimal media component for media/cast on iOS.
1904 # GN version: //media:media_for_cast_ios
1905 'target_name': 'media_for_cast_ios',
1906 'type': '<(component)',
1908 '../base/base.gyp:base',
1909 '../ui/gfx/gfx.gyp:gfx_geometry',
1910 'shared_memory_support',
1913 'MEDIA_DISABLE_FFMPEG',
1914 'MEDIA_DISABLE_LIBVPX',
1915 'MEDIA_FOR_CAST_IOS',
1916 'MEDIA_IMPLEMENTATION',
1918 'direct_dependent_settings': {
1920 'MEDIA_DISABLE_FFMPEG',
1921 'MEDIA_DISABLE_LIBVPX',
1931 'base/mac/coremedia_glue.h',
1932 'base/mac/coremedia_glue.mm',
1933 'base/mac/corevideo_glue.h',
1934 'base/mac/video_frame_mac.cc',
1935 'base/mac/video_frame_mac.h',
1936 'base/mac/videotoolbox_glue.h',
1937 'base/mac/videotoolbox_glue.mm',
1938 'base/simd/convert_rgb_to_yuv.h',
1939 'base/simd/convert_rgb_to_yuv_c.cc',
1940 'base/simd/convert_yuv_to_rgb.h',
1941 'base/simd/convert_yuv_to_rgb_c.cc',
1942 'base/simd/filter_yuv.h',
1943 'base/simd/filter_yuv_c.cc',
1944 'base/video_frame.cc',
1945 'base/video_frame.h',
1946 'base/video_frame_metadata.cc',
1947 'base/video_frame_metadata.h',
1948 'base/video_util.cc',
1949 'base/video_util.h',
1950 'base/yuv_convert.cc',
1951 'base/yuv_convert.h',
1955 '$(SDKROOT)/System/Library/Frameworks/CoreVideo.framework',
1965 'target_conditions': [
1966 ['OS == "ios" and _toolset != "host"', {
1968 # Pull in specific Mac files for iOS (which have been filtered
1969 # out by file name rules).
1970 ['include', '^base/mac/coremedia_glue\\.h$'],
1971 ['include', '^base/mac/coremedia_glue\\.mm$'],
1972 ['include', '^base/mac/corevideo_glue\\.h$'],
1973 ['include', '^base/mac/videotoolbox_glue\\.h$'],
1974 ['include', '^base/mac/videotoolbox_glue\\.mm$'],
1975 ['include', '^base/mac/video_frame_mac\\.h$'],
1976 ['include', '^base/mac/video_frame_mac\\.cc$'],
1979 ], # target_conditions
1983 ['test_isolation_mode != "noop"', {
1986 'target_name': 'media_unittests_run',
1992 '../build/isolate.gypi',
1995 'media_unittests.isolate',