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

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

Issue 723343002: Update from https://crrev.com/304121 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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/draw_quad_unittest.cc ('k') | cc/quads/picture_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 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_PICTURE_DRAW_QUAD_H_ 5 #ifndef CC_QUADS_PICTURE_DRAW_QUAD_H_
6 #define CC_QUADS_PICTURE_DRAW_QUAD_H_ 6 #define CC_QUADS_PICTURE_DRAW_QUAD_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
11 #include "cc/quads/content_draw_quad_base.h" 11 #include "cc/quads/content_draw_quad_base.h"
12 #include "cc/resources/picture_pile_impl.h" 12 #include "cc/resources/raster_source.h"
13 #include "ui/gfx/geometry/rect.h" 13 #include "ui/gfx/geometry/rect.h"
14 #include "ui/gfx/geometry/rect_f.h" 14 #include "ui/gfx/geometry/rect_f.h"
15 #include "ui/gfx/geometry/size.h" 15 #include "ui/gfx/geometry/size.h"
16 16
17 namespace cc { 17 namespace cc {
18 18
19 // Used for on-demand tile rasterization. 19 // Used for on-demand tile rasterization.
20 class CC_EXPORT PictureDrawQuad : public ContentDrawQuadBase { 20 class CC_EXPORT PictureDrawQuad : public ContentDrawQuadBase {
21 public: 21 public:
22 PictureDrawQuad(); 22 PictureDrawQuad();
23 ~PictureDrawQuad() override; 23 ~PictureDrawQuad() override;
24 24
25 void SetNew(const SharedQuadState* shared_quad_state, 25 void SetNew(const SharedQuadState* shared_quad_state,
26 const gfx::Rect& rect, 26 const gfx::Rect& rect,
27 const gfx::Rect& opaque_rect, 27 const gfx::Rect& opaque_rect,
28 const gfx::Rect& visible_rect, 28 const gfx::Rect& visible_rect,
29 const gfx::RectF& tex_coord_rect, 29 const gfx::RectF& tex_coord_rect,
30 const gfx::Size& texture_size, 30 const gfx::Size& texture_size,
31 ResourceFormat texture_format, 31 ResourceFormat texture_format,
32 const gfx::Rect& content_rect, 32 const gfx::Rect& content_rect,
33 float contents_scale, 33 float contents_scale,
34 scoped_refptr<PicturePileImpl> picture_pile); 34 scoped_refptr<RasterSource> raster_source);
35 35
36 void SetAll(const SharedQuadState* shared_quad_state, 36 void SetAll(const SharedQuadState* shared_quad_state,
37 const gfx::Rect& rect, 37 const gfx::Rect& rect,
38 const gfx::Rect& opaque_rect, 38 const gfx::Rect& opaque_rect,
39 const gfx::Rect& visible_rect, 39 const gfx::Rect& visible_rect,
40 bool needs_blending, 40 bool needs_blending,
41 const gfx::RectF& tex_coord_rect, 41 const gfx::RectF& tex_coord_rect,
42 const gfx::Size& texture_size, 42 const gfx::Size& texture_size,
43 ResourceFormat texture_format, 43 ResourceFormat texture_format,
44 const gfx::Rect& content_rect, 44 const gfx::Rect& content_rect,
45 float contents_scale, 45 float contents_scale,
46 scoped_refptr<PicturePileImpl> picture_pile); 46 scoped_refptr<RasterSource> raster_source);
47 47
48 gfx::Rect content_rect; 48 gfx::Rect content_rect;
49 float contents_scale; 49 float contents_scale;
50 scoped_refptr<PicturePileImpl> picture_pile; 50 scoped_refptr<RasterSource> raster_source;
51 ResourceFormat texture_format; 51 ResourceFormat texture_format;
52 52
53 void IterateResources(const ResourceIteratorCallback& callback) override; 53 void IterateResources(const ResourceIteratorCallback& callback) override;
54 54
55 static const PictureDrawQuad* MaterialCast(const DrawQuad* quad); 55 static const PictureDrawQuad* MaterialCast(const DrawQuad* quad);
56 56
57 private: 57 private:
58 void ExtendValue(base::debug::TracedValue* value) const override; 58 void ExtendValue(base::debug::TracedValue* value) const override;
59 }; 59 };
60 60
61 } // namespace cc 61 } // namespace cc
62 62
63 #endif // CC_QUADS_PICTURE_DRAW_QUAD_H_ 63 #endif // CC_QUADS_PICTURE_DRAW_QUAD_H_
OLDNEW
« no previous file with comments | « cc/quads/draw_quad_unittest.cc ('k') | cc/quads/picture_draw_quad.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698