Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(29)

Unified Diff: include/private/SkFloatingPoint.h

Issue 1783583003: Add SkScalarTruncToScalar and speed up SkScalarFraction. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/core/SkScalar.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/private/SkFloatingPoint.h
diff --git a/include/private/SkFloatingPoint.h b/include/private/SkFloatingPoint.h
index efaf4109f1fa06891ab03d2b45209d7a0640abb2..6ed6144d184b3bc5673eb457897b9d195d25e85e 100644
--- a/include/private/SkFloatingPoint.h
+++ b/include/private/SkFloatingPoint.h
@@ -35,6 +35,7 @@ static inline float sk_float_pow(float base, float exp) {
#define sk_float_tan(x) tanf(x)
#define sk_float_floor(x) floorf(x)
#define sk_float_ceil(x) ceilf(x)
+#define sk_float_trunc(x) truncf(x)
#ifdef SK_BUILD_FOR_MAC
# define sk_float_acos(x) static_cast<float>(acos(x))
# define sk_float_asin(x) static_cast<float>(asin(x))
« no previous file with comments | « include/core/SkScalar.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698