Move the DXVA decoder off the GPU thread.
[chromium-blink-merge.git] / cc / BUILD.gn
blob3c1f7bcb32b7a9afa0bde8e3c58d71dfa905991e
1 # Copyright 2014 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.
5 component("cc") {
6   sources = [
7     "animation/animation.cc",
8     "animation/animation.h",
9     "animation/animation_curve.cc",
10     "animation/animation_curve.h",
11     "animation/animation_delegate.h",
12     "animation/animation_events.cc",
13     "animation/animation_events.h",
14     "animation/animation_id_provider.cc",
15     "animation/animation_id_provider.h",
16     "animation/animation_registrar.cc",
17     "animation/animation_registrar.h",
18     "animation/keyframed_animation_curve.cc",
19     "animation/keyframed_animation_curve.h",
20     "animation/layer_animation_controller.cc",
21     "animation/layer_animation_controller.h",
22     "animation/layer_animation_event_observer.h",
23     "animation/layer_animation_value_observer.h",
24     "animation/layer_animation_value_provider.h",
25     "animation/scroll_offset_animation_curve.cc",
26     "animation/scroll_offset_animation_curve.h",
27     "animation/scrollbar_animation_controller.h",
28     "animation/scrollbar_animation_controller.cc",
29     "animation/scrollbar_animation_controller_linear_fade.cc",
30     "animation/scrollbar_animation_controller_linear_fade.h",
31     "animation/scrollbar_animation_controller_thinning.cc",
32     "animation/scrollbar_animation_controller_thinning.h",
33     "animation/timing_function.cc",
34     "animation/timing_function.h",
35     "animation/transform_operation.cc",
36     "animation/transform_operation.h",
37     "animation/transform_operations.cc",
38     "animation/transform_operations.h",
39     "base/completion_event.h",
40     "base/delayed_unique_notifier.cc",
41     "base/delayed_unique_notifier.h",
42     "base/invalidation_region.cc",
43     "base/invalidation_region.h",
44     "base/latency_info_swap_promise.cc",
45     "base/latency_info_swap_promise.h",
46     "base/latency_info_swap_promise_monitor.cc",
47     "base/latency_info_swap_promise_monitor.h",
48     "base/math_util.cc",
49     "base/math_util.h",
50     "base/ref_counted_managed.h",
51     "base/region.cc",
52     "base/region.h",
53     "base/rolling_time_delta_history.cc",
54     "base/rolling_time_delta_history.h",
55     "base/scoped_ptr_algorithm.h",
56     "base/scoped_ptr_deque.h",
57     "base/scoped_ptr_vector.h",
58     "base/simple_enclosed_region.cc",
59     "base/simple_enclosed_region.h",
60     "base/swap_promise.h",
61     "base/swap_promise_monitor.cc",
62     "base/swap_promise_monitor.h",
63     "base/switches.cc",
64     "base/switches.h",
65     "base/synced_property.h",
66     "base/tiling_data.cc",
67     "base/tiling_data.h",
68     "base/time_util.h",
69     "base/unique_notifier.cc",
70     "base/unique_notifier.h",
71     "base/util.h",
72     "debug/benchmark_instrumentation.cc",
73     "debug/benchmark_instrumentation.h",
74     "debug/debug_colors.cc",
75     "debug/debug_colors.h",
76     "debug/debug_rect_history.cc",
77     "debug/debug_rect_history.h",
78     "debug/devtools_instrumentation.h",
79     "debug/frame_rate_counter.cc",
80     "debug/frame_rate_counter.h",
81     "debug/frame_viewer_instrumentation.h",
82     "debug/invalidation_benchmark.cc",
83     "debug/invalidation_benchmark.h",
84     "debug/lap_timer.cc",
85     "debug/lap_timer.h",
86     "debug/layer_tree_debug_state.cc",
87     "debug/layer_tree_debug_state.h",
88     "debug/micro_benchmark.cc",
89     "debug/micro_benchmark.h",
90     "debug/micro_benchmark_impl.cc",
91     "debug/micro_benchmark_impl.h",
92     "debug/micro_benchmark_controller.cc",
93     "debug/micro_benchmark_controller.h",
94     "debug/micro_benchmark_controller_impl.cc",
95     "debug/micro_benchmark_controller_impl.h",
96     "debug/paint_time_counter.cc",
97     "debug/paint_time_counter.h",
98     "debug/picture_record_benchmark.cc",
99     "debug/picture_record_benchmark.h",
100     "debug/rasterize_and_record_benchmark.cc",
101     "debug/rasterize_and_record_benchmark.h",
102     "debug/rasterize_and_record_benchmark_impl.cc",
103     "debug/rasterize_and_record_benchmark_impl.h",
104     "debug/rendering_stats.cc",
105     "debug/rendering_stats.h",
106     "debug/rendering_stats_instrumentation.cc",
107     "debug/rendering_stats_instrumentation.h",
108     "debug/ring_buffer.h",
109     "debug/traced_picture.cc",
110     "debug/traced_picture.h",
111     "debug/traced_value.cc",
112     "debug/traced_value.h",
113     "debug/unittest_only_benchmark.cc",
114     "debug/unittest_only_benchmark.h",
115     "debug/unittest_only_benchmark_impl.cc",
116     "debug/unittest_only_benchmark_impl.h",
117     "input/input_handler.cc",
118     "input/input_handler.h",
119     "input/page_scale_animation.cc",
120     "input/page_scale_animation.h",
121     "input/layer_selection_bound.cc",
122     "input/layer_selection_bound.h",
123     "input/scroll_elasticity_helper.cc",
124     "input/scroll_elasticity_helper.h",
125     "input/selection_bound_type.h",
126     "input/top_controls_manager.cc",
127     "input/top_controls_manager.h",
128     "input/top_controls_manager_client.h",
129     "layers/append_quads_data.h",
130     "layers/content_layer.cc",
131     "layers/content_layer.h",
132     "layers/content_layer_client.h",
133     "layers/contents_scaling_layer.cc",
134     "layers/contents_scaling_layer.h",
135     "layers/delegated_frame_provider.cc",
136     "layers/delegated_frame_provider.h",
137     "layers/delegated_frame_resource_collection.cc",
138     "layers/delegated_frame_resource_collection.h",
139     "layers/delegated_renderer_layer.cc",
140     "layers/delegated_renderer_layer.h",
141     "layers/delegated_renderer_layer_impl.cc",
142     "layers/delegated_renderer_layer_impl.h",
143     "layers/draw_properties.h",
144     "layers/heads_up_display_layer.cc",
145     "layers/heads_up_display_layer.h",
146     "layers/heads_up_display_layer_impl.cc",
147     "layers/heads_up_display_layer_impl.h",
148     "layers/image_layer.cc",
149     "layers/image_layer.h",
150     "layers/io_surface_layer.cc",
151     "layers/io_surface_layer.h",
152     "layers/io_surface_layer_impl.cc",
153     "layers/io_surface_layer_impl.h",
154     "layers/layer.cc",
155     "layers/layer.h",
156     "layers/layer_client.h",
157     "layers/layer_impl.cc",
158     "layers/layer_impl.h",
159     "layers/layer_iterator.h",
160     "layers/layer_lists.cc",
161     "layers/layer_lists.h",
162     "layers/layer_position_constraint.cc",
163     "layers/layer_position_constraint.h",
164     "layers/layer_utils.cc",
165     "layers/layer_utils.h",
166     "layers/nine_patch_layer.cc",
167     "layers/nine_patch_layer.h",
168     "layers/nine_patch_layer_impl.cc",
169     "layers/nine_patch_layer_impl.h",
170     "layers/paint_properties.h",
171     "layers/painted_scrollbar_layer.cc",
172     "layers/painted_scrollbar_layer.h",
173     "layers/painted_scrollbar_layer_impl.cc",
174     "layers/painted_scrollbar_layer_impl.h",
175     "layers/picture_image_layer.cc",
176     "layers/picture_image_layer.h",
177     "layers/picture_image_layer_impl.cc",
178     "layers/picture_image_layer_impl.h",
179     "layers/picture_layer.cc",
180     "layers/picture_layer.h",
181     "layers/picture_layer_impl.cc",
182     "layers/picture_layer_impl.h",
183     "layers/render_pass_sink.h",
184     "layers/render_surface.cc",
185     "layers/render_surface.h",
186     "layers/render_surface_impl.cc",
187     "layers/render_surface_impl.h",
188     "layers/scrollbar_layer_impl_base.cc",
189     "layers/scrollbar_layer_impl_base.h",
190     "layers/scrollbar_layer_interface.h",
191     "layers/solid_color_layer.cc",
192     "layers/solid_color_layer.h",
193     "layers/solid_color_layer_impl.cc",
194     "layers/solid_color_layer_impl.h",
195     "layers/solid_color_scrollbar_layer.cc",
196     "layers/solid_color_scrollbar_layer.h",
197     "layers/solid_color_scrollbar_layer_impl.cc",
198     "layers/solid_color_scrollbar_layer_impl.h",
199     "layers/surface_layer.cc",
200     "layers/surface_layer.h",
201     "layers/surface_layer_impl.cc",
202     "layers/surface_layer_impl.h",
203     "layers/texture_layer.cc",
204     "layers/texture_layer.h",
205     "layers/texture_layer_client.h",
206     "layers/texture_layer_impl.cc",
207     "layers/texture_layer_impl.h",
208     "layers/tiled_layer.cc",
209     "layers/tiled_layer.h",
210     "layers/tiled_layer_impl.cc",
211     "layers/tiled_layer_impl.h",
212     "layers/ui_resource_layer.cc",
213     "layers/ui_resource_layer.h",
214     "layers/ui_resource_layer_impl.cc",
215     "layers/ui_resource_layer_impl.h",
216     "layers/video_frame_provider.h",
217     "layers/video_frame_provider_client_impl.cc",
218     "layers/video_frame_provider_client_impl.h",
219     "layers/video_layer.cc",
220     "layers/video_layer.h",
221     "layers/video_layer_impl.cc",
222     "layers/video_layer_impl.h",
223     "output/begin_frame_args.cc",
224     "output/begin_frame_args.h",
225     "output/bsp_tree.cc",
226     "output/bsp_tree.h",
227     "output/bsp_walk_action.cc",
228     "output/bsp_walk_action.h",
229     "output/compositor_frame.cc",
230     "output/compositor_frame.h",
231     "output/compositor_frame_ack.cc",
232     "output/compositor_frame_ack.h",
233     "output/compositor_frame_metadata.cc",
234     "output/compositor_frame_metadata.h",
235     "output/context_provider.cc",
236     "output/context_provider.h",
237     "output/copy_output_request.cc",
238     "output/copy_output_request.h",
239     "output/copy_output_result.cc",
240     "output/copy_output_result.h",
241     "output/delegated_frame_data.cc",
242     "output/delegated_frame_data.h",
243     "output/delegating_renderer.cc",
244     "output/delegating_renderer.h",
245     "output/direct_renderer.cc",
246     "output/direct_renderer.h",
247     "output/filter_operation.cc",
248     "output/filter_operation.h",
249     "output/filter_operations.cc",
250     "output/filter_operations.h",
251     "output/geometry_binding.cc",
252     "output/geometry_binding.h",
253     "output/gl_frame_data.cc",
254     "output/gl_frame_data.h",
255     "output/gl_renderer.cc",
256     "output/gl_renderer.h",
257     "output/gl_renderer_draw_cache.cc",
258     "output/gl_renderer_draw_cache.h",
259     "output/managed_memory_policy.cc",
260     "output/managed_memory_policy.h",
261     "output/output_surface.cc",
262     "output/output_surface.h",
263     "output/output_surface_client.h",
264     "output/overlay_candidate.cc",
265     "output/overlay_candidate.h",
266     "output/overlay_candidate_validator.h",
267     "output/overlay_processor.cc",
268     "output/overlay_processor.h",
269     "output/overlay_strategy_single_on_top.cc",
270     "output/overlay_strategy_single_on_top.h",
271     "output/program_binding.cc",
272     "output/program_binding.h",
273     "output/render_surface_filters.cc",
274     "output/render_surface_filters.h",
275     "output/renderer.cc",
276     "output/renderer.h",
277     "output/renderer_settings.cc",
278     "output/renderer_settings.h",
279     "output/shader.cc",
280     "output/shader.h",
281     "output/software_frame_data.cc",
282     "output/software_frame_data.h",
283     "output/software_output_device.cc",
284     "output/software_output_device.h",
285     "output/software_renderer.cc",
286     "output/software_renderer.h",
287     "output/viewport_selection_bound.cc",
288     "output/viewport_selection_bound.h",
289     "output/vsync_parameter_observer.h",
290     "quads/checkerboard_draw_quad.cc",
291     "quads/checkerboard_draw_quad.h",
292     "quads/content_draw_quad_base.cc",
293     "quads/content_draw_quad_base.h",
294     "quads/debug_border_draw_quad.cc",
295     "quads/debug_border_draw_quad.h",
296     "quads/draw_polygon.cc",
297     "quads/draw_polygon.h",
298     "quads/draw_quad.cc",
299     "quads/draw_quad.h",
300     "quads/io_surface_draw_quad.cc",
301     "quads/io_surface_draw_quad.h",
302     "quads/largest_draw_quad.h",
303     "quads/largest_draw_quad.cc",
304     "quads/list_container.cc",
305     "quads/list_container.h",
306     "quads/picture_draw_quad.cc",
307     "quads/picture_draw_quad.h",
308     "quads/render_pass.cc",
309     "quads/render_pass.h",
310     "quads/render_pass_draw_quad.cc",
311     "quads/render_pass_draw_quad.h",
312     "quads/render_pass_id.cc",
313     "quads/render_pass_id.h",
314     "quads/shared_quad_state.cc",
315     "quads/shared_quad_state.h",
316     "quads/solid_color_draw_quad.cc",
317     "quads/solid_color_draw_quad.h",
318     "quads/stream_video_draw_quad.cc",
319     "quads/stream_video_draw_quad.h",
320     "quads/surface_draw_quad.cc",
321     "quads/surface_draw_quad.h",
322     "quads/texture_draw_quad.cc",
323     "quads/texture_draw_quad.h",
324     "quads/tile_draw_quad.cc",
325     "quads/tile_draw_quad.h",
326     "quads/yuv_video_draw_quad.cc",
327     "quads/yuv_video_draw_quad.h",
328     "resources/bitmap_content_layer_updater.cc",
329     "resources/bitmap_content_layer_updater.h",
330     "resources/bitmap_raster_worker_pool.cc",
331     "resources/bitmap_raster_worker_pool.h",
332     "resources/bitmap_skpicture_content_layer_updater.cc",
333     "resources/bitmap_skpicture_content_layer_updater.h",
334     "resources/clip_display_item.cc",
335     "resources/clip_display_item.h",
336     "resources/content_layer_updater.cc",
337     "resources/content_layer_updater.h",
338     "resources/display_item.cc",
339     "resources/display_item.h",
340     "resources/display_item_list.cc",
341     "resources/display_item_list.h",
342     "resources/display_list_raster_source.cc",
343     "resources/display_list_raster_source.h",
344     "resources/display_list_recording_source.cc",
345     "resources/display_list_recording_source.h",
346     "resources/drawing_display_item.cc",
347     "resources/drawing_display_item.h",
348     "resources/eviction_tile_priority_queue.cc",
349     "resources/eviction_tile_priority_queue.h",
350     "resources/filter_display_item.cc",
351     "resources/filter_display_item.h",
352     "resources/gpu_raster_worker_pool.cc",
353     "resources/gpu_raster_worker_pool.h",
354     "resources/image_layer_updater.cc",
355     "resources/image_layer_updater.h",
356     "resources/layer_painter.h",
357     "resources/layer_quad.cc",
358     "resources/layer_quad.h",
359     "resources/layer_tiling_data.cc",
360     "resources/layer_tiling_data.h",
361     "resources/layer_updater.cc",
362     "resources/layer_updater.h",
363     "resources/managed_tile_state.cc",
364     "resources/managed_tile_state.h",
365     "resources/memory_history.cc",
366     "resources/memory_history.h",
367     "resources/one_copy_raster_worker_pool.cc",
368     "resources/one_copy_raster_worker_pool.h",
369     "resources/picture.cc",
370     "resources/picture.h",
371     "resources/picture_layer_tiling.cc",
372     "resources/picture_layer_tiling.h",
373     "resources/picture_layer_tiling_set.cc",
374     "resources/picture_layer_tiling_set.h",
375     "resources/picture_pile.cc",
376     "resources/picture_pile.h",
377     "resources/picture_pile_impl.cc",
378     "resources/picture_pile_impl.h",
379     "resources/pixel_buffer_raster_worker_pool.cc",
380     "resources/pixel_buffer_raster_worker_pool.h",
381     "resources/platform_color.h",
382     "resources/prioritized_resource.cc",
383     "resources/prioritized_resource.h",
384     "resources/prioritized_resource_manager.cc",
385     "resources/prioritized_resource_manager.h",
386     "resources/priority_calculator.cc",
387     "resources/priority_calculator.h",
388     "resources/raster_buffer.cc",
389     "resources/raster_buffer.h",
390     "resources/raster_source.h",
391     "resources/raster_source_helper.cc",
392     "resources/raster_source_helper.h",
393     "resources/raster_tile_priority_queue.cc",
394     "resources/raster_tile_priority_queue.h",
395     "resources/raster_worker_pool.cc",
396     "resources/raster_worker_pool.h",
397     "resources/rasterizer.cc",
398     "resources/rasterizer.h",
399     "resources/release_callback.h",
400     "resources/resource.cc",
401     "resources/resource.h",
402     "resources/resource_format.cc",
403     "resources/resource_format.h",
404     "resources/resource_pool.cc",
405     "resources/resource_pool.h",
406     "resources/resource_provider.cc",
407     "resources/resource_provider.h",
408     "resources/resource_update.cc",
409     "resources/resource_update.h",
410     "resources/resource_update_controller.cc",
411     "resources/resource_update_controller.h",
412     "resources/resource_update_queue.cc",
413     "resources/resource_update_queue.h",
414     "resources/returned_resource.h",
415     "resources/scoped_gpu_raster.cc",
416     "resources/scoped_gpu_raster.h",
417     "resources/scoped_resource.cc",
418     "resources/scoped_resource.h",
419     "resources/scoped_ui_resource.cc",
420     "resources/scoped_ui_resource.h",
421     "resources/shared_bitmap.cc",
422     "resources/shared_bitmap.h",
423     "resources/shared_bitmap_manager.h",
424     "resources/single_release_callback.cc",
425     "resources/single_release_callback.h",
426     "resources/single_release_callback_impl.cc",
427     "resources/single_release_callback_impl.h",
428     "resources/skpicture_content_layer_updater.cc",
429     "resources/skpicture_content_layer_updater.h",
430     "resources/task_graph_runner.cc",
431     "resources/task_graph_runner.h",
432     "resources/texture_mailbox.cc",
433     "resources/texture_mailbox.h",
434     "resources/texture_mailbox_deleter.cc",
435     "resources/texture_mailbox_deleter.h",
436     "resources/texture_uploader.cc",
437     "resources/texture_uploader.h",
438     "resources/tile.cc",
439     "resources/tile.h",
440     "resources/tile_manager.cc",
441     "resources/tile_manager.h",
442     "resources/tile_priority.cc",
443     "resources/tile_priority.h",
444     "resources/tiling_set_eviction_queue.cc",
445     "resources/tiling_set_eviction_queue.h",
446     "resources/transferable_resource.cc",
447     "resources/transferable_resource.h",
448     "resources/transform_display_item.cc",
449     "resources/transform_display_item.h",
450     "resources/transparency_display_item.cc",
451     "resources/transparency_display_item.h",
452     "resources/ui_resource_bitmap.cc",
453     "resources/ui_resource_bitmap.h",
454     "resources/ui_resource_client.h",
455     "resources/ui_resource_request.cc",
456     "resources/ui_resource_request.h",
457     "resources/video_resource_updater.cc",
458     "resources/video_resource_updater.h",
459     "resources/zero_copy_raster_worker_pool.cc",
460     "resources/zero_copy_raster_worker_pool.h",
461     "scheduler/begin_frame_source.cc",
462     "scheduler/begin_frame_source.h",
463     "scheduler/delay_based_time_source.cc",
464     "scheduler/delay_based_time_source.h",
465     "scheduler/draw_result.h",
466     "scheduler/scheduler.cc",
467     "scheduler/scheduler.h",
468     "scheduler/scheduler_settings.cc",
469     "scheduler/scheduler_settings.h",
470     "scheduler/scheduler_state_machine.cc",
471     "scheduler/scheduler_state_machine.h",
472     "trees/blocking_task_runner.cc",
473     "trees/blocking_task_runner.h",
474     "trees/damage_tracker.cc",
475     "trees/damage_tracker.h",
476     "trees/layer_sorter.cc",
477     "trees/layer_sorter.h",
478     "trees/layer_tree_host.cc",
479     "trees/layer_tree_host.h",
480     "trees/layer_tree_host_client.h",
481     "trees/layer_tree_host_common.cc",
482     "trees/layer_tree_host_common.h",
483     "trees/layer_tree_host_impl.cc",
484     "trees/layer_tree_host_impl.h",
485     "trees/layer_tree_impl.cc",
486     "trees/layer_tree_impl.h",
487     "trees/layer_tree_settings.cc",
488     "trees/layer_tree_settings.h",
489     "trees/occlusion.cc",
490     "trees/occlusion.h",
491     "trees/occlusion_tracker.cc",
492     "trees/occlusion_tracker.h",
493     "trees/proxy.cc",
494     "trees/proxy.h",
495     "trees/proxy_timing_history.cc",
496     "trees/proxy_timing_history.h",
497     "trees/scoped_abort_remaining_swap_promises.h",
498     "trees/single_thread_proxy.cc",
499     "trees/single_thread_proxy.h",
500     "trees/thread_proxy.cc",
501     "trees/thread_proxy.h",
502     "trees/tree_synchronizer.cc",
503     "trees/tree_synchronizer.h",
504   ]
506   if (is_win) {
507     # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
508     cflags = [ "/wd4267" ]  # size_t -> int
509   }
511   public_deps = [
512     "//skia",
513   ]
514   deps = [
515     "//base",
516     "//base/third_party/dynamic_annotations",
517     "//cc/surfaces:surface_id",
518     "//gpu",
519     "//gpu/command_buffer/client:gles2_interface",
520     "//gpu/command_buffer/client:gpu_memory_buffer_manager",
521     "//media",
522     "//ui/events:events_base",
523     "//ui/gfx",
524     "//ui/gfx/geometry",
525   ]
527   defines = [ "CC_IMPLEMENTATION=1" ]
529   if (!is_debug && (is_win || is_android)) {
530     configs -= [ "//build/config/compiler:optimize" ]
531     configs += [ "//build/config/compiler:optimize_max" ]
532   }
535 source_set("test_support") {
536   testonly = true
537   sources = [
538     "test/animation_test_common.cc",
539     "test/animation_test_common.h",
540     "test/begin_frame_args_test.cc",
541     "test/begin_frame_args_test.h",
542     "test/fake_content_layer.cc",
543     "test/fake_content_layer.h",
544     "test/fake_content_layer_client.cc",
545     "test/fake_content_layer_client.h",
546     "test/fake_content_layer_impl.cc",
547     "test/fake_content_layer_impl.h",
548     "test/fake_delegated_renderer_layer.cc",
549     "test/fake_delegated_renderer_layer.h",
550     "test/fake_delegated_renderer_layer_impl.cc",
551     "test/fake_delegated_renderer_layer_impl.h",
552     "test/fake_impl_proxy.h",
553     "test/fake_layer_tree_host.cc",
554     "test/fake_layer_tree_host.h",
555     "test/fake_layer_tree_host_client.cc",
556     "test/fake_layer_tree_host_client.h",
557     "test/fake_layer_tree_host_impl.cc",
558     "test/fake_layer_tree_host_impl.h",
559     "test/fake_layer_tree_host_impl_client.cc",
560     "test/fake_layer_tree_host_impl_client.h",
561     "test/fake_output_surface.cc",
562     "test/fake_output_surface.h",
563     "test/fake_output_surface_client.cc",
564     "test/fake_output_surface_client.h",
565     "test/fake_painted_scrollbar_layer.cc",
566     "test/fake_painted_scrollbar_layer.h",
567     "test/fake_picture_layer.cc",
568     "test/fake_picture_layer.h",
569     "test/fake_picture_layer_impl.cc",
570     "test/fake_picture_layer_impl.h",
571     "test/fake_picture_layer_tiling_client.cc",
572     "test/fake_picture_layer_tiling_client.h",
573     "test/fake_picture_pile.cc",
574     "test/fake_picture_pile.h",
575     "test/fake_picture_pile_impl.cc",
576     "test/fake_picture_pile_impl.h",
577     "test/fake_proxy.cc",
578     "test/fake_proxy.h",
579     "test/fake_renderer_client.cc",
580     "test/fake_renderer_client.h",
581     "test/fake_rendering_stats_instrumentation.h",
582     "test/fake_scoped_ui_resource.cc",
583     "test/fake_scoped_ui_resource.h",
584     "test/fake_scrollbar.cc",
585     "test/fake_scrollbar.h",
586     "test/fake_tile_manager.cc",
587     "test/fake_tile_manager.h",
588     "test/fake_tile_manager_client.cc",
589     "test/fake_tile_manager_client.h",
590     "test/fake_ui_resource_layer_tree_host_impl.cc",
591     "test/fake_ui_resource_layer_tree_host_impl.h",
592     "test/fake_video_frame_provider.cc",
593     "test/fake_video_frame_provider.h",
594     "test/geometry_test_utils.cc",
595     "test/geometry_test_utils.h",
596     "test/test_in_process_context_provider.cc",
597     "test/test_in_process_context_provider.h",
598     "test/impl_side_painting_settings.h",
599     "test/layer_test_common.cc",
600     "test/layer_test_common.h",
601     "test/layer_tree_host_common_test.cc",
602     "test/layer_tree_host_common_test.h",
603     "test/layer_tree_json_parser.cc",
604     "test/layer_tree_json_parser.h",
605     "test/layer_tree_pixel_resource_test.cc",
606     "test/layer_tree_pixel_resource_test.h",
607     "test/layer_tree_pixel_test.cc",
608     "test/layer_tree_pixel_test.h",
609     "test/layer_tree_test.cc",
610     "test/layer_tree_test.h",
611     "test/mock_occlusion_tracker.h",
612     "test/ordered_simple_task_runner.cc",
613     "test/ordered_simple_task_runner.h",
614     "test/ordered_texture_map.cc",
615     "test/ordered_texture_map.h",
616     "test/paths.cc",
617     "test/paths.h",
618     "test/pixel_comparator.cc",
619     "test/pixel_comparator.h",
620     "test/pixel_test.cc",
621     "test/pixel_test.h",
622     "test/pixel_test_output_surface.cc",
623     "test/pixel_test_output_surface.h",
624     "test/pixel_test_software_output_device.cc",
625     "test/pixel_test_software_output_device.h",
626     "test/pixel_test_utils.cc",
627     "test/pixel_test_utils.h",
628     "test/render_pass_test_common.cc",
629     "test/render_pass_test_common.h",
630     "test/render_pass_test_utils.cc",
631     "test/render_pass_test_utils.h",
632     "test/scheduler_test_common.cc",
633     "test/scheduler_test_common.h",
634     "test/skia_common.cc",
635     "test/skia_common.h",
636     "test/solid_color_content_layer_client.cc",
637     "test/solid_color_content_layer_client.h",
638     "test/test_context_provider.cc",
639     "test/test_context_provider.h",
640     "test/test_context_support.cc",
641     "test/test_context_support.h",
642     "test/test_gles2_interface.cc",
643     "test/test_gles2_interface.h",
644     "test/test_gpu_memory_buffer_manager.cc",
645     "test/test_gpu_memory_buffer_manager.h",
646     "test/test_image_factory.cc",
647     "test/test_image_factory.h",
648     "test/test_now_source.cc",
649     "test/test_now_source.h",
650     "test/test_occlusion_tracker.h",
651     "test/test_shared_bitmap_manager.cc",
652     "test/test_shared_bitmap_manager.h",
653     "test/test_texture.cc",
654     "test/test_texture.h",
655     "test/test_tile_priorities.cc",
656     "test/test_tile_priorities.h",
657     "test/test_web_graphics_context_3d.cc",
658     "test/test_web_graphics_context_3d.h",
659     "test/tiled_layer_test_common.cc",
660     "test/tiled_layer_test_common.h",
661   ]
663   include_dirs = [
664     ".",
665     "test",
666   ]
668   public_deps = [
669     ":cc",
670     "//gpu:test_support",
671   ]
672   deps = [
673     "//base",
674     "//base/test:test_support",
675     "//base/third_party/dynamic_annotations",
676     "//gpu/command_buffer/client:gles2_c_lib",
677     "//gpu/command_buffer/client:gles2_implementation",
678     "//gpu/command_buffer/client:gpu_memory_buffer_manager",
679     "//gpu/command_buffer/client:gl_in_process_context",
680     "//gpu/command_buffer/common:gles2_utils",
681     "//gpu/skia_bindings",
682     "//media",
683     "//skia",
684     "//testing/gmock",
685     "//testing/gtest",
686     "//ui/gfx",
687     "//ui/gfx/geometry",
688     "//ui/gfx:test_support",
689     "//ui/gl",
690   ]
692   if (!is_android) {  # TODO(GYP) Enable on Android when osmesa links.
693     deps += [ "//third_party/mesa:osmesa" ]
694   }
697 test("cc_unittests") {
698   sources = [
699     "animation/animation_unittest.cc",
700     "animation/keyframed_animation_curve_unittest.cc",
701     "animation/layer_animation_controller_unittest.cc",
702     "animation/scroll_offset_animation_curve_unittest.cc",
703     "animation/scrollbar_animation_controller_linear_fade_unittest.cc",
704     "animation/scrollbar_animation_controller_thinning_unittest.cc",
705     "animation/transform_operations_unittest.cc",
706     "base/float_quad_unittest.cc",
707     "base/math_util_unittest.cc",
708     "base/region_unittest.cc",
709     "base/rolling_time_delta_history_unittest.cc",
710     "base/scoped_ptr_vector_unittest.cc",
711     "base/simple_enclosed_region_unittest.cc",
712     "base/tiling_data_unittest.cc",
713     "base/util_unittest.cc",
714     "debug/micro_benchmark_controller_unittest.cc",
715     "input/top_controls_manager_unittest.cc",
716     "layers/contents_scaling_layer_unittest.cc",
717     "layers/delegated_frame_provider_unittest.cc",
718     "layers/delegated_frame_resource_collection_unittest.cc",
719     "layers/delegated_renderer_layer_impl_unittest.cc",
720     "layers/delegated_renderer_layer_unittest.cc",
721     "layers/heads_up_display_unittest.cc",
722     "layers/heads_up_display_layer_impl_unittest.cc",
723     "layers/io_surface_layer_impl_unittest.cc",
724     "layers/layer_impl_unittest.cc",
725     "layers/layer_iterator_unittest.cc",
726     "layers/layer_position_constraint_unittest.cc",
727     "layers/layer_unittest.cc",
728     "layers/layer_utils_unittest.cc",
729     "layers/nine_patch_layer_impl_unittest.cc",
730     "layers/nine_patch_layer_unittest.cc",
731     "layers/painted_scrollbar_layer_impl_unittest.cc",
732     "layers/picture_image_layer_impl_unittest.cc",
733     "layers/picture_layer_impl_unittest.cc",
734     "layers/picture_layer_unittest.cc",
735     "layers/render_surface_unittest.cc",
736     "layers/render_surface_impl_unittest.cc",
737     "layers/scrollbar_layer_unittest.cc",
738     "layers/solid_color_layer_impl_unittest.cc",
739     "layers/solid_color_scrollbar_layer_impl_unittest.cc",
740     "layers/surface_layer_unittest.cc",
741     "layers/surface_layer_impl_unittest.cc",
742     "layers/texture_layer_unittest.cc",
743     "layers/texture_layer_impl_unittest.cc",
744     "layers/tiled_layer_impl_unittest.cc",
745     "layers/tiled_layer_unittest.cc",
746     "layers/ui_resource_layer_impl_unittest.cc",
747     "layers/ui_resource_layer_unittest.cc",
748     "layers/video_layer_impl_unittest.cc",
749     "output/begin_frame_args_unittest.cc",
750     "output/delegating_renderer_unittest.cc",
751     "output/filter_operations_unittest.cc",
752     "output/gl_renderer_unittest.cc",
753     "output/output_surface_unittest.cc",
754     "output/overlay_unittest.cc",
755     "output/renderer_pixeltest.cc",
756     "output/renderer_unittest.cc",
757     "output/shader_unittest.cc",
758     "output/software_renderer_unittest.cc",
759     "quads/draw_quad_unittest.cc",
760     "quads/list_container_unittest.cc",
761     "quads/render_pass_unittest.cc",
762     "resources/display_item_list_unittest.cc",
763     "resources/layer_quad_unittest.cc",
764     "resources/picture_layer_tiling_set_unittest.cc",
765     "resources/picture_layer_tiling_unittest.cc",
766     "resources/picture_pile_impl_unittest.cc",
767     "resources/picture_pile_unittest.cc",
768     "resources/picture_unittest.cc",
769     "resources/prioritized_resource_unittest.cc",
770     "resources/raster_worker_pool_unittest.cc",
771     "resources/resource_provider_unittest.cc",
772     "resources/resource_update_controller_unittest.cc",
773     "resources/scoped_resource_unittest.cc",
774     "resources/task_graph_runner_unittest.cc",
775     "resources/texture_mailbox_deleter_unittest.cc",
776     "resources/texture_uploader_unittest.cc",
777     "resources/tile_manager_unittest.cc",
778     "resources/tile_priority_unittest.cc",
779     "resources/video_resource_updater_unittest.cc",
780     "scheduler/begin_frame_source_unittest.cc",
781     "scheduler/delay_based_time_source_unittest.cc",
782     "scheduler/scheduler_state_machine_unittest.cc",
783     "scheduler/scheduler_unittest.cc",
784     "test/layer_tree_json_parser_unittest.cc",
785     "test/test_web_graphics_context_3d_unittest.cc",
786     "trees/blocking_task_runner_unittest.cc",
787     "trees/damage_tracker_unittest.cc",
788     "trees/layer_sorter_unittest.cc",
789     "trees/layer_tree_host_common_unittest.cc",
790     "trees/layer_tree_host_impl_unittest.cc",
791     "trees/layer_tree_host_pixeltest_blending.cc",
792     "trees/layer_tree_host_pixeltest_filters.cc",
793     "trees/layer_tree_host_pixeltest_masks.cc",
794     "trees/layer_tree_host_pixeltest_on_demand_raster.cc",
795     "trees/layer_tree_host_pixeltest_readback.cc",
796     "trees/layer_tree_host_pixeltest_synchronous.cc",
797     "trees/layer_tree_host_unittest.cc",
798     "trees/layer_tree_host_unittest_animation.cc",
799     "trees/layer_tree_host_unittest_context.cc",
800     "trees/layer_tree_host_unittest_copyrequest.cc",
801     "trees/layer_tree_host_unittest_damage.cc",
802     "trees/layer_tree_host_unittest_delegated.cc",
803     "trees/layer_tree_host_unittest_occlusion.cc",
804     "trees/layer_tree_host_unittest_no_message_loop.cc",
805     "trees/layer_tree_host_unittest_picture.cc",
806     "trees/layer_tree_host_unittest_proxy.cc",
807     "trees/layer_tree_host_unittest_scroll.cc",
808     "trees/layer_tree_host_unittest_video.cc",
809     "trees/layer_tree_impl_unittest.cc",
810     "trees/occlusion_tracker_unittest.cc",
811     "trees/occlusion_unittest.cc",
812     "trees/tree_synchronizer_unittest.cc",
814     # Surfaces test files.
815     "surfaces/surface_aggregator_test_helpers.cc",
816     "surfaces/surface_aggregator_test_helpers.h",
817     "surfaces/surface_aggregator_unittest.cc",
818     "surfaces/surface_unittest.cc",
819     "surfaces/surfaces_pixeltest.cc",
821     # Setup.
822     "test/run_all_unittests.cc",
823     "test/cc_test_suite.cc",
824   ]
826   deps = [
827     ":cc",
828     ":test_support",
829     "//base/test:test_support",
830     "//cc/surfaces",
831     "//cc/surfaces:surface_id",
832     "//gpu",
833     "//gpu:test_support",
834     "//gpu/command_buffer/client:gles2_interface",
835     "//gpu/command_buffer/common:gles2_utils",
836     "//media",
837     "//testing/gmock",
838     "//testing/gtest",
839     "//ui/events:events_base",
840     "//ui/gfx",
841     "//ui/gfx/geometry",
842     "//ui/gfx:test_support",
843     "//ui/gl",
844   ]
847 test("cc_perftests") {
848   sources = [
849     "layers/layer_perftest.cc",
850     "layers/picture_layer_impl_perftest.cc",
851     "resources/picture_layer_tiling_perftest.cc",
852     "resources/picture_pile_impl_perftest.cc",
853     "resources/raster_worker_pool_perftest.cc",
854     "resources/task_graph_runner_perftest.cc",
855     "resources/tile_manager_perftest.cc",
856     "test/cc_test_suite.cc",
857     "test/run_all_perftests.cc",
858     "trees/layer_tree_host_common_perftest.cc",
859     "trees/layer_tree_host_perftest.cc",
860     "trees/occlusion_tracker_perftest.cc",
861   ]
863   deps = [
864     ":cc",
865     ":test_support",
866     "//base",
867     "//base/test:test_support",
868     "//gpu",
869     "//gpu:test_support",
870     "//gpu/command_buffer/common:gles2_utils",
871     "//media",
872     "//skia",
873     "//testing/gmock",
874     "//testing/gtest",
875     "//testing/perf",
876     "//ui/gfx",
877     "//ui/gfx/geometry",
878     "//ui/gl",
879   ]