aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkScalar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkScalar.cpp')
-rw-r--r--src/core/SkScalar.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/SkScalar.cpp b/src/core/SkScalar.cpp
index c48d3890ad..e8f6e93348 100644
--- a/src/core/SkScalar.cpp
+++ b/src/core/SkScalar.cpp
@@ -31,6 +31,6 @@ SkScalar SkScalarInterpFunc(SkScalar searchKey, const SkScalar keys[],
// Otherwise, interpolate between right - 1 and right.
SkScalar rightKey = keys[right];
SkScalar leftKey = keys[right-1];
- SkScalar fract = SkScalarDiv(searchKey-leftKey,rightKey-leftKey);
+ SkScalar fract = (searchKey - leftKey) / (rightKey - leftKey);
return SkScalarInterp(values[right-1], values[right], fract);
}