Calculates the vector projection of pointA
onto the nonzero pointB
. This is the
orthogonal projection of pointA
onto a straight line parallel to pointB
.
name | type | arguments | description |
---|---|---|---|
pointA | Phaser.Geom.Point |
Point A, to be projected onto Point B. |
|
pointB | Phaser.Geom.Point |
Point B, to have Point A projected upon it. |
|
out | Phaser.Geom.Point | <optional> |
The Point object to store the position in. If not given, a new Point instance is created. |
A Point object holding the coordinates of the vector projection of pointA
onto pointB
.