[ios] describe radians↔degrees functions

This commit is contained in:
Jason Wray
2015-10-02 18:54:53 -04:00
parent e565808de0
commit 29da7bb26d

View File

@@ -83,11 +83,13 @@ NS_INLINE NSString *MGLStringFromCoordinateBounds(MGLCoordinateBounds bounds) {
bounds.ne.latitude, bounds.ne.longitude];
}
/** Returns radians, converted from degrees. */
NS_INLINE CGFloat MGLRadiansFromDegrees(CLLocationDegrees degrees)
{
return (CGFloat)(degrees * M_PI) / 180;
}
/** Returns degrees, converted from radians. */
NS_INLINE CLLocationDegrees MGLDegreesFromRadians(CGFloat radians)
{
return radians * 180 / M_PI;