OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CC_TREES_LAYER_TREE_SETTINGS_H_ | 5 #ifndef CC_TREES_LAYER_TREE_SETTINGS_H_ |
6 #define CC_TREES_LAYER_TREE_SETTINGS_H_ | 6 #define CC_TREES_LAYER_TREE_SETTINGS_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
11 #include "cc/base/cc_export.h" | 11 #include "cc/base/cc_export.h" |
12 #include "cc/debug/layer_tree_debug_state.h" | 12 #include "cc/debug/layer_tree_debug_state.h" |
13 #include "cc/output/managed_memory_policy.h" | 13 #include "cc/output/managed_memory_policy.h" |
14 #include "cc/output/renderer_settings.h" | 14 #include "cc/output/renderer_settings.h" |
15 #include "cc/scheduler/scheduler_settings.h" | 15 #include "cc/scheduler/scheduler_settings.h" |
16 #include "third_party/skia/include/core/SkColor.h" | 16 #include "third_party/skia/include/core/SkColor.h" |
17 #include "ui/gfx/geometry/size.h" | 17 #include "ui/gfx/geometry/size.h" |
18 | 18 |
19 namespace cc { | 19 namespace cc { |
20 | 20 |
| 21 namespace proto { |
| 22 class LayerTreeSettings; |
| 23 } // namespace proto |
| 24 |
21 class CC_EXPORT LayerTreeSettings { | 25 class CC_EXPORT LayerTreeSettings { |
22 public: | 26 public: |
23 LayerTreeSettings(); | 27 LayerTreeSettings(); |
24 virtual ~LayerTreeSettings(); | 28 virtual ~LayerTreeSettings(); |
25 | 29 |
| 30 bool operator==(const LayerTreeSettings& other) const; |
| 31 |
| 32 void ToProtobuf(proto::LayerTreeSettings* proto) const; |
| 33 void FromProtobuf(const proto::LayerTreeSettings& proto); |
| 34 |
| 35 SchedulerSettings ToSchedulerSettings() const; |
| 36 |
26 RendererSettings renderer_settings; | 37 RendererSettings renderer_settings; |
27 bool single_thread_proxy_scheduler; | 38 bool single_thread_proxy_scheduler; |
28 bool use_external_begin_frame_source; | 39 bool use_external_begin_frame_source; |
29 bool main_frame_before_activation_enabled; | 40 bool main_frame_before_activation_enabled; |
30 bool using_synchronous_renderer_compositor; | 41 bool using_synchronous_renderer_compositor; |
31 bool accelerated_animation_enabled; | 42 bool accelerated_animation_enabled; |
32 bool can_use_lcd_text; | 43 bool can_use_lcd_text; |
33 bool use_distance_field_text; | 44 bool use_distance_field_text; |
34 bool gpu_rasterization_enabled; | 45 bool gpu_rasterization_enabled; |
35 bool gpu_rasterization_forced; | 46 bool gpu_rasterization_forced; |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 bool use_occlusion_for_tile_prioritization; | 84 bool use_occlusion_for_tile_prioritization; |
74 bool verify_property_trees; | 85 bool verify_property_trees; |
75 bool use_property_trees; | 86 bool use_property_trees; |
76 bool image_decode_tasks_enabled; | 87 bool image_decode_tasks_enabled; |
77 bool use_compositor_animation_timelines; | 88 bool use_compositor_animation_timelines; |
78 bool wait_for_beginframe_interval; | 89 bool wait_for_beginframe_interval; |
79 int max_staging_buffer_usage_in_bytes; | 90 int max_staging_buffer_usage_in_bytes; |
80 ManagedMemoryPolicy memory_policy_; | 91 ManagedMemoryPolicy memory_policy_; |
81 | 92 |
82 LayerTreeDebugState initial_debug_state; | 93 LayerTreeDebugState initial_debug_state; |
83 | |
84 SchedulerSettings ToSchedulerSettings() const; | |
85 }; | 94 }; |
86 | 95 |
87 } // namespace cc | 96 } // namespace cc |
88 | 97 |
89 #endif // CC_TREES_LAYER_TREE_SETTINGS_H_ | 98 #endif // CC_TREES_LAYER_TREE_SETTINGS_H_ |
OLD | NEW |