C# 클래스 Sharpex2D.Math.Vector2

파일 보기 프로젝트 열기: ThuCommix/Sharpex2D 1 사용 예제들

공개 메소드들

메소드 설명
Abs ( Vector2 a ) : Vector2

Returns the absolute values of the specified vector.

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

Clamps the specified value.

CrossProduct ( ) : Vector2

Returns the vector cross product.

Dot ( Vector2 a, Vector2 b ) : float

Returns the dot product for the specified vectors.

Equals ( object obj ) : bool

Determines whether the specified System.Object is equal to this instance.

GetHashCode ( ) : int

Returns a hash code for this instance.

Lerp ( Vector2 a, Vector2 b, float amount ) : Vector2

Linear interpolation between the two values.

Max ( Vector2 a, Vector2 b ) : Vector2

Returns the greater components of the two values.

Min ( Vector2 a, Vector2 b ) : Vector2

Returns the lesser components of the two values.

Negate ( Vector2 vector ) : Vector2

Negates the specified vector.

Normalize ( Vector2 a ) : Vector2

Normalizes the specified vector.

Normalize ( ) : void

Normalizes this vector.

Reflect ( Vector2 vector, Vector2 normal ) : Vector2

Reflects the specified vector.

Rotate ( Vector2 vector, float angle ) : Vector2

Rotates the specified vector.

Round ( Vector2 vector ) : Vector2

Rounds the specified vector.

SmoothStep ( Vector2 a, Vector2 b, float amount ) : Vector2

Interpolates between two values using a cubic equation.

ToString ( ) : string

Returns a System.String that represents this instance.

Translate ( Vector2 translation ) : void

Translates the vector.

Truncate ( Vector2 a ) : Vector2

Truncates the specified vector and removes all decimal places.

Vector2 ( float value ) : System

Initializes a new instance of the Vector2 struct.

Vector2 ( float x, float y ) : System

Initializes a new instance of the Vector2 struct.

VectorProduct ( Vector2 left, Vector2 right ) : float

Returns the vector product.

operator ( ) : Vector2

Implements the operator *.

operator ( ) : bool

Implements the operator !=.

메소드 상세

Abs() 공개 정적인 메소드

Returns the absolute values of the specified vector.
public static Abs ( Vector2 a ) : Vector2
a Vector2 The vector.
리턴 Vector2

Clamp() 공개 정적인 메소드

Clamps the specified value.
public static Clamp ( Vector2 value, Vector2 min, Vector2 max ) : Vector2
value Vector2 The value.
min Vector2 The min.
max Vector2 The max.
리턴 Vector2

CrossProduct() 공개 메소드

Returns the vector cross product.
public CrossProduct ( ) : Vector2
리턴 Vector2

Dot() 공개 정적인 메소드

Returns the dot product for the specified vectors.
public static Dot ( Vector2 a, Vector2 b ) : float
a Vector2 The first value.
b Vector2 The second value.
리턴 float

Equals() 공개 메소드

Determines whether the specified System.Object is equal to this instance.
public Equals ( object obj ) : bool
obj object The to compare with this instance.
리턴 bool

GetHashCode() 공개 메소드

Returns a hash code for this instance.
public GetHashCode ( ) : int
리턴 int

Lerp() 공개 정적인 메소드

Linear interpolation between the two values.
public static Lerp ( Vector2 a, Vector2 b, float amount ) : Vector2
a Vector2 The first value.
b Vector2 The second value.
amount float The amount.
리턴 Vector2

Max() 공개 정적인 메소드

Returns the greater components of the two values.
public static Max ( Vector2 a, Vector2 b ) : Vector2
a Vector2 The first value.
b Vector2 The second value.
리턴 Vector2

Min() 공개 정적인 메소드

Returns the lesser components of the two values.
public static Min ( Vector2 a, Vector2 b ) : Vector2
a Vector2 The first value.
b Vector2 The second value.
리턴 Vector2

Negate() 공개 정적인 메소드

Negates the specified vector.
public static Negate ( Vector2 vector ) : Vector2
vector Vector2 The vector.
리턴 Vector2

Normalize() 공개 정적인 메소드

Normalizes the specified vector.
public static Normalize ( Vector2 a ) : Vector2
a Vector2 The vector.
리턴 Vector2

Normalize() 공개 메소드

Normalizes this vector.
public Normalize ( ) : void
리턴 void

Reflect() 공개 정적인 메소드

Reflects the specified vector.
public static Reflect ( Vector2 vector, Vector2 normal ) : Vector2
vector Vector2 The vector.
normal Vector2 The normal.
리턴 Vector2

Rotate() 공개 정적인 메소드

Rotates the specified vector.
public static Rotate ( Vector2 vector, float angle ) : Vector2
vector Vector2 The vector.
angle float The angle.
리턴 Vector2

Round() 공개 정적인 메소드

Rounds the specified vector.
public static Round ( Vector2 vector ) : Vector2
vector Vector2 The vector.
리턴 Vector2

SmoothStep() 공개 정적인 메소드

Interpolates between two values using a cubic equation.
public static SmoothStep ( Vector2 a, Vector2 b, float amount ) : Vector2
a Vector2 The first value.
b Vector2 The second value.
amount float The amount.
리턴 Vector2

ToString() 공개 메소드

Returns a System.String that represents this instance.
public ToString ( ) : string
리턴 string

Translate() 공개 메소드

Translates the vector.
public Translate ( Vector2 translation ) : void
translation Vector2 The translation.
리턴 void

Truncate() 공개 정적인 메소드

Truncates the specified vector and removes all decimal places.
public static Truncate ( Vector2 a ) : Vector2
a Vector2 The vector.
리턴 Vector2

Vector2() 공개 메소드

Initializes a new instance of the Vector2 struct.
public Vector2 ( float value ) : System
value float The value.
리턴 System

Vector2() 공개 메소드

Initializes a new instance of the Vector2 struct.
public Vector2 ( float x, float y ) : System
x float The x.
y float The y.
리턴 System

VectorProduct() 공개 정적인 메소드

Returns the vector product.
public static VectorProduct ( Vector2 left, Vector2 right ) : float
left Vector2
right Vector2
리턴 float

operator() 공개 정적인 메소드

Implements the operator *.
public static operator ( ) : Vector2
리턴 Vector2

operator() 공개 정적인 메소드

Implements the operator !=.
public static operator ( ) : bool
리턴 bool