| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 EffectPaintPropertyNode_h | 5 #ifndef EffectPaintPropertyNode_h |
| 6 #define EffectPaintPropertyNode_h | 6 #define EffectPaintPropertyNode_h |
| 7 | 7 |
| 8 #include "cc/layers/layer.h" | 8 #include "cc/layers/layer.h" |
| 9 #include "platform/PlatformExport.h" | 9 #include "platform/PlatformExport.h" |
| 10 #include "platform/graphics/CompositorFilterOperations.h" | 10 #include "platform/graphics/CompositorFilterOperations.h" |
| 11 #include "platform/graphics/paint/ClipPaintPropertyNode.h" | 11 #include "platform/graphics/paint/ClipPaintPropertyNode.h" |
| 12 #include "platform/graphics/paint/TransformPaintPropertyNode.h" | 12 #include "platform/graphics/paint/TransformPaintPropertyNode.h" |
| 13 #include "wtf/PassRefPtr.h" | 13 #include "wtf/PassRefPtr.h" |
| 14 #include "wtf/RefCounted.h" | 14 #include "wtf/RefCounted.h" |
| 15 #include "wtf/RefPtr.h" | 15 #include "wtf/RefPtr.h" |
| 16 #include "wtf/text/WTFString.h" |
| 16 | 17 |
| 17 #include <iosfwd> | 18 #include <iosfwd> |
| 18 | 19 |
| 19 namespace blink { | 20 namespace blink { |
| 20 | 21 |
| 21 // Effect nodes are abstraction of isolated groups, along with optional effects | 22 // Effect nodes are abstraction of isolated groups, along with optional effects |
| 22 // that can be applied to the composited output of the group. | 23 // that can be applied to the composited output of the group. |
| 23 // | 24 // |
| 24 // The effect tree is rooted at a node with no parent. This root node should | 25 // The effect tree is rooted at a node with no parent. This root node should |
| 25 // not be modified. | 26 // not be modified. |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 // if an effect node has changed. It ignores changes of reference filters | 80 // if an effect node has changed. It ignores changes of reference filters |
| 80 // because SkImageFilter doesn't have an equality operator. | 81 // because SkImageFilter doesn't have an equality operator. |
| 81 bool operator==(const EffectPaintPropertyNode& o) const { | 82 bool operator==(const EffectPaintPropertyNode& o) const { |
| 82 return m_parent == o.m_parent && | 83 return m_parent == o.m_parent && |
| 83 m_localTransformSpace == o.m_localTransformSpace && | 84 m_localTransformSpace == o.m_localTransformSpace && |
| 84 m_outputClip == o.m_outputClip && m_opacity == o.m_opacity && | 85 m_outputClip == o.m_outputClip && m_opacity == o.m_opacity && |
| 85 m_filter.equalsIgnoringReferenceFilters(o.m_filter); | 86 m_filter.equalsIgnoringReferenceFilters(o.m_filter); |
| 86 } | 87 } |
| 87 #endif | 88 #endif |
| 88 | 89 |
| 90 String toString() const; |
| 91 |
| 89 private: | 92 private: |
| 90 EffectPaintPropertyNode( | 93 EffectPaintPropertyNode( |
| 91 PassRefPtr<const EffectPaintPropertyNode> parent, | 94 PassRefPtr<const EffectPaintPropertyNode> parent, |
| 92 PassRefPtr<const TransformPaintPropertyNode> localTransformSpace, | 95 PassRefPtr<const TransformPaintPropertyNode> localTransformSpace, |
| 93 PassRefPtr<const ClipPaintPropertyNode> outputClip, | 96 PassRefPtr<const ClipPaintPropertyNode> outputClip, |
| 94 CompositorFilterOperations filter, | 97 CompositorFilterOperations filter, |
| 95 float opacity) | 98 float opacity) |
| 96 : m_parent(parent), | 99 : m_parent(parent), |
| 97 m_localTransformSpace(localTransformSpace), | 100 m_localTransformSpace(localTransformSpace), |
| 98 m_outputClip(outputClip), | 101 m_outputClip(outputClip), |
| (...skipping 26 matching lines...) Expand all Loading... |
| 125 mutable scoped_refptr<cc::Layer> m_dummyLayer; | 128 mutable scoped_refptr<cc::Layer> m_dummyLayer; |
| 126 }; | 129 }; |
| 127 | 130 |
| 128 // Redeclared here to avoid ODR issues. | 131 // Redeclared here to avoid ODR issues. |
| 129 // See platform/testing/PaintPrinters.h. | 132 // See platform/testing/PaintPrinters.h. |
| 130 void PrintTo(const EffectPaintPropertyNode&, std::ostream*); | 133 void PrintTo(const EffectPaintPropertyNode&, std::ostream*); |
| 131 | 134 |
| 132 } // namespace blink | 135 } // namespace blink |
| 133 | 136 |
| 134 #endif // EffectPaintPropertyNode_h | 137 #endif // EffectPaintPropertyNode_h |
| OLD | NEW |