C# 클래스 Sharpex2D.Math.MathHelper

파일 보기 프로젝트 열기: ThuCommix/Sharpex2D

공개 메소드들

메소드 설명
Abs ( float value ) : float

Returns the absolute value.

Atan2 ( float x, float y ) : float

Calculates the arctangent.

Barycentric ( float value1, float value2, float value3, float amount1, float amount2 ) : float

Returns the Cartesian coordinate for one axis of a point that is defined by a given triangle and two normalized barycentric (areal) coordinates.

CatmullRom ( float value1, float value2, float value3, float value4, float amount ) : float

Performs a Catmull-Rom interpolation using the specified positions.

Clamp ( float value, float min, float max ) : float

Restricts a value to be within a specified range.

Cos ( float value ) : float

Returns the cosinus for the specified value.

Distance ( float value1, float value2 ) : float

Calculates the absolute value of the difference of two values.

Hermite ( float value1, float tangent1, float value2, float tangent2, float amount ) : float

Performs a Hermite spline interpolation.

Lerp ( float value1, float value2, float amount ) : float

Linearly interpolates between two values.

Max ( float value1, float value2 ) : float

Returns the greater of two values.

Min ( float value1, float value2 ) : float

Returns the lesser of two values.

Pow ( float basis, float exponent ) : float

Calculates x raised to the power of y.

Round ( float value ) : float

Rounds the specified value.

Sin ( float value ) : float

Returns the sinus for the specified value.

SmoothStep ( float value1, float value2, float amount ) : float

Interpolates between two values using a cubic equation.

Sqrt ( float value ) : float

Returns the square root for the specified value.

ToAngle ( Vector2 vector ) : float

Calculates an angle out of given coordinates.

ToAngle ( float x, float y ) : float

Calculates an angle out of given coordinates.

ToDegrees ( float radians ) : float

Converts radians to degrees.

ToRadians ( float degrees ) : float

Converts degrees to radians.

ToVector ( float angle ) : Vector2

Converts an angle to a direction vector.

WrapAngle ( float angle ) : float

Reduces a given angle to a value between π and -π.

메소드 상세

Abs() 공개 정적인 메소드

Returns the absolute value.
public static Abs ( float value ) : float
value float The value.
리턴 float

Atan2() 공개 정적인 메소드

Calculates the arctangent.
public static Atan2 ( float x, float y ) : float
x float The X.
y float The Y.
리턴 float

Barycentric() 공개 정적인 메소드

Returns the Cartesian coordinate for one axis of a point that is defined by a given triangle and two normalized barycentric (areal) coordinates.
public static Barycentric ( float value1, float value2, float value3, float amount1, float amount2 ) : float
value1 float The value1.
value2 float The value2.
value3 float The value3.
amount1 float The amount1.
amount2 float The amount2.
리턴 float

CatmullRom() 공개 정적인 메소드

Performs a Catmull-Rom interpolation using the specified positions.
public static CatmullRom ( float value1, float value2, float value3, float value4, float amount ) : float
value1 float The value1.
value2 float The value2.
value3 float The value3.
value4 float The value4.
amount float The amount.
리턴 float

Clamp() 공개 정적인 메소드

Restricts a value to be within a specified range.
public static Clamp ( float value, float min, float max ) : float
value float The value.
min float The minimum.
max float The maximum.
리턴 float

Cos() 공개 정적인 메소드

Returns the cosinus for the specified value.
public static Cos ( float value ) : float
value float The value.
리턴 float

Distance() 공개 정적인 메소드

Calculates the absolute value of the difference of two values.
public static Distance ( float value1, float value2 ) : float
value1 float The value1.
value2 float The value2.
리턴 float

Hermite() 공개 정적인 메소드

Performs a Hermite spline interpolation.
public static Hermite ( float value1, float tangent1, float value2, float tangent2, float amount ) : float
value1 float The value1.
tangent1 float The tangent1.
value2 float The value2.
tangent2 float The tangent2.
amount float The amount.
리턴 float

Lerp() 공개 정적인 메소드

Linearly interpolates between two values.
public static Lerp ( float value1, float value2, float amount ) : float
value1 float The value1.
value2 float The value2.
amount float The amount.
리턴 float

Max() 공개 정적인 메소드

Returns the greater of two values.
public static Max ( float value1, float value2 ) : float
value1 float The value1.
value2 float The value2.
리턴 float

Min() 공개 정적인 메소드

Returns the lesser of two values.
public static Min ( float value1, float value2 ) : float
value1 float The value1.
value2 float The value2.
리턴 float

Pow() 공개 정적인 메소드

Calculates x raised to the power of y.
public static Pow ( float basis, float exponent ) : float
basis float The Basis.
exponent float The Exponent.
리턴 float

Round() 공개 정적인 메소드

Rounds the specified value.
public static Round ( float value ) : float
value float The value.
리턴 float

Sin() 공개 정적인 메소드

Returns the sinus for the specified value.
public static Sin ( float value ) : float
value float The value.
리턴 float

SmoothStep() 공개 정적인 메소드

Interpolates between two values using a cubic equation.
public static SmoothStep ( float value1, float value2, float amount ) : float
value1 float The value1.
value2 float The value2.
amount float The amount.
리턴 float

Sqrt() 공개 정적인 메소드

Returns the square root for the specified value.
public static Sqrt ( float value ) : float
value float The value.
리턴 float

ToAngle() 공개 정적인 메소드

Calculates an angle out of given coordinates.
public static ToAngle ( Vector2 vector ) : float
vector Vector2 The vector.
리턴 float

ToAngle() 공개 정적인 메소드

Calculates an angle out of given coordinates.
public static ToAngle ( float x, float y ) : float
x float The x.
y float The y.
리턴 float

ToDegrees() 공개 정적인 메소드

Converts radians to degrees.
public static ToDegrees ( float radians ) : float
radians float The radians.
리턴 float

ToRadians() 공개 정적인 메소드

Converts degrees to radians.
public static ToRadians ( float degrees ) : float
degrees float The degrees.
리턴 float

ToVector() 공개 정적인 메소드

Converts an angle to a direction vector.
public static ToVector ( float angle ) : Vector2
angle float The angle.
리턴 Vector2

WrapAngle() 공개 정적인 메소드

Reduces a given angle to a value between π and -π.
public static WrapAngle ( float angle ) : float
angle float The angle.
리턴 float