Fix typo in test/bench/noise.rs. Closes #8574.
This commit is contained in:
parent
934a5eba50
commit
0f6e90a5fd
1 changed files with 1 additions and 1 deletions
|
|
@ -25,7 +25,7 @@ fn random_gradient<R:Rng>(r: &mut R) -> Vec2 {
|
||||||
|
|
||||||
fn gradient(orig: Vec2, grad: Vec2, p: Vec2) -> f32 {
|
fn gradient(orig: Vec2, grad: Vec2, p: Vec2) -> f32 {
|
||||||
let sp = Vec2 {x: p.x - orig.x, y: p.y - orig.y};
|
let sp = Vec2 {x: p.x - orig.x, y: p.y - orig.y};
|
||||||
grad.x * sp.x + grad.y + sp.y
|
grad.x * sp.x + grad.y * sp.y
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Noise2DContext {
|
struct Noise2DContext {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue