swayfx/sway/desktop/fx_renderer/animation_utils.c
2024-01-26 19:46:13 +01:00

13 lines
232 B
C

#include <math.h>
#include "sway/desktop/fx_renderer/animation_utils.h"
double lerp (double a, double b, double t) {
return a * (1.0 - t) + b * t;
}
double ease_out_cubic (double t) {
double p = t - 1;
return pow(p, 3) + 1;
}