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

Side by Side Diff: cc/render_pass_draw_quad.h

Issue 11618026: Move filters to RenderPassDrawQuad (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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_RENDER_PASS_DRAW_QUAD_H_ 5 #ifndef CC_RENDER_PASS_DRAW_QUAD_H_
6 #define CC_RENDER_PASS_DRAW_QUAD_H_ 6 #define CC_RENDER_PASS_DRAW_QUAD_H_
7 7
8 #include <public/WebFilterOperations.h>
danakj 2012/12/19 21:22:52 use "third_party/WebKit/..."
piman 2012/12/19 21:50:00 Done.
8 #include "base/basictypes.h" 9 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
10 #include "cc/cc_export.h" 11 #include "cc/cc_export.h"
11 #include "cc/draw_quad.h" 12 #include "cc/draw_quad.h"
12 #include "cc/render_pass.h" 13 #include "cc/render_pass.h"
13 #include "cc/resource_provider.h" 14 #include "cc/resource_provider.h"
14 15
15 namespace cc { 16 namespace cc {
16 17
17 class CC_EXPORT RenderPassDrawQuad : public DrawQuad { 18 class CC_EXPORT RenderPassDrawQuad : public DrawQuad {
18 public: 19 public:
19 static scoped_ptr<RenderPassDrawQuad> Create(); 20 static scoped_ptr<RenderPassDrawQuad> Create();
20 21
21 void SetNew(const SharedQuadState* shared_quad_state, 22 void SetNew(const SharedQuadState* shared_quad_state,
22 gfx::Rect rect, 23 gfx::Rect rect,
23 RenderPass::Id render_pass_id, 24 RenderPass::Id render_pass_id,
24 bool is_replica, 25 bool is_replica,
25 ResourceProvider::ResourceId mask_resource_id, 26 ResourceProvider::ResourceId mask_resource_id,
26 gfx::Rect contents_changed_since_last_frame, 27 gfx::Rect contents_changed_since_last_frame,
27 gfx::RectF mask_uv_rect); 28 gfx::RectF mask_uv_rect,
29 const WebKit::WebFilterOperations& filters,
30 skia::RefPtr<SkImageFilter> filter,
31 const WebKit::WebFilterOperations& background_filters);
28 32
29 void SetAll(const SharedQuadState* shared_quad_state, 33 void SetAll(const SharedQuadState* shared_quad_state,
30 gfx::Rect rect, 34 gfx::Rect rect,
31 gfx::Rect opaque_rect, 35 gfx::Rect opaque_rect,
32 gfx::Rect visible_rect, 36 gfx::Rect visible_rect,
33 bool needs_blending, 37 bool needs_blending,
34 RenderPass::Id render_pass_id, 38 RenderPass::Id render_pass_id,
35 bool is_replica, 39 bool is_replica,
36 ResourceProvider::ResourceId mask_resource_id, 40 ResourceProvider::ResourceId mask_resource_id,
37 gfx::Rect contents_changed_since_last_frame, 41 gfx::Rect contents_changed_since_last_frame,
38 gfx::RectF mask_uv_rect); 42 gfx::RectF mask_uv_rect,
43 const WebKit::WebFilterOperations& filters,
44 skia::RefPtr<SkImageFilter> filter,
45 const WebKit::WebFilterOperations& background_filters);
39 46
40 scoped_ptr<RenderPassDrawQuad> Copy( 47 scoped_ptr<RenderPassDrawQuad> Copy(
41 const SharedQuadState* copied_shared_quad_state, 48 const SharedQuadState* copied_shared_quad_state,
42 RenderPass::Id copied_render_pass_id) const; 49 RenderPass::Id copied_render_pass_id) const;
43 50
44 RenderPass::Id render_pass_id; 51 RenderPass::Id render_pass_id;
45 bool is_replica; 52 bool is_replica;
46 ResourceProvider::ResourceId mask_resource_id; 53 ResourceProvider::ResourceId mask_resource_id;
47 gfx::Rect contents_changed_since_last_frame; 54 gfx::Rect contents_changed_since_last_frame;
48 gfx::RectF mask_uv_rect; 55 gfx::RectF mask_uv_rect;
49 56
57 // Deprecated post-processing filters, applied to the pixels in the render
58 // pass' texture.
59 WebKit::WebFilterOperations filters;
60 // Post-processing filter applied to the pixels in the render pass' texture.
61 skia::RefPtr<SkImageFilter> filter;
62
63 // Post-processing filters, applied to the pixels showing through the
64 // background of the render pass, from behind it.
65 WebKit::WebFilterOperations background_filters;
66
50 static const RenderPassDrawQuad* MaterialCast(const DrawQuad*); 67 static const RenderPassDrawQuad* MaterialCast(const DrawQuad*);
51 private: 68 private:
52 RenderPassDrawQuad(); 69 RenderPassDrawQuad();
53 }; 70 };
54 71
55 } 72 }
56 73
57 #endif // CC_RENDER_PASS_DRAW_QUAD_H_ 74 #endif // CC_RENDER_PASS_DRAW_QUAD_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698