mirror of
https://github.com/oliverbooth/X10D
synced 2024-11-14 16:15:41 +00:00
(#15) Improve xmldoc for Deg <-> Rad methods
This commit is contained in:
parent
643a254b87
commit
08e89d3ab0
@ -8,10 +8,13 @@ namespace X10D.DoubleExtensions
|
|||||||
public static class DoubleExtensions
|
public static class DoubleExtensions
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts an angle from degrees to radians.
|
/// Converts the current angle in degrees to its equivalent represented in radians.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="angle">The angle in degrees.</param>
|
/// <param name="angle">The angle in degrees to convert.</param>
|
||||||
/// <returns>Returns <paramref name="angle" /> in radians.</returns>
|
/// <returns>
|
||||||
|
/// <paramref name="angle" /> converted from degrees to radians by calculating
|
||||||
|
/// <c><paramref name="angle" />π / 180</c>.
|
||||||
|
/// </returns>
|
||||||
public static double DegreesToRadians(this double angle)
|
public static double DegreesToRadians(this double angle)
|
||||||
{
|
{
|
||||||
return Math.PI * angle / 180.0;
|
return Math.PI * angle / 180.0;
|
||||||
@ -99,10 +102,13 @@ namespace X10D.DoubleExtensions
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts an angle from radians to degrees.
|
/// Converts the current angle in radians to its equivalent represented in degrees.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="angle">The angle in radians.</param>
|
/// <param name="angle">The angle in radians to convert.</param>
|
||||||
/// <returns>Returns <paramref name="angle" /> in degrees.</returns>
|
/// <returns>
|
||||||
|
/// <paramref name="angle" /> converted from radians to degrees by calculating
|
||||||
|
/// <c><paramref name="angle" />(180 / π)</c>.
|
||||||
|
/// </returns>
|
||||||
public static double RadiansToDegrees(this double angle)
|
public static double RadiansToDegrees(this double angle)
|
||||||
{
|
{
|
||||||
return angle * (180.0 / Math.PI);
|
return angle * (180.0 / Math.PI);
|
||||||
|
@ -9,10 +9,13 @@ namespace X10D.SingleExtensions
|
|||||||
public static class SingleExtensions
|
public static class SingleExtensions
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts an angle from degrees to radians.
|
/// Converts the current angle in degrees to its equivalent represented in radians.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="angle">The angle in degrees.</param>
|
/// <param name="angle">The angle in degrees to convert.</param>
|
||||||
/// <returns>Returns <paramref name="angle" /> in radians.</returns>
|
/// <returns>
|
||||||
|
/// <paramref name="angle" /> converted from degrees to radians by calculating
|
||||||
|
/// <c><paramref name="angle" />π / 180</c>.
|
||||||
|
/// </returns>
|
||||||
public static float DegreesToRadians(this float angle)
|
public static float DegreesToRadians(this float angle)
|
||||||
{
|
{
|
||||||
return (float)((double)angle).DegreesToRadians();
|
return (float)((double)angle).DegreesToRadians();
|
||||||
@ -100,10 +103,13 @@ namespace X10D.SingleExtensions
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Converts an angle from radians to degrees.
|
/// Converts the current angle in radians to its equivalent represented in degrees.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="angle">The angle in radians.</param>
|
/// <param name="angle">The angle in radians to convert.</param>
|
||||||
/// <returns>Returns <paramref name="angle" /> in degrees.</returns>
|
/// <returns>
|
||||||
|
/// <paramref name="angle" /> converted from radians to degrees by calculating
|
||||||
|
/// <c><paramref name="angle" />(180 / π)</c>.
|
||||||
|
/// </returns>
|
||||||
public static float RadiansToDegrees(this float angle)
|
public static float RadiansToDegrees(this float angle)
|
||||||
{
|
{
|
||||||
return (float)((double)angle).RadiansToDegrees();
|
return (float)((double)angle).RadiansToDegrees();
|
||||||
|
Loading…
Reference in New Issue
Block a user