Skip to content

Conversation

@emilk
Copy link
Owner

@emilk emilk commented Jun 6, 2024

This adds most of the "standard" easing functions from https://easings.net/ to emath::easing, and adds helpers in egui for using them.

In particular there is now ctx.animate_bool_with_easing and ctx.animate_bool_responsive, that uses a cubic easing function.

All animations in egui now uses cubic ease-out, for a more responsive feeling (fast at the start, slower towards the end).

@emilk emilk added emath Relates to the emath crate egui labels Jun 6, 2024
@emilk emilk merged commit 29b12e1 into master Jun 6, 2024
@emilk emilk deleted the emilk/easing branch June 6, 2024 11:09
@emilk emilk added the feature New feature or request label Jun 27, 2024
@aevyrie
Copy link
Contributor

aevyrie commented Oct 30, 2024

Closes #2717

hacknus pushed a commit to hacknus/egui that referenced this pull request Oct 30, 2024
This adds most of the "standard" easing functions from
https://easings.net/ to `emath::easing`, and adds helpers in `egui` for
using them.

In particular there is now `ctx.animate_bool_with_easing` and
`ctx.animate_bool_responsive`, that uses a cubic easing function.

All animations in egui now uses cubic ease-out, for a more responsive
feeling (fast at the start, slower towards the end).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

egui emath Relates to the emath crate feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants