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

Side by Side Diff: cc/quads/tile_draw_quad.h

Issue 93663004: [#2] Pass gfx structs by const ref (gfx::Rect, gfx::RectF) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase to ToT, fix builds on non-linux platforms! Created 6 years, 11 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/quads/texture_draw_quad.cc ('k') | cc/quads/tile_draw_quad.cc » ('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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #ifndef CC_QUADS_TILE_DRAW_QUAD_H_ 5 #ifndef CC_QUADS_TILE_DRAW_QUAD_H_
6 #define CC_QUADS_TILE_DRAW_QUAD_H_ 6 #define CC_QUADS_TILE_DRAW_QUAD_H_
7 7
8 #include "cc/quads/content_draw_quad_base.h" 8 #include "cc/quads/content_draw_quad_base.h"
9 9
10 namespace cc { 10 namespace cc {
11 11
12 class CC_EXPORT TileDrawQuad : public ContentDrawQuadBase { 12 class CC_EXPORT TileDrawQuad : public ContentDrawQuadBase {
13 public: 13 public:
14 static scoped_ptr<TileDrawQuad> Create(); 14 static scoped_ptr<TileDrawQuad> Create();
15 virtual ~TileDrawQuad(); 15 virtual ~TileDrawQuad();
16 16
17 void SetNew(const SharedQuadState* shared_quad_state, 17 void SetNew(const SharedQuadState* shared_quad_state,
18 gfx::Rect rect, 18 const gfx::Rect& rect,
19 gfx::Rect opaque_rect, 19 const gfx::Rect& opaque_rect,
20 unsigned resource_id, 20 unsigned resource_id,
21 const gfx::RectF& tex_coord_rect, 21 const gfx::RectF& tex_coord_rect,
22 gfx::Size texture_size, 22 gfx::Size texture_size,
23 bool swizzle_contents); 23 bool swizzle_contents);
24 24
25 void SetAll(const SharedQuadState* shared_quad_state, 25 void SetAll(const SharedQuadState* shared_quad_state,
26 gfx::Rect rect, 26 const gfx::Rect& rect,
27 gfx::Rect opaque_rect, 27 const gfx::Rect& opaque_rect,
28 gfx::Rect visible_rect, 28 const gfx::Rect& visible_rect,
29 bool needs_blending, 29 bool needs_blending,
30 unsigned resource_id, 30 unsigned resource_id,
31 const gfx::RectF& tex_coord_rect, 31 const gfx::RectF& tex_coord_rect,
32 gfx::Size texture_size, 32 gfx::Size texture_size,
33 bool swizzle_contents); 33 bool swizzle_contents);
34 34
35 unsigned resource_id; 35 unsigned resource_id;
36 36
37 virtual void IterateResources(const ResourceIteratorCallback& callback) 37 virtual void IterateResources(const ResourceIteratorCallback& callback)
38 OVERRIDE; 38 OVERRIDE;
39 39
40 static const TileDrawQuad* MaterialCast(const DrawQuad*); 40 static const TileDrawQuad* MaterialCast(const DrawQuad*);
41 41
42 private: 42 private:
43 TileDrawQuad(); 43 TileDrawQuad();
44 virtual void ExtendValue(base::DictionaryValue* value) const OVERRIDE; 44 virtual void ExtendValue(base::DictionaryValue* value) const OVERRIDE;
45 }; 45 };
46 46
47 } // namespace cc 47 } // namespace cc
48 48
49 #endif // CC_QUADS_TILE_DRAW_QUAD_H_ 49 #endif // CC_QUADS_TILE_DRAW_QUAD_H_
OLDNEW
« no previous file with comments | « cc/quads/texture_draw_quad.cc ('k') | cc/quads/tile_draw_quad.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698