Add quadratic, cubing, quartic eases
Add a few common easing functions, with a few questions regarding scope:
- A quick search seems like CSS doesn't define a whole bunch of eases. Does that matter wrt what gets defined in haxeui?
- Does "reverse easing function" need to be updated for every ease if it's a CSS thing?
- Tunable complex eases like
bouncemaybe don't need to be implemented here? As in, externally defining aFloat->Floateasing function may be more flexible - If we define a bunch here, how many? Sine, quintic, exponential, back, circular, elastic...
Will update formatting, unless you have something quick for that
A quick search seems like CSS doesn't define a whole bunch of eases. Does that matter wrt what gets defined in haxeui?
I wouldnt say so - the animation system is going to be overhauled at some point - so now is a nice time to get as many things in so they dont get "lost in the shuffle" - css animations can always be enhanced "later"
Does "reverse easing function" need to be updated for every ease if it's a CSS thing?
Usually, i would say "yes", but here i feel like it doesnt matter so much - i doubt many (any?) people are using css animations (they are clunky - even in css3) so i think it can wait for a refactor (that wont stop the clunkiness of them ofc)
Tunable complex eases like bounce maybe don't need to be implemented here? As in, externally defining a Float->Float easing function may be more flexible
At some point (probably sooner rather than later), ill see about making all this moddable by the module.xml - that way if someone does want to an a new function they wont need to go through and modify core code like you have had to
I do like the idea about "tunable easing functions" though... how would the function signature for, for example, a tunage bounce look - it maybe worth trying to get that type of thing working now.
If we define a bunch here, how many? Sine, quintic, exponential, back, circular, elastic...
as many as you want - the ones you have listed seem perfectly sensible to me
Will update formatting, unless you have something quick for that
I dont
Ok let me just add most of these then https://easings.net/
Here is a bounce definition, with the coefficients affecting how many bounces etc