예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }
예제 #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)));
 }