Reputation: 3207
How to get the degree of clockwise angle from antiClockWise angle. I need to do this in Java. Is there any Java API that can help ?
Upvotes: 1
Views: 3283
Reputation: 718718
No. There isn't an API to do this. This is simple high-school maths. So simple that using an API would make your code >>less<< readable and >>less< maintainable.
For the record, the "computation" is 360 - angle
, if the angle is in degrees, or 2 * Math.PI - angle
if the angle is in radians.
(Or ... maybe, you just want -angle
. Your terminology - "clockwise angle" and "anti-clockwise angle" is ambiguous.)
Upvotes: 3