Fixed warnings
This commit is contained in:
parent
59c11d9531
commit
276a7beb19
@ -84,7 +84,7 @@ endif()
|
|||||||
|
|
||||||
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
|
||||||
add_definitions(-Weverything -Wpedantic -Wno-c++98-compat -Wno-c++98-compat-pedantic -Wno-padded -Wno-documentation -Wno-gnu-anonymous-struct -Wno-nested-anon-types)
|
add_definitions(-Weverything -Wpedantic -Wno-c++98-compat -Wno-c++98-compat-pedantic -Wno-padded -Wno-documentation -Wno-gnu-anonymous-struct -Wno-nested-anon-types)
|
||||||
add_definitions(-Wno-sign-conversion -Wno-unused-variable -Wno-missing-prototypes -Wno-unreachable-code -Wno-missing-variable-declarations -Wno-sign-compare)
|
add_definitions(-Wno-sign-conversion -Wno-unused-variable -Wno-missing-prototypes -Wno-unreachable-code -Wno-missing-variable-declarations -Wno-sign-compare -Wno-double-promotion)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
option(GLM_TEST_ENABLE_LANG_EXTENSIONS "Enable language extensions" OFF)
|
option(GLM_TEST_ENABLE_LANG_EXTENSIONS "Enable language extensions" OFF)
|
||||||
|
@ -30,7 +30,7 @@ namespace
|
|||||||
}
|
}
|
||||||
|
|
||||||
template<typename U, glm::precision P, typename T, typename CTy, typename CTr>
|
template<typename U, glm::precision P, typename T, typename CTy, typename CTr>
|
||||||
std::basic_string<CTy> type_name(std::basic_ostream<CTy,CTr>& os, T const&)
|
std::basic_string<CTy> type_name(std::basic_ostream<CTy,CTr>&, T const&)
|
||||||
{
|
{
|
||||||
std::basic_ostringstream<CTy,CTr> ostr;
|
std::basic_ostringstream<CTy,CTr> ostr;
|
||||||
|
|
||||||
|
@ -19,7 +19,7 @@ int test_qr(matType<C, R, T, P> m)
|
|||||||
|
|
||||||
for (glm::length_t i = 0; i < C; i++)
|
for (glm::length_t i = 0; i < C; i++)
|
||||||
for (glm::length_t j = 0; j < R; j++)
|
for (glm::length_t j = 0; j < R; j++)
|
||||||
Error += std::abs(err[i][j]) > epsilon ? 1 : 0;
|
Error += glm::abs(err[i][j]) > epsilon ? 1 : 0;
|
||||||
|
|
||||||
//Test if the columns of q are orthonormal
|
//Test if the columns of q are orthonormal
|
||||||
for (glm::length_t i = 0; i < (C < R ? C : R); i++)
|
for (glm::length_t i = 0; i < (C < R ? C : R); i++)
|
||||||
@ -27,7 +27,7 @@ int test_qr(matType<C, R, T, P> m)
|
|||||||
Error += (length(q[i]) - 1) > epsilon ? 1 : 0;
|
Error += (length(q[i]) - 1) > epsilon ? 1 : 0;
|
||||||
|
|
||||||
for (glm::length_t j = 0; j<i; j++)
|
for (glm::length_t j = 0; j<i; j++)
|
||||||
Error += std::abs(dot(q[i], q[j])) > epsilon ? 1 : 0;
|
Error += glm::abs(dot(q[i], q[j])) > epsilon ? 1 : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
//Test if the matrix r is upper triangular
|
//Test if the matrix r is upper triangular
|
||||||
@ -54,7 +54,7 @@ int test_rq(matType<C, R, T, P> m)
|
|||||||
|
|
||||||
for (glm::length_t i = 0; i < C; i++)
|
for (glm::length_t i = 0; i < C; i++)
|
||||||
for (glm::length_t j = 0; j < R; j++)
|
for (glm::length_t j = 0; j < R; j++)
|
||||||
Error += std::abs(err[i][j]) > epsilon ? 1 : 0;
|
Error += glm::abs(err[i][j]) > epsilon ? 1 : 0;
|
||||||
|
|
||||||
//Test if the rows of q are orthonormal
|
//Test if the rows of q are orthonormal
|
||||||
matType<(C < R ? C : R), C, T, P> tq = transpose(q);
|
matType<(C < R ? C : R), C, T, P> tq = transpose(q);
|
||||||
@ -64,7 +64,7 @@ int test_rq(matType<C, R, T, P> m)
|
|||||||
Error += (length(tq[i]) - 1) > epsilon ? 1 : 0;
|
Error += (length(tq[i]) - 1) > epsilon ? 1 : 0;
|
||||||
|
|
||||||
for (glm::length_t j = 0; j<i; j++)
|
for (glm::length_t j = 0; j<i; j++)
|
||||||
Error += std::abs(dot(tq[i], tq[j])) > epsilon ? 1 : 0;
|
Error += glm::abs(dot(tq[i], tq[j])) > epsilon ? 1 : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
//Test if the matrix r is upper triangular
|
//Test if the matrix r is upper triangular
|
||||||
|
Loading…
x
Reference in New Issue
Block a user