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

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

Issue 1380653003: Mac Overlays: Allow SolidColor and Tile quads to be candidates for overlays. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@AllOrNothing2
Patch Set: Plumb allow_overlay Created 5 years, 2 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_CONTENT_DRAW_QUAD_BASE_H_ 5 #ifndef CC_QUADS_CONTENT_DRAW_QUAD_BASE_H_
6 #define CC_QUADS_CONTENT_DRAW_QUAD_BASE_H_ 6 #define CC_QUADS_CONTENT_DRAW_QUAD_BASE_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "cc/base/cc_export.h" 9 #include "cc/base/cc_export.h"
10 #include "cc/quads/draw_quad.h" 10 #include "cc/quads/draw_quad.h"
11 #include "ui/gfx/geometry/rect_f.h" 11 #include "ui/gfx/geometry/rect_f.h"
12 #include "ui/gfx/geometry/size.h" 12 #include "ui/gfx/geometry/size.h"
13 13
14 namespace gfx { 14 namespace gfx {
15 class Rect; 15 class Rect;
16 } 16 }
17 17
18 namespace cc { 18 namespace cc {
19 19
20 class CC_EXPORT ContentDrawQuadBase : public DrawQuad { 20 class CC_EXPORT ContentDrawQuadBase : public DrawQuad {
21 public: 21 public:
22 void SetNew(const SharedQuadState* shared_quad_state, 22 void SetNew(const SharedQuadState* shared_quad_state,
23 DrawQuad::Material material, 23 DrawQuad::Material material,
24 const gfx::Rect& rect, 24 const gfx::Rect& rect,
25 const gfx::Rect& opaque_rect, 25 const gfx::Rect& opaque_rect,
26 const gfx::Rect& visible_rect, 26 const gfx::Rect& visible_rect,
27 const gfx::RectF& tex_coord_rect, 27 const gfx::RectF& tex_coord_rect,
28 const gfx::Size& texture_size, 28 const gfx::Size& texture_size,
29 bool swizzle_contents, 29 bool swizzle_contents,
30 bool nearest_neighbor); 30 bool nearest_neighbor,
31 bool allow_overlay);
31 32
32 void SetAll(const SharedQuadState* shared_quad_state, 33 void SetAll(const SharedQuadState* shared_quad_state,
33 DrawQuad::Material material, 34 DrawQuad::Material material,
34 const gfx::Rect& rect, 35 const gfx::Rect& rect,
35 const gfx::Rect& opaque_rect, 36 const gfx::Rect& opaque_rect,
36 const gfx::Rect& visible_rect, 37 const gfx::Rect& visible_rect,
37 bool needs_blending, 38 bool needs_blending,
38 const gfx::RectF& tex_coord_rect, 39 const gfx::RectF& tex_coord_rect,
39 const gfx::Size& texture_size, 40 const gfx::Size& texture_size,
40 bool swizzle_contents, 41 bool swizzle_contents,
41 bool nearest_neighbor); 42 bool nearest_neighbor,
43 bool allow_overlay);
42 44
43 gfx::RectF tex_coord_rect; 45 gfx::RectF tex_coord_rect;
44 gfx::Size texture_size; 46 gfx::Size texture_size;
45 bool swizzle_contents; 47 bool swizzle_contents;
46 bool nearest_neighbor; 48 bool nearest_neighbor;
49 bool allow_overlay;
47 50
48 protected: 51 protected:
49 ContentDrawQuadBase(); 52 ContentDrawQuadBase();
50 ~ContentDrawQuadBase() override; 53 ~ContentDrawQuadBase() override;
51 void ExtendValue(base::trace_event::TracedValue* value) const override; 54 void ExtendValue(base::trace_event::TracedValue* value) const override;
52 }; 55 };
53 56
54 } // namespace cc 57 } // namespace cc
55 58
56 #endif // CC_QUADS_CONTENT_DRAW_QUAD_BASE_H_ 59 #endif // CC_QUADS_CONTENT_DRAW_QUAD_BASE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698