|
17 | 17 | #include"ink/geometry/angle.h" |
18 | 18 | #include"ink/jni/internal/jni_defines.h" |
19 | 19 |
|
| 20 | +namespace { |
| 21 | + |
| 22 | +using ::ink::Angle; |
| 23 | + |
| 24 | +}// namespace |
| 25 | + |
20 | 26 | extern"C" { |
21 | 27 |
|
22 | | -JNI_METHOD(geometry, Angle, jfloat, nativeNormalized) |
23 | | -(JNIEnv* env, jobject object, jfloat angle_radians) { |
24 | | - ink::Angle angle =ink::Angle::Radians(angle_radians); |
25 | | -return angle.Normalized().ValueInRadians(); |
| 28 | +JNI_METHOD(geometry, AngleNative, jfloat, normalizedRadians) |
| 29 | +(JNIEnv* env, jobject object, jfloat radians) { |
| 30 | +returnAngle::Radians(radians).Normalized().ValueInRadians(); |
26 | 31 | } |
27 | 32 |
|
28 | | -JNI_METHOD(geometry, Angle, jfloat, nativeNormalizedAboutZero) |
29 | | -(JNIEnv* env, jobject object, jfloat angle_radians) { |
30 | | - ink::Angle angle =ink::Angle::Radians(angle_radians); |
31 | | -return angle.NormalizedAboutZero().ValueInRadians(); |
32 | | -} |
| 33 | +JNI_METHOD(geometry, AngleNative, jfloat, normalizedAboutZeroRadians) |
| 34 | +(JNIEnv* env, jobject object, jfloat radians) { |
| 35 | +returnAngle::Radians(radians).NormalizedAboutZero().ValueInRadians(); |
33 | 36 | } |
| 37 | + |
| 38 | +}// extern "C" |