C# 클래스 TrianglesInSpace.Motion.Path

상속: IPath
파일 보기 프로젝트 열기: anthony-martin/Triangles-in-space 1 사용 예제들

공개 메소드들

메소드 설명
CalcRadius ( double velocity, double accel ) : double
CreatePathTo ( Vector destination, Vector initialVelocity, Vector initialPosition, ulong startTime ) : List
DetermineDurationOfTurn ( TrianglesInSpace.Primitives.Angle start, TrianglesInSpace.Primitives.Angle end, TrianglesInSpace.Primitives.Angle turnRate, TurnDirection turnDirection ) : ulong
DetermineTurnDirection ( Vector velocity, Vector turiningCircleOffset ) : TurnDirection

Determines if a turn is clockwise or anti clockwise

DetermineTurnEnd ( Vector destination, double radius, TurnDirection turnDirection ) : TrianglesInSpace.Primitives.Angle

DetermineTurnRate ( double speed, double radius, TurnDirection turnDirection ) : TrianglesInSpace.Primitives.Angle
DetermineTurningCircles ( Vector initialVelocity, double radius, Vector &circleOne, Vector &circleTwo ) : void

Determines the positions of the two possible turning circles Relative to the initial position which is not passed into the function

GetCurrentMotion ( ulong currentTime ) : IMotion
MoveToDestination ( Vector destination, ulong currentTime ) : void
Path ( ) : System
Path ( double maximumAcceleration, IMotion startingMotion ) : System
SelectTuriningCircle ( Vector circleCentreOne, Vector circleCentreTwo, Vector targetPosition, double turningRadius ) : Vector

Select the closest turning circle to the desitnation unless the closest circle is within the radius of the turning circle. All positions need to be in the same reference frame

메소드 상세

CalcRadius() 공개 정적인 메소드

public static CalcRadius ( double velocity, double accel ) : double
velocity double
accel double
리턴 double

CreatePathTo() 공개 메소드

public CreatePathTo ( Vector destination, Vector initialVelocity, Vector initialPosition, ulong startTime ) : List
destination TrianglesInSpace.Primitives.Vector
initialVelocity TrianglesInSpace.Primitives.Vector
initialPosition TrianglesInSpace.Primitives.Vector
startTime ulong
리턴 List

DetermineDurationOfTurn() 공개 메소드

public DetermineDurationOfTurn ( TrianglesInSpace.Primitives.Angle start, TrianglesInSpace.Primitives.Angle end, TrianglesInSpace.Primitives.Angle turnRate, TurnDirection turnDirection ) : ulong
start TrianglesInSpace.Primitives.Angle
end TrianglesInSpace.Primitives.Angle
turnRate TrianglesInSpace.Primitives.Angle
turnDirection TurnDirection
리턴 ulong

DetermineTurnDirection() 공개 메소드

Determines if a turn is clockwise or anti clockwise
public DetermineTurnDirection ( Vector velocity, Vector turiningCircleOffset ) : TurnDirection
velocity TrianglesInSpace.Primitives.Vector The current velocity of the object
turiningCircleOffset TrianglesInSpace.Primitives.Vector The position of the turning circle relative to the initial position
리턴 TurnDirection

DetermineTurnEnd() 공개 메소드

public DetermineTurnEnd ( Vector destination, double radius, TurnDirection turnDirection ) : TrianglesInSpace.Primitives.Angle
destination TrianglesInSpace.Primitives.Vector The position of the destination relative to the turning point
radius double The radius of the turning circle
turnDirection TurnDirection If the turn is clockwise or anti clockwise
리턴 TrianglesInSpace.Primitives.Angle

DetermineTurnRate() 공개 메소드

public DetermineTurnRate ( double speed, double radius, TurnDirection turnDirection ) : TrianglesInSpace.Primitives.Angle
speed double
radius double
turnDirection TurnDirection
리턴 TrianglesInSpace.Primitives.Angle

DetermineTurningCircles() 공개 메소드

Determines the positions of the two possible turning circles Relative to the initial position which is not passed into the function
public DetermineTurningCircles ( Vector initialVelocity, double radius, Vector &circleOne, Vector &circleTwo ) : void
initialVelocity TrianglesInSpace.Primitives.Vector The current velocity of the object
radius double The desired radius of the object
circleOne TrianglesInSpace.Primitives.Vector The first of the two possible turning circles
circleTwo TrianglesInSpace.Primitives.Vector The second of the two possible turning circles
리턴 void

GetCurrentMotion() 공개 메소드

public GetCurrentMotion ( ulong currentTime ) : IMotion
currentTime ulong
리턴 IMotion

MoveToDestination() 공개 메소드

public MoveToDestination ( Vector destination, ulong currentTime ) : void
destination TrianglesInSpace.Primitives.Vector
currentTime ulong
리턴 void

Path() 공개 메소드

public Path ( ) : System
리턴 System

Path() 공개 메소드

public Path ( double maximumAcceleration, IMotion startingMotion ) : System
maximumAcceleration double
startingMotion IMotion
리턴 System

SelectTuriningCircle() 공개 메소드

Select the closest turning circle to the desitnation unless the closest circle is within the radius of the turning circle. All positions need to be in the same reference frame
public SelectTuriningCircle ( Vector circleCentreOne, Vector circleCentreTwo, Vector targetPosition, double turningRadius ) : Vector
circleCentreOne TrianglesInSpace.Primitives.Vector
circleCentreTwo TrianglesInSpace.Primitives.Vector
targetPosition TrianglesInSpace.Primitives.Vector The destination
turningRadius double The radius of the circles
리턴 TrianglesInSpace.Primitives.Vector