OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> | 2 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 : SVGAnimatedIntegerOptionalInteger(contextElement, SVGNames::orderAttr,
0, 0) | 56 : SVGAnimatedIntegerOptionalInteger(contextElement, SVGNames::orderAttr,
0, 0) |
57 { | 57 { |
58 } | 58 } |
59 }; | 59 }; |
60 | 60 |
61 SVGParsingError SVGAnimatedOrder::setBaseValueAsString(const String& value) | 61 SVGParsingError SVGAnimatedOrder::setBaseValueAsString(const String& value) |
62 { | 62 { |
63 SVGParsingError parseStatus = SVGAnimatedIntegerOptionalInteger::setBaseValu
eAsString(value); | 63 SVGParsingError parseStatus = SVGAnimatedIntegerOptionalInteger::setBaseValu
eAsString(value); |
64 | 64 |
65 ASSERT(contextElement()); | 65 ASSERT(contextElement()); |
66 if (parseStatus == NoError && (firstInteger()->baseValue()->value() < 1 || s
econdInteger()->baseValue()->value() < 1)) { | 66 if (parseStatus == SVGStatus::NoError && (firstInteger()->baseValue()->value
() < 1 || secondInteger()->baseValue()->value() < 1)) { |
67 contextElement()->document().accessSVGExtensions().reportWarning( | 67 contextElement()->document().accessSVGExtensions().reportWarning( |
68 "feConvolveMatrix: problem parsing order=\"" + value + "\"."); | 68 "feConvolveMatrix: problem parsing order=\"" + value + "\"."); |
69 } | 69 } |
70 return parseStatus; | 70 return parseStatus; |
71 } | 71 } |
72 | 72 |
73 inline SVGFEConvolveMatrixElement::SVGFEConvolveMatrixElement(Document& document
) | 73 inline SVGFEConvolveMatrixElement::SVGFEConvolveMatrixElement(Document& document
) |
74 : SVGFilterPrimitiveStandardAttributes(SVGNames::feConvolveMatrixTag, docume
nt) | 74 : SVGFilterPrimitiveStandardAttributes(SVGNames::feConvolveMatrixTag, docume
nt) |
75 , m_bias(SVGAnimatedNumber::create(this, SVGNames::biasAttr, SVGNumber::crea
te())) | 75 , m_bias(SVGAnimatedNumber::create(this, SVGNames::biasAttr, SVGNumber::crea
te())) |
76 , m_divisor(SVGAnimatedNumber::create(this, SVGNames::divisorAttr, SVGNumber
::create())) | 76 , m_divisor(SVGAnimatedNumber::create(this, SVGNames::divisorAttr, SVGNumber
::create())) |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 | 190 |
191 RefPtrWillBeRawPtr<FilterEffect> effect = FEConvolveMatrix::create(filter, | 191 RefPtrWillBeRawPtr<FilterEffect> effect = FEConvolveMatrix::create(filter, |
192 IntSize(orderXValue, orderYValue), divisorValue, | 192 IntSize(orderXValue, orderYValue), divisorValue, |
193 m_bias->currentValue()->value(), IntPoint(targetXValue, targetYValue), m
_edgeMode->currentValue()->enumValue(), | 193 m_bias->currentValue()->value(), IntPoint(targetXValue, targetYValue), m
_edgeMode->currentValue()->enumValue(), |
194 m_preserveAlpha->currentValue()->value(), m_kernelMatrix->currentValue()
->toFloatVector()); | 194 m_preserveAlpha->currentValue()->value(), m_kernelMatrix->currentValue()
->toFloatVector()); |
195 effect->inputEffects().append(input1); | 195 effect->inputEffects().append(input1); |
196 return effect.release(); | 196 return effect.release(); |
197 } | 197 } |
198 | 198 |
199 } // namespace blink | 199 } // namespace blink |
OLD | NEW |