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

Side by Side Diff: include/core/SkScalar.h

Issue 121303004: Fleshed out a lot of the Path interfac (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: unused imports Created 6 years, 11 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 unified diff | Download patch
« no previous file with comments | « gyp/v8.gyp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkScalar_DEFINED 8 #ifndef SkScalar_DEFINED
9 #define SkScalar_DEFINED 9 #define SkScalar_DEFINED
10 10
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 /** Returns one half of the specified SkScalar 133 /** Returns one half of the specified SkScalar
134 */ 134 */
135 #define SkScalarHalf(a) ((a) * 0.5f) 135 #define SkScalarHalf(a) ((a) * 0.5f)
136 136
137 #define SK_ScalarSqrt2 1.41421356f 137 #define SK_ScalarSqrt2 1.41421356f
138 #define SK_ScalarPI 3.14159265f 138 #define SK_ScalarPI 3.14159265f
139 #define SK_ScalarTanPIOver8 0.414213562f 139 #define SK_ScalarTanPIOver8 0.414213562f
140 #define SK_ScalarRoot2Over2 0.707106781f 140 #define SK_ScalarRoot2Over2 0.707106781f
141 141
142 #define SkDegreesToRadians(degrees) ((degrees) * (SK_ScalarPI / 180)) 142 #define SkDegreesToRadians(degrees) ((degrees) * (SK_ScalarPI / 180))
143 #define SkRadiansToDegrees(radians) ((radians) * (180 / SK_ScalarPI))
143 float SkScalarSinCos(SkScalar radians, SkScalar* cosValue); 144 float SkScalarSinCos(SkScalar radians, SkScalar* cosValue);
144 #define SkScalarSin(radians) (float)sk_float_sin(radians) 145 #define SkScalarSin(radians) (float)sk_float_sin(radians)
145 #define SkScalarCos(radians) (float)sk_float_cos(radians) 146 #define SkScalarCos(radians) (float)sk_float_cos(radians)
146 #define SkScalarTan(radians) (float)sk_float_tan(radians) 147 #define SkScalarTan(radians) (float)sk_float_tan(radians)
147 #define SkScalarASin(val) (float)sk_float_asin(val) 148 #define SkScalarASin(val) (float)sk_float_asin(val)
148 #define SkScalarACos(val) (float)sk_float_acos(val) 149 #define SkScalarACos(val) (float)sk_float_acos(val)
149 #define SkScalarATan2(y, x) (float)sk_float_atan2(y,x) 150 #define SkScalarATan2(y, x) (float)sk_float_atan2(y,x)
150 #define SkScalarExp(x) (float)sk_float_exp(x) 151 #define SkScalarExp(x) (float)sk_float_exp(x)
151 #define SkScalarLog(x) (float)sk_float_log(x) 152 #define SkScalarLog(x) (float)sk_float_log(x)
152 153
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 SkASSERT(n >= 0); 225 SkASSERT(n >= 0);
225 for (int i = 0; i < n; ++i) { 226 for (int i = 0; i < n; ++i) {
226 if (a[i] != b[i]) { 227 if (a[i] != b[i]) {
227 return false; 228 return false;
228 } 229 }
229 } 230 }
230 return true; 231 return true;
231 } 232 }
232 233
233 #endif 234 #endif
OLDNEW
« no previous file with comments | « gyp/v8.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698