| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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_OUTPUT_DIRECT_RENDERER_H_ | 5 #ifndef CC_OUTPUT_DIRECT_RENDERER_H_ |
| 6 #define CC_OUTPUT_DIRECT_RENDERER_H_ | 6 #define CC_OUTPUT_DIRECT_RENDERER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <unordered_map> | 9 #include <unordered_map> |
| 10 | 10 |
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 187 bool use_partial_swap_; | 187 bool use_partial_swap_; |
| 188 | 188 |
| 189 // TODO(danakj): Just use a vector of pairs here? Hash map is way overkill. | 189 // TODO(danakj): Just use a vector of pairs here? Hash map is way overkill. |
| 190 std::unordered_map<RenderPassId, | 190 std::unordered_map<RenderPassId, |
| 191 std::unique_ptr<ScopedResource>, | 191 std::unique_ptr<ScopedResource>, |
| 192 RenderPassIdHash> | 192 RenderPassIdHash> |
| 193 render_pass_textures_; | 193 render_pass_textures_; |
| 194 std::unordered_map<RenderPassId, TileDrawQuad, RenderPassIdHash> | 194 std::unordered_map<RenderPassId, TileDrawQuad, RenderPassIdHash> |
| 195 render_pass_bypass_quads_; | 195 render_pass_bypass_quads_; |
| 196 | 196 |
| 197 bool visible_; | 197 bool visible_ = false; |
| 198 | 198 |
| 199 // For use in coordinate conversion, this stores the output rect, viewport | 199 // For use in coordinate conversion, this stores the output rect, viewport |
| 200 // rect (= unflipped version of glViewport rect), the size of target | 200 // rect (= unflipped version of glViewport rect), the size of target |
| 201 // framebuffer, and the current window space viewport. During a draw, this | 201 // framebuffer, and the current window space viewport. During a draw, this |
| 202 // stores the values for the current render pass; in between draws, they | 202 // stores the values for the current render pass; in between draws, they |
| 203 // retain the values for the root render pass of the last draw. | 203 // retain the values for the root render pass of the last draw. |
| 204 gfx::Rect current_draw_rect_; | 204 gfx::Rect current_draw_rect_; |
| 205 gfx::Rect current_viewport_rect_; | 205 gfx::Rect current_viewport_rect_; |
| 206 gfx::Size current_surface_size_; | 206 gfx::Size current_surface_size_; |
| 207 gfx::Rect current_window_space_viewport_; | 207 gfx::Rect current_window_space_viewport_; |
| 208 | 208 |
| 209 private: | 209 private: |
| 210 bool initialized_ = false; | 210 bool initialized_ = false; |
| 211 gfx::Size enlarge_pass_texture_amount_; | 211 gfx::Size enlarge_pass_texture_amount_; |
| 212 | 212 |
| 213 DISALLOW_COPY_AND_ASSIGN(DirectRenderer); | 213 DISALLOW_COPY_AND_ASSIGN(DirectRenderer); |
| 214 }; | 214 }; |
| 215 | 215 |
| 216 } // namespace cc | 216 } // namespace cc |
| 217 | 217 |
| 218 #endif // CC_OUTPUT_DIRECT_RENDERER_H_ | 218 #endif // CC_OUTPUT_DIRECT_RENDERER_H_ |
| OLD | NEW |