Added assert to ensure lerp is used in the correct range of value

master
Christophe Riccio ago%!(EXTRA string=13 years)
parent cd043f2ee2
commit 9926506c7f
  1. 4
      glm/gtc/quaternion.inl

@ -480,6 +480,10 @@ namespace detail
T const & a
)
{
// Lerp is only defined in [0, 1]
assert(a >= T(0));
assert(a <= T(1));
return x * (T(1) - a) + (y * a);
}

Loading…
Cancel
Save