If an argument for from is invalid or the attribute 'from' is missing at all, the resulting drawing is wrong. This is caused by SVGAnimateElement::calculateFromAndToValues. It sets transformation from color to string if one argument is wrong/missing. A short try to fix this broke W3C tests animate-elem-40 -41 -60 -62 and -78. I tried to take the SVGColor of the valid argument, transformed it to a String (SVGColor::cssText()) and set it as new toValue/fromValue.
Maybe after bug 54800 is fixed, this is easy to fix as well.
Created attachment 139351 [details] Patch
Comment on attachment 139351 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=139351&action=review r=me > Source/WebCore/ChangeLog:8 > + Switch AnimatedColorAnimator to use the standard animateAdditveNumber() method, taking progress & repeatCount into account. animateAdditveNumber <- typo > Source/WebCore/svg/SVGAnimatedColor.cpp:94 > + animatedColor = ColorDistance::clampColor(static_cast<int>(animatedRed), static_cast<int>(animatedGreen), static_cast<int>(animatedBlue), static_cast<int>(animatedAlpha)); Is static_cast<int>(floatColor) really the correct rounding?
Created attachment 139352 [details] Patch v2
Committed r115564: <http://trac.webkit.org/changeset/115564>