Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(88)

Side by Side Diff: ui/compositor/compositor.cc

Issue 1413153014: Add a flag for enabling compositor property trees (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 #include "ui/compositor/compositor.h" 5 #include "ui/compositor/compositor.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <deque> 8 #include <deque>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 settings.initial_debug_state.show_surface_damage_rects = 128 settings.initial_debug_state.show_surface_damage_rects =
129 command_line->HasSwitch(cc::switches::kUIShowSurfaceDamageRects); 129 command_line->HasSwitch(cc::switches::kUIShowSurfaceDamageRects);
130 settings.initial_debug_state.show_screen_space_rects = 130 settings.initial_debug_state.show_screen_space_rects =
131 command_line->HasSwitch(cc::switches::kUIShowScreenSpaceRects); 131 command_line->HasSwitch(cc::switches::kUIShowScreenSpaceRects);
132 settings.initial_debug_state.show_replica_screen_space_rects = 132 settings.initial_debug_state.show_replica_screen_space_rects =
133 command_line->HasSwitch(cc::switches::kUIShowReplicaScreenSpaceRects); 133 command_line->HasSwitch(cc::switches::kUIShowReplicaScreenSpaceRects);
134 134
135 settings.initial_debug_state.SetRecordRenderingStats( 135 settings.initial_debug_state.SetRecordRenderingStats(
136 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking)); 136 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking));
137 137
138 settings.use_property_trees =
139 command_line->HasSwitch(cc::switches::kEnableCompositorPropertyTrees);
138 settings.use_zero_copy = IsUIZeroCopyEnabled(); 140 settings.use_zero_copy = IsUIZeroCopyEnabled();
139 141
140 settings.renderer_settings.use_rgba_4444_textures = 142 settings.renderer_settings.use_rgba_4444_textures =
141 command_line->HasSwitch(switches::kUIEnableRGBA4444Textures); 143 command_line->HasSwitch(switches::kUIEnableRGBA4444Textures);
142 144
143 // UI compositor always uses partial raster if not using zero-copy. Zero copy 145 // UI compositor always uses partial raster if not using zero-copy. Zero copy
144 // doesn't currently support partial raster. 146 // doesn't currently support partial raster.
145 settings.use_partial_raster = !settings.use_zero_copy; 147 settings.use_partial_raster = !settings.use_zero_copy;
146 148
147 // Use CPU_READ_WRITE_PERSISTENT memory buffers to support partial tile 149 // Use CPU_READ_WRITE_PERSISTENT memory buffers to support partial tile
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
492 observer_list_, 494 observer_list_,
493 OnCompositingLockStateChanged(this)); 495 OnCompositingLockStateChanged(this));
494 } 496 }
495 497
496 void Compositor::CancelCompositorLock() { 498 void Compositor::CancelCompositorLock() {
497 if (compositor_lock_) 499 if (compositor_lock_)
498 compositor_lock_->CancelLock(); 500 compositor_lock_->CancelLock();
499 } 501 }
500 502
501 } // namespace ui 503 } // namespace ui
OLDNEW
« cc/base/switches.h ('K') | « content/renderer/gpu/render_widget_compositor.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698