-
-
Notifications
You must be signed in to change notification settings - Fork 151
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* develop: chore: update git attribs, remove obsolete files fix(geom): arg order pointAt() impl (RAY/RAY3) refactor(vectors): cleanup, update docs/readme refactor(vectors): renaming and minor fixes at point-on-ray feat(vectors, geom): point on ray at distance
- Loading branch information
Showing
8 changed files
with
71 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,4 @@ | |
*.pdf -text | ||
*.png -text | ||
*.gz -text | ||
tools/doc/typedoc-theme/* linguist-vendored |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
import { Vec } from "./api"; | ||
import { maddN, maddN2, maddN3 } from "./maddn"; | ||
|
||
/** | ||
* Calculates the nD point laying on ray at given distance. `rayDir` MUST be | ||
* normalized. | ||
* | ||
* @param out - | ||
* @param rayOrigin - | ||
* @param rayDir - | ||
* @param dist - | ||
*/ | ||
export const pointOnRay = ( | ||
out: Vec | null, | ||
rayOrigin: Vec, | ||
rayDir: Vec, | ||
dist: number | ||
) => maddN(out, rayDir, dist, rayOrigin); | ||
|
||
/** | ||
* 2D version of {@link pointOnRay}. | ||
* | ||
* @param out - | ||
* @param rayOrigin - | ||
* @param rayDir - | ||
* @param dist - | ||
*/ | ||
export const pointOnRay2 = ( | ||
out: Vec | null, | ||
rayOrigin: Vec, | ||
rayDir: Vec, | ||
dist: number | ||
) => maddN2(out, rayDir, dist, rayOrigin); | ||
|
||
/** | ||
* 3D version of {@link pointOnRay}. | ||
* | ||
* @param out - | ||
* @param rayOrigin - | ||
* @param rayDir - | ||
* @param dist - | ||
*/ | ||
export const pointOnRay3 = ( | ||
out: Vec | null, | ||
rayOrigin: Vec, | ||
rayDir: Vec, | ||
dist: number | ||
) => maddN3(out, rayDir, dist, rayOrigin); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.