From 9bf06c7581a762850bd0d25d9f44c52ab6065056 Mon Sep 17 00:00:00 2001 From: "danakj@chromium.org" Date: Fri, 7 Mar 2014 18:16:24 +0000 Subject: cc: Add visible_rect to Draw*Quad::SetNew(). Currently the visible_rect is implicitly set to the quad's |rect| value then later changed by the occlusion/culling code. Instead we want to compute this value up front and set it on the quad when the quad is created. So add it to the SetNew() method. Currently it should always be set to the same value as the |rect|. R=enne BUG=344962 Review URL: https://codereview.chromium.org/185563008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@255662 0039d316-1c4b-4281-b951-d872f2087c98 --- cc/quads/tile_draw_quad.cc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'cc/quads/tile_draw_quad.cc') diff --git a/cc/quads/tile_draw_quad.cc b/cc/quads/tile_draw_quad.cc index c17bb99..6e28607 100644 --- a/cc/quads/tile_draw_quad.cc +++ b/cc/quads/tile_draw_quad.cc @@ -24,12 +24,18 @@ scoped_ptr TileDrawQuad::Create() { void TileDrawQuad::SetNew(const SharedQuadState* shared_quad_state, const gfx::Rect& rect, const gfx::Rect& opaque_rect, + const gfx::Rect& visible_rect, unsigned resource_id, const gfx::RectF& tex_coord_rect, const gfx::Size& texture_size, bool swizzle_contents) { - ContentDrawQuadBase::SetNew(shared_quad_state, DrawQuad::TILED_CONTENT, rect, - opaque_rect, tex_coord_rect, texture_size, + ContentDrawQuadBase::SetNew(shared_quad_state, + DrawQuad::TILED_CONTENT, + rect, + opaque_rect, + visible_rect, + tex_coord_rect, + texture_size, swizzle_contents); this->resource_id = resource_id; } -- cgit v1.1