| 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_DRAW_PROPERTIES_H_ | 5 #ifndef CC_LAYERS_DRAW_PROPERTIES_H_ |
| 6 #define CC_LAYERS_DRAW_PROPERTIES_H_ | 6 #define CC_LAYERS_DRAW_PROPERTIES_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "ui/gfx/rect.h" | 9 #include "ui/gfx/rect.h" |
| 10 #include "ui/gfx/transform.h" | 10 #include "ui/gfx/transform.h" |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 descendants_can_clip_selves(false) {} | 30 descendants_can_clip_selves(false) {} |
| 31 | 31 |
| 32 // Transforms objects from content space to target surface space, where | 32 // Transforms objects from content space to target surface space, where |
| 33 // this layer would be drawn. | 33 // this layer would be drawn. |
| 34 gfx::Transform target_space_transform; | 34 gfx::Transform target_space_transform; |
| 35 | 35 |
| 36 // Transforms objects from content space to screen space (viewport space). | 36 // Transforms objects from content space to screen space (viewport space). |
| 37 gfx::Transform screen_space_transform; | 37 gfx::Transform screen_space_transform; |
| 38 | 38 |
| 39 // DrawProperties::opacity may be different than LayerType::opacity, | 39 // DrawProperties::opacity may be different than LayerType::opacity, |
| 40 // particularly in the case when a renderSurface re-parents the layer's | 40 // particularly in the case when a RenderSurface re-parents the layer's |
| 41 // opacity, or when opacity is compounded by the hierarchy. | 41 // opacity, or when opacity is compounded by the hierarchy. |
| 42 float opacity; | 42 float opacity; |
| 43 | 43 |
| 44 // xxx_is_animating flags are used to indicate whether the DrawProperties | 44 // xxx_is_animating flags are used to indicate whether the DrawProperties |
| 45 // are actually meaningful on the main thread. When the properties are | 45 // are actually meaningful on the main thread. When the properties are |
| 46 // animating, the main thread may not have the same values that are used | 46 // animating, the main thread may not have the same values that are used |
| 47 // to draw. | 47 // to draw. |
| 48 bool opacity_is_animating; | 48 bool opacity_is_animating; |
| 49 bool screen_space_opacity_is_animating; | 49 bool screen_space_opacity_is_animating; |
| 50 bool target_space_transform_is_animating; | 50 bool target_space_transform_is_animating; |
| 51 bool screen_space_transform_is_animating; | 51 bool screen_space_transform_is_animating; |
| 52 | 52 |
| 53 // True if the layer can use LCD text. | 53 // True if the layer can use LCD text. |
| 54 bool can_use_lcd_text; | 54 bool can_use_lcd_text; |
| 55 | 55 |
| 56 // True if the layer needs to be clipped by clipRect. | 56 // True if the layer needs to be clipped by clip_rect. |
| 57 bool is_clipped; | 57 bool is_clipped; |
| 58 | 58 |
| 59 // The layer whose coordinate space this layer draws into. This can be | 59 // The layer whose coordinate space this layer draws into. This can be |
| 60 // either the same layer (draw_properties_.render_target == this) or an | 60 // either the same layer (draw_properties_.render_target == this) or an |
| 61 // ancestor of this layer. | 61 // ancestor of this layer. |
| 62 LayerType* render_target; | 62 LayerType* render_target; |
| 63 | 63 |
| 64 // The surface that this layer and its subtree would contribute to. | 64 // The surface that this layer and its subtree would contribute to. |
| 65 scoped_ptr<RenderSurfaceType> render_surface; | 65 scoped_ptr<RenderSurfaceType> render_surface; |
| 66 | 66 |
| (...skipping 20 matching lines...) Expand all Loading... |
| 87 int num_descendants_that_draw_content; | 87 int num_descendants_that_draw_content; |
| 88 | 88 |
| 89 // If true, every descendant in the sub-tree can clip itself without the | 89 // If true, every descendant in the sub-tree can clip itself without the |
| 90 // need to use hardware sissoring or a new render target. | 90 // need to use hardware sissoring or a new render target. |
| 91 bool descendants_can_clip_selves; | 91 bool descendants_can_clip_selves; |
| 92 }; | 92 }; |
| 93 | 93 |
| 94 } // namespace cc | 94 } // namespace cc |
| 95 | 95 |
| 96 #endif // CC_LAYERS_DRAW_PROPERTIES_H_ | 96 #endif // CC_LAYERS_DRAW_PROPERTIES_H_ |
| OLD | NEW |