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

Unified Diff: include/core/SkFixed.h

Issue 733163003: Switch SkBitmapProcState's SkFractionalInt to 32.32. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 1 month 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 | « no previous file | src/core/SkBitmapProcState.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkFixed.h
diff --git a/include/core/SkFixed.h b/include/core/SkFixed.h
index 488836c06035006a5c3630990697d74eb4c55c35..f3326618433dbaa060f5f950ea85d101489e27da 100644
--- a/include/core/SkFixed.h
+++ b/include/core/SkFixed.h
@@ -140,14 +140,14 @@ SkFixed SkFixedMul_portable(SkFixed, SkFixed);
///////////////////////////////////////////////////////////////////////////////
-typedef int64_t SkFixed48;
+typedef int64_t SkFixed3232; // 32.32
-#define SkIntToFixed48(x) ((SkFixed48)(x) << 48)
-#define SkFixed48ToInt(x) ((int)((x) >> 48))
-#define SkFixedToFixed48(x) ((SkFixed48)(x) << 32)
-#define SkFixed48ToFixed(x) ((SkFixed)((x) >> 32))
-#define SkFloatToFixed48(x) ((SkFixed48)((x) * (65536.0f * 65536.0f * 65536.0f)))
+#define SkIntToFixed3232(x) ((SkFixed3232)(x) << 32)
+#define SkFixed3232ToInt(x) ((int)((x) >> 32))
+#define SkFixedToFixed3232(x) ((SkFixed3232)(x) << 16)
+#define SkFixed3232ToFixed(x) ((SkFixed)((x) >> 16))
+#define SkFloatToFixed3232(x) ((SkFixed3232)((x) * (65536.0f * 65536.0f)))
-#define SkScalarToFixed48(x) SkFloatToFixed48(x)
+#define SkScalarToFixed3232(x) SkFloatToFixed3232(x)
#endif
« no previous file with comments | « no previous file | src/core/SkBitmapProcState.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698