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

Side by Side Diff: cc/render_pass.h

Issue 11618026: Move filters to RenderPassDrawQuad (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase 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
« no previous file with comments | « cc/layer_tree_host_impl_unittest.cc ('k') | cc/render_pass.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 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_H_ 5 #ifndef CC_RENDER_PASS_H_
6 #define CC_RENDER_PASS_H_ 6 #define CC_RENDER_PASS_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 void SetNew(Id id, 67 void SetNew(Id id,
68 gfx::Rect output_rect, 68 gfx::Rect output_rect,
69 gfx::RectF damage_rect, 69 gfx::RectF damage_rect,
70 const gfx::Transform& transform_to_root_target); 70 const gfx::Transform& transform_to_root_target);
71 71
72 void SetAll(Id id, 72 void SetAll(Id id,
73 gfx::Rect output_rect, 73 gfx::Rect output_rect,
74 gfx::RectF damage_rect, 74 gfx::RectF damage_rect,
75 const gfx::Transform& transform_to_root_target, 75 const gfx::Transform& transform_to_root_target,
76 bool has_transparent_background, 76 bool has_transparent_background,
77 bool has_occlusion_from_outside_target_surface, 77 bool has_occlusion_from_outside_target_surface);
78 const WebKit::WebFilterOperations& filters,
79 const skia::RefPtr<SkImageFilter>& filter,
80 const WebKit::WebFilterOperations& background_filters);
81 78
82 // Uniquely identifies the render pass in the compositor's current frame. 79 // Uniquely identifies the render pass in the compositor's current frame.
83 Id id; 80 Id id;
84 81
85 // These are in the space of the render pass' physical pixels. 82 // These are in the space of the render pass' physical pixels.
86 gfx::Rect output_rect; 83 gfx::Rect output_rect;
87 gfx::RectF damage_rect; 84 gfx::RectF damage_rect;
88 85
89 // Transforms from the origin of the |output_rect| to the origin of the root 86 // Transforms from the origin of the |output_rect| to the origin of the root
90 // render pass' |output_rect|. 87 // render pass' |output_rect|.
91 gfx::Transform transform_to_root_target; 88 gfx::Transform transform_to_root_target;
92 89
93 // If false, the pixels in the render pass' texture are all opaque. 90 // If false, the pixels in the render pass' texture are all opaque.
94 bool has_transparent_background; 91 bool has_transparent_background;
95 92
96 // If true, then there may be pixels in the render pass' texture that are not 93 // If true, then there may be pixels in the render pass' texture that are not
97 // complete, since they are occluded. 94 // complete, since they are occluded.
98 bool has_occlusion_from_outside_target_surface; 95 bool has_occlusion_from_outside_target_surface;
99 96
100 // Deprecated post-processing filters, applied to the pixels in the render
101 // pass' texture.
102 WebKit::WebFilterOperations filters;
103 // Post-processing filter applied to the pixels in the render pass' texture.
104 skia::RefPtr<SkImageFilter> filter;
105
106 // Post-processing filters, applied to the pixels showing through the
107 // background of the render pass, from behind it.
108 WebKit::WebFilterOperations background_filters;
109
110 QuadList quad_list; 97 QuadList quad_list;
111 SharedQuadStateList shared_quad_state_list; 98 SharedQuadStateList shared_quad_state_list;
112 99
113 protected: 100 protected:
114 RenderPass(); 101 RenderPass();
115 102
116 DISALLOW_COPY_AND_ASSIGN(RenderPass); 103 DISALLOW_COPY_AND_ASSIGN(RenderPass);
117 }; 104 };
118 105
119 } // namespace cc 106 } // namespace cc
(...skipping 12 matching lines...) Expand all
132 return hash<std::pair<int, int> >()( 119 return hash<std::pair<int, int> >()(
133 std::pair<int, int>(key.layer_id, key.index)); 120 std::pair<int, int>(key.layer_id, key.index));
134 } 121 }
135 }; 122 };
136 #else 123 #else
137 #error define a hash function for your compiler 124 #error define a hash function for your compiler
138 #endif // COMPILER 125 #endif // COMPILER
139 } 126 }
140 127
141 namespace cc { 128 namespace cc {
142 typedef std::vector<RenderPass*> RenderPassList; 129 typedef ScopedPtrVector<RenderPass> RenderPassList;
143 typedef ScopedPtrHashMap<RenderPass::Id, RenderPass> RenderPassIdHashMap; 130 typedef base::hash_map<RenderPass::Id, RenderPass*> RenderPassIdHashMap;
144 } // namespace cc 131 } // namespace cc
145 132
146 #endif // CC_RENDER_PASS_H_ 133 #endif // CC_RENDER_PASS_H_
OLDNEW
« no previous file with comments | « cc/layer_tree_host_impl_unittest.cc ('k') | cc/render_pass.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698