#ifndef _ANIMATION_INTERPOLATE
#define _ANIMATION_INTERPOLATE

#include "Animation.h"

struct A_Interpolate {
	u32 startFrame;
	u32 endFrame;

	void* initialValueTemp;
	size_t initialValueTempSize;

	void* value;
	void* goalValue;
	void (*interpolate)(void* value, const void* initialState, const void* finalState, double percentage);
};

ARGB A_Interpolate(const Animation* anim, u32 frameIndex, ARGB pixel, i32 r, i32 c, void* priv);

void AO_LineInterpolate(void* valueLine, const void* initialLine, const void* finalLine, double percentage);

void AM_LinearInterpolate(void* valueLinear, const void* initialLinear, const void* finalLinear, double percentage);
void AM_SpinInterpolate(void* valueSpin, const void* initialSpin, const void* finalSpin, double percentage);

#endif /* _ANIMATION_INTERPOLATE */
