Lines Matching refs:percent

402 unsigned SVGAnimationElement::calculateKeyTimesIndex(float percent) const
407 // cases we don't need to consider the last value, since |percent| is never
412 if (m_keyTimes[index] > percent)
418 float SVGAnimationElement::calculatePercentForSpline(float percent, unsigned splineIndex) const
426 return narrowPrecisionToFloat(bezier.solve(percent, solveEpsilon(duration.value())));
429 float SVGAnimationElement::calculatePercentFromKeyPoints(float percent) const
436 if (percent == 1)
439 unsigned index = calculateKeyTimesIndex(percent);
449 float keyPointPercent = (percent - fromPercent) / (toPercent - fromPercent);
458 float SVGAnimationElement::calculatePercentForFromTo(float percent) const
461 return percent > m_keyTimes[1] ? 1 : 0;
463 return percent;
466 void SVGAnimationElement::currentValuesFromKeyPoints(float percent, float& effectivePercent, String& from, String& to) const
471 effectivePercent = calculatePercentFromKeyPoints(percent);
477 void SVGAnimationElement::currentValuesForValuesAnimation(float percent, float& effectivePercent, String& from, String& to)
483 if (percent == 1 || valuesCount == 1) {
500 return currentValuesFromKeyPoints(percent, effectivePercent, from, to);
506 unsigned index = calculateKeyTimesIndex(percent);
509 index = static_cast<unsigned>(percent * valuesCount);
522 index = static_cast<unsigned>(floorf(percent * (valuesCount - 1)));
532 effectivePercent = (percent - fromPercent) / (toPercent - fromPercent);
597 void SVGAnimationElement::updateAnimation(float percent, unsigned repeatCount, SVGSMILElement* resultElement)
608 currentValuesForValuesAnimation(percent, effectivePercent, from, to);
617 effectivePercent = calculatePercentFromKeyPoints(percent);
619 effectivePercent = calculatePercentForSpline(percent, calculateKeyTimesIndex(percent));
621 effectivePercent = calculatePercentForFromTo(percent);
623 effectivePercent = percent;