Ejemplo n.º 1
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix2x3f Round(Matrix2x3f value, int digits, MidpointRounding mode)
 {
     return(new Matrix2x3f(Functions.Round(value.M11, digits, mode), Functions.Round(value.M21, digits, mode), Functions.Round(value.M12, digits, mode), Functions.Round(value.M22, digits, mode), Functions.Round(value.M13, digits, mode), Functions.Round(value.M23, digits, mode)));
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix2x3f Round(Matrix2x3f value)
 {
     return(new Matrix2x3f(Functions.Round(value.M11), Functions.Round(value.M21), Functions.Round(value.M12), Functions.Round(value.M22), Functions.Round(value.M13), Functions.Round(value.M23)));
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix2x3f Round(Matrix2x3f value, int digits)
 {
     return(new Matrix2x3f(Functions.Round(value.M11, digits), Functions.Round(value.M21, digits), Functions.Round(value.M12, digits), Functions.Round(value.M22, digits), Functions.Round(value.M13, digits), Functions.Round(value.M23, digits)));
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Returns a vector where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A vector.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Vector2f Round(Vector2h value, int digits)
 {
     return(new Vector2f(Functions.Round(value.X, digits), Functions.Round(value.Y, digits)));
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix2x3d Round(Matrix2x3d value, MidpointRounding mode)
 {
     return(new Matrix2x3d(Functions.Round(value.M11, mode), Functions.Round(value.M21, mode), Functions.Round(value.M12, mode), Functions.Round(value.M22, mode), Functions.Round(value.M13, mode), Functions.Round(value.M23, mode)));
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix4x2f Round(Matrix4x2f value, MidpointRounding mode)
 {
     return(new Matrix4x2f(Functions.Round(value.M11, mode), Functions.Round(value.M21, mode), Functions.Round(value.M31, mode), Functions.Round(value.M41, mode), Functions.Round(value.M12, mode), Functions.Round(value.M22, mode), Functions.Round(value.M32, mode), Functions.Round(value.M42, mode)));
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x2d Round(Matrix3x2d value, int digits)
 {
     return(new Matrix3x2d(Functions.Round(value.M11, digits), Functions.Round(value.M21, digits), Functions.Round(value.M31, digits), Functions.Round(value.M12, digits), Functions.Round(value.M22, digits), Functions.Round(value.M32, digits)));
 }
Ejemplo n.º 8
0
 /// <summary>
 /// Returns a complex number where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A complex number.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Complex Round(Complex value, int digits)
 {
     return(new Complex(
                Functions.Round(value.A, digits),
                Functions.Round(value.B, digits)));
 }
Ejemplo n.º 9
0
 /// <summary>
 /// Returns a complex number where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A complex number.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Complex Round(Complex value, int digits, MidpointRounding mode)
 {
     return(new Complex(
                Functions.Round(value.A, digits, mode),
                Functions.Round(value.B, digits, mode)));
 }
Ejemplo n.º 10
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x4f Round(Matrix3x4f value, int digits, MidpointRounding mode)
 {
     return(new Matrix3x4f(Functions.Round(value.M11, digits, mode), Functions.Round(value.M21, digits, mode), Functions.Round(value.M31, digits, mode), Functions.Round(value.M12, digits, mode), Functions.Round(value.M22, digits, mode), Functions.Round(value.M32, digits, mode), Functions.Round(value.M13, digits, mode), Functions.Round(value.M23, digits, mode), Functions.Round(value.M33, digits, mode), Functions.Round(value.M14, digits, mode), Functions.Round(value.M24, digits, mode), Functions.Round(value.M34, digits, mode)));
 }
Ejemplo n.º 11
0
 /// <summary>
 /// Returns a complex number where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A complex number.</param>
 /// <returns>The result of rounding value.</returns>
 public static Complex Round(Complex value)
 {
     return(new Complex(
                Functions.Round(value.A),
                Functions.Round(value.B)));
 }
Ejemplo n.º 12
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix4x3d Round(Matrix4x3d value, int digits, MidpointRounding mode)
 {
     return(new Matrix4x3d(Functions.Round(value.M11, digits, mode), Functions.Round(value.M21, digits, mode), Functions.Round(value.M31, digits, mode), Functions.Round(value.M41, digits, mode), Functions.Round(value.M12, digits, mode), Functions.Round(value.M22, digits, mode), Functions.Round(value.M32, digits, mode), Functions.Round(value.M42, digits, mode), Functions.Round(value.M13, digits, mode), Functions.Round(value.M23, digits, mode), Functions.Round(value.M33, digits, mode), Functions.Round(value.M43, digits, mode)));
 }
Ejemplo n.º 13
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix4x3d Round(Matrix4x3d value)
 {
     return(new Matrix4x3d(Functions.Round(value.M11), Functions.Round(value.M21), Functions.Round(value.M31), Functions.Round(value.M41), Functions.Round(value.M12), Functions.Round(value.M22), Functions.Round(value.M32), Functions.Round(value.M42), Functions.Round(value.M13), Functions.Round(value.M23), Functions.Round(value.M33), Functions.Round(value.M43)));
 }
Ejemplo n.º 14
0
 /// <summary>
 /// Returns a vector where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A vector.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Vector2f Round(Vector2h value, int digits, MidpointRounding mode)
 {
     return(new Vector2f(Functions.Round(value.X, digits, mode), Functions.Round(value.Y, digits, mode)));
 }
Ejemplo n.º 15
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix4x2f Round(Matrix4x2f value)
 {
     return(new Matrix4x2f(Functions.Round(value.M11), Functions.Round(value.M21), Functions.Round(value.M31), Functions.Round(value.M41), Functions.Round(value.M12), Functions.Round(value.M22), Functions.Round(value.M32), Functions.Round(value.M42)));
 }
Ejemplo n.º 16
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x4d Round(Matrix3x4d value)
 {
     return(new Matrix3x4d(Functions.Round(value.M11), Functions.Round(value.M21), Functions.Round(value.M31), Functions.Round(value.M12), Functions.Round(value.M22), Functions.Round(value.M32), Functions.Round(value.M13), Functions.Round(value.M23), Functions.Round(value.M33), Functions.Round(value.M14), Functions.Round(value.M24), Functions.Round(value.M34)));
 }
Ejemplo n.º 17
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix4x2f Round(Matrix4x2f value, int digits)
 {
     return(new Matrix4x2f(Functions.Round(value.M11, digits), Functions.Round(value.M21, digits), Functions.Round(value.M31, digits), Functions.Round(value.M41, digits), Functions.Round(value.M12, digits), Functions.Round(value.M22, digits), Functions.Round(value.M32, digits), Functions.Round(value.M42, digits)));
 }
Ejemplo n.º 18
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x4d Round(Matrix3x4d value, int digits)
 {
     return(new Matrix3x4d(Functions.Round(value.M11, digits), Functions.Round(value.M21, digits), Functions.Round(value.M31, digits), Functions.Round(value.M12, digits), Functions.Round(value.M22, digits), Functions.Round(value.M32, digits), Functions.Round(value.M13, digits), Functions.Round(value.M23, digits), Functions.Round(value.M33, digits), Functions.Round(value.M14, digits), Functions.Round(value.M24, digits), Functions.Round(value.M34, digits)));
 }
Ejemplo n.º 19
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x2d Round(Matrix3x2d value)
 {
     return(new Matrix3x2d(Functions.Round(value.M11), Functions.Round(value.M21), Functions.Round(value.M31), Functions.Round(value.M12), Functions.Round(value.M22), Functions.Round(value.M32)));
 }
Ejemplo n.º 20
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x4d Round(Matrix3x4d value, MidpointRounding mode)
 {
     return(new Matrix3x4d(Functions.Round(value.M11, mode), Functions.Round(value.M21, mode), Functions.Round(value.M31, mode), Functions.Round(value.M12, mode), Functions.Round(value.M22, mode), Functions.Round(value.M32, mode), Functions.Round(value.M13, mode), Functions.Round(value.M23, mode), Functions.Round(value.M33, mode), Functions.Round(value.M14, mode), Functions.Round(value.M24, mode), Functions.Round(value.M34, mode)));
 }
Ejemplo n.º 21
0
 /// <summary>
 /// Returns a matrix where each element is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A matrix.</param>
 /// <param name="digits">The number of fractional digits in the return value.</param>
 /// <param name="mode">Specification for how to round value if it is midway between two other numbers.</param>
 /// <returns>The result of rounding value.</returns>
 public static Matrix3x2d Round(Matrix3x2d value, int digits, MidpointRounding mode)
 {
     return(new Matrix3x2d(Functions.Round(value.M11, digits, mode), Functions.Round(value.M21, digits, mode), Functions.Round(value.M31, digits, mode), Functions.Round(value.M12, digits, mode), Functions.Round(value.M22, digits, mode), Functions.Round(value.M32, digits, mode)));
 }
Ejemplo n.º 22
0
 /// <summary>
 /// Returns a vector where each component is rounded to the nearest integral value.
 /// </summary>
 /// <param name="value">A vector.</param>
 /// <returns>The result of rounding value.</returns>
 public static Vector2f Round(Vector2h value)
 {
     return(new Vector2f(Functions.Round(value.X), Functions.Round(value.Y)));
 }