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

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

Issue 236313006: cc: Add initial GPU-to-GPU copy rasterizer implementation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: nits Created 6 years, 7 months 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 | Annotate | Revision Log
« no previous file with comments | « content/renderer/render_thread_impl.cc ('k') | ui/compositor/compositor_switches.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 command_line->HasSwitch(cc::switches::kUIShowReplicaScreenSpaceRects); 147 command_line->HasSwitch(cc::switches::kUIShowReplicaScreenSpaceRects);
148 settings.initial_debug_state.show_occluding_rects = 148 settings.initial_debug_state.show_occluding_rects =
149 command_line->HasSwitch(cc::switches::kUIShowOccludingRects); 149 command_line->HasSwitch(cc::switches::kUIShowOccludingRects);
150 settings.initial_debug_state.show_non_occluding_rects = 150 settings.initial_debug_state.show_non_occluding_rects =
151 command_line->HasSwitch(cc::switches::kUIShowNonOccludingRects); 151 command_line->HasSwitch(cc::switches::kUIShowNonOccludingRects);
152 152
153 settings.initial_debug_state.SetRecordRenderingStats( 153 settings.initial_debug_state.SetRecordRenderingStats(
154 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking)); 154 command_line->HasSwitch(cc::switches::kEnableGpuBenchmarking));
155 155
156 settings.impl_side_painting = IsUIImplSidePaintingEnabled(); 156 settings.impl_side_painting = IsUIImplSidePaintingEnabled();
157 settings.use_map_image = IsUIMapImageEnabled(); 157 settings.use_zero_copy = IsUIZeroCopyEnabled();
158 158
159 base::TimeTicks before_create = base::TimeTicks::Now(); 159 base::TimeTicks before_create = base::TimeTicks::Now();
160 if (!!g_compositor_thread) { 160 if (!!g_compositor_thread) {
161 host_ = cc::LayerTreeHost::CreateThreaded( 161 host_ = cc::LayerTreeHost::CreateThreaded(
162 this, 162 this,
163 g_shared_bitmap_manager, 163 g_shared_bitmap_manager,
164 settings, 164 settings,
165 g_compositor_thread->message_loop_proxy()); 165 g_compositor_thread->message_loop_proxy());
166 } else { 166 } else {
167 host_ = cc::LayerTreeHost::CreateSingleThreaded( 167 host_ = cc::LayerTreeHost::CreateSingleThreaded(
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 // CompositorObservers to be notified before starting another 472 // CompositorObservers to be notified before starting another
473 // draw cycle. 473 // draw cycle.
474 ScheduleDraw(); 474 ScheduleDraw();
475 } 475 }
476 FOR_EACH_OBSERVER(CompositorObserver, 476 FOR_EACH_OBSERVER(CompositorObserver,
477 observer_list_, 477 observer_list_,
478 OnCompositingEnded(this)); 478 OnCompositingEnded(this));
479 } 479 }
480 480
481 } // namespace ui 481 } // namespace ui
OLDNEW
« no previous file with comments | « content/renderer/render_thread_impl.cc ('k') | ui/compositor/compositor_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698