Module firework_rs::utils
source · Expand description
utils module provides some useful helper functions of random generation and gradient scale
Functions§
- Return squared distance between to points
- A sample function defining the gradient of the
Particle - A sample function defining the gradient of the
Particle - A sample function defining the gradient of the
Particle - Generate random
Vec2on an arc - Generate random
Vec2within a circle range - Generate random
Vec2within a circle range with normal distribution - Generate random
Vec2within a circle range with normal distribution - Generate random
Vec2within a fan-shape range - Generate random
Vec2on a circle - A sample function defining the gradient of the
Particle - Round a
Vec2from(f32, f32)to(isize, isize)