|
Aurore
A Switch-like interface for your app, on every screen
|
Functions | |
| aurore::Time | now () |
| Now, in µs (the clock every helper reads). | |
| float | progress (aurore::Time since, float duration_us) |
| float | ease_out (float t) |
| Easings, 0..1 to 0..1. | |
| float | ease_in_out (float t) |
| sine | |
| float | back_out (float t) |
| overshoots a little, then settles | |
| void | reveal (aurore::View *view, float rise=10.0f, int ms=180, int delay_ms=0) |
| void | reveal_all (const std::vector< aurore::View * > &views, float rise=8.0f, int ms=220, int stagger_ms=35, int limit=8) |
| void | dismiss (aurore::View *view, std::function< void()> then, float rise=8.0f, int ms=200) |
| void | slide_from (aurore::View *view, float dx, float dy, int ms=220) |
| void | breathe (aurore::View *view, float low=0.45f, int ms=700) |
view breathes once: to low alpha and back, over ms. | |
| float motion::back_out | ( | float | t | ) |
overshoots a little, then settles
| void motion::breathe | ( | aurore::View * | view, |
| float | low = 0.45f, |
||
| int | ms = 700 |
||
| ) |
view breathes once: to low alpha and back, over ms.
| void motion::dismiss | ( | aurore::View * | view, |
| std::function< void()> | then, | ||
| float | rise = 8.0f, |
||
| int | ms = 200 |
||
| ) |
view bows out: up rise px and to clear over ms, then then (what hides it, guarded by its caller: the view may be gone by then). With the motion off, then at once.
| float motion::ease_in_out | ( | float | t | ) |
sine
| float motion::ease_out | ( | float | t | ) |
Easings, 0..1 to 0..1.
cubic: fast, then settles
| aurore::Time motion::now | ( | ) |
Now, in µs (the clock every helper reads).
| float motion::progress | ( | aurore::Time | since, |
| float | duration_us | ||
| ) |
0..1: how far something begun at since (µs) is, over duration_us; 1 once it is over, or when since is 0.
| void motion::reveal | ( | aurore::View * | view, |
| float | rise = 10.0f, |
||
| int | ms = 180, |
||
| int | delay_ms = 0 |
||
| ) |
view rises rise px into its place over ms, from nearly clear to its alpha, after delay_ms; nothing (the view as it is) with the motion off. For a aurore::Box; any other view is left as it is.
| void motion::reveal_all | ( | const std::vector< aurore::View * > & | views, |
| float | rise = 8.0f, |
||
| int | ms = 220, |
||
| int | stagger_ms = 35, |
||
| int | limit = 8 |
||
| ) |
The same for each of views in turn, stagger_ms apart, the first limit of them only (the rest come as they are): a list's lines.
| void motion::slide_from | ( | aurore::View * | view, |
| float | dx, | ||
| float | dy, | ||
| int | ms = 220 |
||
| ) |
view was just moved by (dx, dy): it slides from where it was to where it is, over ms.