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

Unified Diff: cc/quads/render_pass_draw_quad.h

Issue 659683002: Include mask texture size in RenderPassDrawQuad (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@update_mask_draw_quad_test
Patch Set: No ToEnclosedRect Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/quads/draw_quad_unittest.cc ('k') | cc/quads/render_pass_draw_quad.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/quads/render_pass_draw_quad.h
diff --git a/cc/quads/render_pass_draw_quad.h b/cc/quads/render_pass_draw_quad.h
index 587c7ece2d2cbf1122e2b0c1e0785cc785530b43..25417f624c95c74a7c8be2895520b2b97d5b67a0 100644
--- a/cc/quads/render_pass_draw_quad.h
+++ b/cc/quads/render_pass_draw_quad.h
@@ -25,7 +25,8 @@ class CC_EXPORT RenderPassDrawQuad : public DrawQuad {
const gfx::Rect& visible_rect,
RenderPassId render_pass_id,
ResourceProvider::ResourceId mask_resource_id,
- const gfx::RectF& mask_uv_rect,
+ const gfx::Vector2dF& mask_uv_scale,
+ const gfx::Size& mask_texture_size,
const FilterOperations& filters,
const gfx::Vector2dF& filters_scale,
const FilterOperations& background_filters);
@@ -37,14 +38,16 @@ class CC_EXPORT RenderPassDrawQuad : public DrawQuad {
bool needs_blending,
RenderPassId render_pass_id,
ResourceProvider::ResourceId mask_resource_id,
- const gfx::RectF& mask_uv_rect,
+ const gfx::Vector2dF& mask_uv_scale,
+ const gfx::Size& mask_texture_size,
const FilterOperations& filters,
const gfx::Vector2dF& filters_scale,
const FilterOperations& background_filters);
RenderPassId render_pass_id;
ResourceProvider::ResourceId mask_resource_id;
- gfx::RectF mask_uv_rect;
+ gfx::Vector2dF mask_uv_scale;
+ gfx::Size mask_texture_size;
// Post-processing filters, applied to the pixels in the render pass' texture.
FilterOperations filters;
@@ -59,6 +62,9 @@ class CC_EXPORT RenderPassDrawQuad : public DrawQuad {
// background of the render pass, from behind it.
FilterOperations background_filters;
+ // Helper function to generate the normalized uv rect.
+ gfx::RectF MaskUVRect() const;
+
virtual void IterateResources(const ResourceIteratorCallback& callback)
override;
« no previous file with comments | « cc/quads/draw_quad_unittest.cc ('k') | cc/quads/render_pass_draw_quad.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698