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

Side by Side Diff: cc/layers/tiled_layer_impl.cc

Issue 988693005: Chromium roll (https://codereview.chromium.org/976353002) (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: fixed bad android build patch Created 5 years, 9 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
« no previous file with comments | « cc/layers/picture_layer_unittest.cc ('k') | cc/output/gl_renderer.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 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 #include "cc/layers/tiled_layer_impl.h" 5 #include "cc/layers/tiled_layer_impl.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/strings/stringprintf.h" 8 #include "base/strings/stringprintf.h"
9 #include "base/trace_event/trace_event_argument.h" 9 #include "base/trace_event/trace_event_argument.h"
10 #include "cc/base/math_util.h" 10 #include "cc/base/math_util.h"
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 if (ShowDebugBorders()) { 234 if (ShowDebugBorders()) {
235 checker_color = 235 checker_color =
236 tile ? DebugColors::InvalidatedTileCheckerboardColor() 236 tile ? DebugColors::InvalidatedTileCheckerboardColor()
237 : DebugColors::EvictedTileCheckerboardColor(); 237 : DebugColors::EvictedTileCheckerboardColor();
238 } else { 238 } else {
239 checker_color = DebugColors::DefaultCheckerboardColor(); 239 checker_color = DebugColors::DefaultCheckerboardColor();
240 } 240 }
241 241
242 CheckerboardDrawQuad* checkerboard_quad = 242 CheckerboardDrawQuad* checkerboard_quad =
243 render_pass->CreateAndAppendDrawQuad<CheckerboardDrawQuad>(); 243 render_pass->CreateAndAppendDrawQuad<CheckerboardDrawQuad>();
244 checkerboard_quad->SetNew( 244 checkerboard_quad->SetNew(shared_quad_state, tile_rect,
245 shared_quad_state, tile_rect, visible_tile_rect, checker_color); 245 visible_tile_rect, checker_color, 1.f);
246 append_quads_data->num_missing_tiles++; 246 append_quads_data->num_missing_tiles++;
247 continue; 247 continue;
248 } 248 }
249 249
250 gfx::Rect tile_opaque_rect = contents_opaque() ? tile_rect : gfx::Rect(); 250 gfx::Rect tile_opaque_rect = contents_opaque() ? tile_rect : gfx::Rect();
251 251
252 // Keep track of how the top left has moved, so the texture can be 252 // Keep track of how the top left has moved, so the texture can be
253 // offset the same amount. 253 // offset the same amount.
254 gfx::Vector2d display_offset = tile_rect.origin() - display_rect.origin(); 254 gfx::Vector2d display_offset = tile_rect.origin() - display_rect.origin();
255 gfx::Vector2d texture_offset = 255 gfx::Vector2d texture_offset =
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
314 314
315 void TiledLayerImpl::ReleaseResources() { 315 void TiledLayerImpl::ReleaseResources() {
316 tiler_->reset(); 316 tiler_->reset();
317 } 317 }
318 318
319 const char* TiledLayerImpl::LayerTypeAsString() const { 319 const char* TiledLayerImpl::LayerTypeAsString() const {
320 return "cc::TiledLayerImpl"; 320 return "cc::TiledLayerImpl";
321 } 321 }
322 322
323 } // namespace cc 323 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/picture_layer_unittest.cc ('k') | cc/output/gl_renderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698