aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkScalar.h
diff options
context:
space:
mode:
authorGravatar Hal Canary <halcanary@google.com>2017-02-01 14:47:57 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-02-02 12:21:33 +0000
commit565da18f6e4a0f04dc836ce9d35f31bee31644f7 (patch)
tree851654163930903f0b3a45846703014324d92c32 /include/core/SkScalar.h
parent09a1c088b407b2cb04b7f41d71b227e7da4757a8 (diff)
SkScalar: delete code thqat doesn't compile.
Change-Id: I8a5c404d6151fca79af5c5a98d4b44924c0ade52 Reviewed-on: https://skia-review.googlesource.com/7882 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
Diffstat (limited to 'include/core/SkScalar.h')
-rw-r--r--include/core/SkScalar.h50
1 files changed, 0 insertions, 50 deletions
diff --git a/include/core/SkScalar.h b/include/core/SkScalar.h
index 922840fd1a..16e885850e 100644
--- a/include/core/SkScalar.h
+++ b/include/core/SkScalar.h
@@ -10,14 +10,6 @@
#include "../private/SkFloatingPoint.h"
-// TODO: move this sort of check into SkPostConfig.h
-#define SK_SCALAR_IS_DOUBLE 0
-#undef SK_SCALAR_IS_FLOAT
-#define SK_SCALAR_IS_FLOAT 1
-
-
-#if SK_SCALAR_IS_FLOAT
-
typedef float SkScalar;
#define SK_Scalar1 1.0f
@@ -56,48 +48,6 @@ typedef float SkScalar;
#define SkScalarLog(x) (float)sk_float_log(x)
#define SkScalarLog2(x) (float)sk_float_log2(x)
-#else // SK_SCALAR_IS_DOUBLE
-
-typedef double SkScalar;
-
-#define SK_Scalar1 1.0
-#define SK_ScalarHalf 0.5
-#define SK_ScalarSqrt2 1.414213562373095
-#define SK_ScalarPI 3.141592653589793
-#define SK_ScalarTanPIOver8 0.4142135623731
-#define SK_ScalarRoot2Over2 0.70710678118655
-#define SK_ScalarMax 1.7976931348623157+308
-#define SK_ScalarInfinity SK_DoubleInfinity
-#define SK_ScalarNegativeInfinity SK_DoubleNegativeInfinity
-#define SK_ScalarNaN SK_DoubleNaN
-
-#define SkScalarFloorToScalar(x) floor(x)
-#define SkScalarCeilToScalar(x) ceil(x)
-#define SkScalarRoundToScalar(x) floor((x) + 0.5)
-#define SkScalarTruncToScalar(x) trunc(x)
-
-#define SkScalarFloorToInt(x) (int)floor(x)
-#define SkScalarCeilToInt(x) (int)ceil(x)
-#define SkScalarRoundToInt(x) (int)floor((x) + 0.5)
-
-#define SkScalarAbs(x) abs(x)
-#define SkScalarCopySign(x, y) copysign(x, y)
-#define SkScalarMod(x, y) fmod(x,y)
-#define SkScalarSqrt(x) sqrt(x)
-#define SkScalarPow(b, e) pow(b, e)
-
-#define SkScalarSin(radians) sin(radians)
-#define SkScalarCos(radians) cos(radians)
-#define SkScalarTan(radians) tan(radians)
-#define SkScalarASin(val) asin(val)
-#define SkScalarACos(val) acos(val)
-#define SkScalarATan2(y, x) atan2(y,x)
-#define SkScalarExp(x) exp(x)
-#define SkScalarLog(x) log(x)
-#define SkScalarLog2(x) log2(x)
-
-#endif
-
//////////////////////////////////////////////////////////////////////////////////////////////////
#define SkIntToScalar(x) static_cast<SkScalar>(x)