C# Class Sparrow.Geom.Point

The Point class describes a two dimensional point or vector. */
Inheritance: SparrowSharp.Pool.PooledObject
Mostrar archivo Open project: fmotagarcia/sparrow-sharp Class Usage Examples

Public Properties

Property Type Description
X float
Y float

Public Methods

Method Description
AddPoint ( Point point ) : void
CopyFromPoint ( Point point ) : void
Create ( float x = 0.0f, float y = 0.0f ) : Point
Distance ( Point p2 ) : float
Dot ( Point other ) : float
Equals ( Point other ) : bool

Determines whether the specified Point's X and Y values is equal to the current Point with with a small epsilon error margin.

Invert ( ) : void
Normalize ( ) : void
RotateBy ( float angle ) : void

Rotates by the specified angle in Radians

SubtractPoint ( Point point ) : void

Private Methods

Method Description
Init ( ) : Point
Point ( float x = 0.0f, float y = 0.0f ) : System

Method Details

AddPoint() public method

public AddPoint ( Point point ) : void
point Point
return void

CopyFromPoint() public method

public CopyFromPoint ( Point point ) : void
point Point
return void

Create() public static method

public static Create ( float x = 0.0f, float y = 0.0f ) : Point
x float
y float
return Point

Distance() public method

public Distance ( Point p2 ) : float
p2 Point
return float

Dot() public method

public Dot ( Point other ) : float
other Point
return float

Equals() public method

Determines whether the specified Point's X and Y values is equal to the current Point with with a small epsilon error margin.
public Equals ( Point other ) : bool
other Point
return bool

Invert() public method

public Invert ( ) : void
return void

Normalize() public method

public Normalize ( ) : void
return void

RotateBy() public method

Rotates by the specified angle in Radians
public RotateBy ( float angle ) : void
angle float
return void

SubtractPoint() public method

public SubtractPoint ( Point point ) : void
point Point
return void

Property Details

X public_oe property

public float X
return float

Y public_oe property

public float Y
return float