math: fix lerp reference
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
fe517f3efb
commit
77b95aa9a9
1 changed files with 1 additions and 1 deletions
|
|
@ -212,7 +212,7 @@ pub fn Vec(comptime n_value: usize, comptime Scalar: type) type {
|
||||||
/// a.lerp(b, 1.0) == b
|
/// a.lerp(b, 1.0) == b
|
||||||
/// ```
|
/// ```
|
||||||
pub inline fn lerp(a: *const VecN, b: *const VecN, amount: Scalar) VecN {
|
pub inline fn lerp(a: *const VecN, b: *const VecN, amount: Scalar) VecN {
|
||||||
return a.mulScalar(1.0 - amount).add(b.mulScalar(amount));
|
return a.mulScalar(1.0 - amount).add(&b.mulScalar(amount));
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Calculates the dot product between vector a and b and returns scalar.
|
/// Calculates the dot product between vector a and b and returns scalar.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue