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_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ | 5 #ifndef CC_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ |
6 #define CC_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ | 6 #define CC_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ |
7 | 7 |
8 #include "base/containers/hash_tables.h" | 8 #include "base/containers/hash_tables.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" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 void SetRenderPasses( | 70 void SetRenderPasses( |
71 ScopedPtrVector<RenderPass>* render_passes_in_draw_order); | 71 ScopedPtrVector<RenderPass>* render_passes_in_draw_order); |
72 void ClearRenderPasses(); | 72 void ClearRenderPasses(); |
73 | 73 |
74 // Returns |true| if the delegated_render_pass_id is part of the current | 74 // Returns |true| if the delegated_render_pass_id is part of the current |
75 // frame and can be converted. | 75 // frame and can be converted. |
76 bool ConvertDelegatedRenderPassId( | 76 bool ConvertDelegatedRenderPassId( |
77 RenderPass::Id delegated_render_pass_id, | 77 RenderPass::Id delegated_render_pass_id, |
78 RenderPass::Id* output_render_pass_id) const; | 78 RenderPass::Id* output_render_pass_id) const; |
79 | 79 |
80 gfx::Transform DelegatedFrameToLayerSpaceTransform( | |
81 const gfx::Size& frame_size) const; | |
82 | |
83 void AppendRenderPassQuads( | 80 void AppendRenderPassQuads( |
84 QuadSink* quad_sink, | 81 QuadSink* quad_sink, |
85 AppendQuadsData* append_quads_data, | 82 AppendQuadsData* append_quads_data, |
86 const RenderPass* delegated_render_pass, | 83 const RenderPass* delegated_render_pass, |
87 const gfx::Size& frame_size) const; | 84 const gfx::Size& frame_size) const; |
88 | 85 |
89 // LayerImpl overrides. | 86 // LayerImpl overrides. |
90 virtual const char* LayerTypeAsString() const OVERRIDE; | 87 virtual const char* LayerTypeAsString() const OVERRIDE; |
91 | 88 |
92 bool have_render_passes_to_push_; | 89 bool have_render_passes_to_push_; |
93 ScopedPtrVector<RenderPass> render_passes_in_draw_order_; | 90 ScopedPtrVector<RenderPass> render_passes_in_draw_order_; |
94 base::hash_map<RenderPass::Id, int> render_passes_index_by_id_; | 91 base::hash_map<RenderPass::Id, int> render_passes_index_by_id_; |
95 ResourceProvider::ResourceIdArray resources_; | 92 ResourceProvider::ResourceIdArray resources_; |
96 | 93 |
97 gfx::Size display_size_; | 94 gfx::Size display_size_; |
98 int child_id_; | 95 int child_id_; |
99 bool own_child_id_; | 96 bool own_child_id_; |
100 | 97 |
101 DISALLOW_COPY_AND_ASSIGN(DelegatedRendererLayerImpl); | 98 DISALLOW_COPY_AND_ASSIGN(DelegatedRendererLayerImpl); |
102 }; | 99 }; |
103 | 100 |
104 } // namespace cc | 101 } // namespace cc |
105 | 102 |
106 #endif // CC_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ | 103 #endif // CC_LAYERS_DELEGATED_RENDERER_LAYER_IMPL_H_ |
OLD | NEW |