Midnight Blue Game and Engine
Public Member Functions | Properties | List of all members
MB2D.Geometry.Line Class Reference

A line structure, can be drawn via SpriteBatch More...

Collaboration diagram for MB2D.Geometry.Line:
Collaboration graph

Public Member Functions

 Line (Vector2 start, Vector2 end)
 Initializes a new instance of the T:MB2D.Geometry.Line class. More...
 
 Line (Point start, Point end)
 Initializes a new instance of the T:MB2D.Geometry.Line class. More...
 
float PointDistance (Vector2 point)
 Gets the distance from this line a given point is More...
 
float PointDistance (Point point)
 Gets the distance from this line a given point is More...
 

Properties

Vector2 Start [get, set]
 Gets or sets the start point. More...
 
Vector2 End [get, set]
 Gets or sets the end point. More...
 

Detailed Description

A line structure, can be drawn via SpriteBatch

Constructor & Destructor Documentation

§ Line() [1/2]

MB2D.Geometry.Line.Line ( Vector2  start,
Vector2  end 
)
inline

Initializes a new instance of the T:MB2D.Geometry.Line class.

Parameters
startStart point
endEnd point

§ Line() [2/2]

MB2D.Geometry.Line.Line ( Point  start,
Point  end 
)
inline

Initializes a new instance of the T:MB2D.Geometry.Line class.

Parameters
startStart point
endEnd point

Member Function Documentation

§ PointDistance() [1/2]

float MB2D.Geometry.Line.PointDistance ( Vector2  point)
inline

Gets the distance from this line a given point is

Returns
The distance.
Parameters
pointPoint to calculate.

§ PointDistance() [2/2]

float MB2D.Geometry.Line.PointDistance ( Point  point)
inline

Gets the distance from this line a given point is

Returns
The distance.
Parameters
pointPoint to calculate.

Property Documentation

§ End

Vector2 MB2D.Geometry.Line.End
getset

Gets or sets the end point.

The end point.

§ Start

Vector2 MB2D.Geometry.Line.Start
getset

Gets or sets the start point.

The start point


The documentation for this class was generated from the following file: