ultimatepp/reference/LinearInterpolation/LinearInterpolation.cpp

19 lines
388 B
C++

#include <Core/Core.h>
using namespace Upp;
// Generic Lerp and specializations
CONSOLE_APP_MAIN
{
StdLogSetup(LOG_COUT);
DUMP(Lerp(10, 20, 0.5));
DUMP(Lerp(10.0, 20.0, 0.25));
DUMP(Lerp(Point(10, 20), Point(30, 40), 0.5));
DUMP(Lerp(Size(100, 200), Size(300, 400), 0.5));
DUMP(Lerp(Rect(0, 0, 100, 100), Rect(100, 100, 200, 200), 0.5));
}