OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> |
3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "core/svg/SVGFEGaussianBlurElement.h" | 23 #include "core/svg/SVGFEGaussianBlurElement.h" |
24 | 24 |
25 #include "SVGNames.h" | 25 #include "SVGNames.h" |
26 #include "platform/graphics/filters/FilterEffect.h" | 26 #include "platform/graphics/filters/FilterEffect.h" |
27 #include "core/svg/SVGElementInstance.h" | 27 #include "core/svg/SVGElementInstance.h" |
28 #include "core/svg/SVGParserUtilities.h" | 28 #include "core/svg/SVGParserUtilities.h" |
29 #include "core/svg/graphics/filters/SVGFilterBuilder.h" | 29 #include "core/svg/graphics/filters/SVGFilterBuilder.h" |
30 | 30 |
31 namespace WebCore { | 31 namespace WebCore { |
32 | 32 |
33 // Animated property definitions | |
34 | |
35 BEGIN_REGISTER_ANIMATED_PROPERTIES(SVGFEGaussianBlurElement) | |
36 REGISTER_PARENT_ANIMATED_PROPERTIES(SVGFilterPrimitiveStandardAttributes) | |
37 END_REGISTER_ANIMATED_PROPERTIES | |
38 | |
39 inline SVGFEGaussianBlurElement::SVGFEGaussianBlurElement(Document& document) | 33 inline SVGFEGaussianBlurElement::SVGFEGaussianBlurElement(Document& document) |
40 : SVGFilterPrimitiveStandardAttributes(SVGNames::feGaussianBlurTag, document
) | 34 : SVGFilterPrimitiveStandardAttributes(SVGNames::feGaussianBlurTag, document
) |
41 , m_stdDeviation(SVGAnimatedNumberOptionalNumber::create(this, SVGNames::std
DeviationAttr, 0, 0)) | 35 , m_stdDeviation(SVGAnimatedNumberOptionalNumber::create(this, SVGNames::std
DeviationAttr, 0, 0)) |
42 , m_in1(SVGAnimatedString::create(this, SVGNames::inAttr, SVGString::create(
))) | 36 , m_in1(SVGAnimatedString::create(this, SVGNames::inAttr, SVGString::create(
))) |
43 { | 37 { |
44 ScriptWrappable::init(this); | 38 ScriptWrappable::init(this); |
45 | 39 |
46 addToPropertyMap(m_stdDeviation); | 40 addToPropertyMap(m_stdDeviation); |
47 addToPropertyMap(m_in1); | 41 addToPropertyMap(m_in1); |
48 } | 42 } |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 | 108 |
115 if (stdDeviationX()->currentValue()->value() < 0 || stdDeviationY()->current
Value()->value() < 0) | 109 if (stdDeviationX()->currentValue()->value() < 0 || stdDeviationY()->current
Value()->value() < 0) |
116 return nullptr; | 110 return nullptr; |
117 | 111 |
118 RefPtr<FilterEffect> effect = FEGaussianBlur::create(filter, stdDeviationX()
->currentValue()->value(), stdDeviationY()->currentValue()->value()); | 112 RefPtr<FilterEffect> effect = FEGaussianBlur::create(filter, stdDeviationX()
->currentValue()->value(), stdDeviationY()->currentValue()->value()); |
119 effect->inputEffects().append(input1); | 113 effect->inputEffects().append(input1); |
120 return effect.release(); | 114 return effect.release(); |
121 } | 115 } |
122 | 116 |
123 } | 117 } |
OLD | NEW |