This commit is contained in:
aozhiwei 2019-04-13 12:00:36 +08:00
parent b5c3f69440
commit 990fe6dd16

View File

@ -34,10 +34,10 @@ void Vector2D::Normalize()
{
#if 1
glm::vec2 v = glm::normalize(glm::vec2(x, y));
assert(!isnan(v[0]));
assert(!isnan(v[1]));
x = v[0];
y = v[1];
assert(!isnan(x));
assert(!isnan(x));
#else
Eigen::Vector2f v(x, y);
v.normalize();