mirror of
https://github.com/g-truc/glm.git
synced 2024-11-26 10:14:35 +00:00
Fixed error: comparing floating point with == or != is unsafe
This commit is contained in:
parent
f9dc1d587f
commit
291287e45d
@ -49,11 +49,8 @@ int test_ctr()
|
|||||||
{6, 7, 8},
|
{6, 7, 8},
|
||||||
{9, 10, 11}};
|
{9, 10, 11}};
|
||||||
|
|
||||||
for(glm::length_t i = 0; i < m0.length(); ++i)
|
Error += glm::all(glm::equal(m0, m2, glm::epsilon<float>())) ? 0 : 1;
|
||||||
Error += glm::all(glm::equal(m0[i], m2[i])) ? 0 : 1;
|
Error += glm::all(glm::equal(m1, m2, glm::epsilon<float>())) ? 0 : 1;
|
||||||
|
|
||||||
for(glm::length_t i = 0; i < m1.length(); ++i)
|
|
||||||
Error += glm::all(glm::equal(m1[i], m2[i])) ? 0 : 1;
|
|
||||||
|
|
||||||
std::vector<glm::mat4x3> v1{
|
std::vector<glm::mat4x3> v1{
|
||||||
{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11},
|
{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11},
|
||||||
|
Loading…
Reference in New Issue
Block a user