High-degree easing functions shouldn't be jerky
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 171
Description
## Bevy version
https://github.com/bevyengine/bevy/blob/72f096c91ea1056c41f2da821d310765c4482c00/crates/bevy_math/src/curve/easing.rs#L283-L295
## What you did
Low-degree easing functions have no choice to be jerky -- a quadratic one is [forced](https://www.desmos.com/calculator/oe93v9okni) to be jerky because it doesn't have enough degrees of freedom *not* to be.
If I'm using `QuinticInOut`, though, I'd expect it to be using those extra degrees to give continuous acceleration.
The current definition is still jerky, though: it jumps from +40 acceleration to -40 acceleration instantly:
Or if the existing ones shouldn't be edited, for some reason, should maybe some [Hermite](https://en.wikipedia.org/wiki/Hermite_interpolation#Statement_of_the_problem) in-out easing functions be added with 0 nth derivates at the endpoints?
Contributor guide
Research direction
Start in crates/bevy_math/src/curve/easing.rs at lines 283-295 and inspect the high-degree easing definitions. Compare the current QuinticInOut behavior with the linked acceleration example, then determine whether existing functions should change or Hermite in-out functions should be added. Done means the selected high-degree easing behavior has continuous acceleration through the transition.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100