Fixed missing std:: namespace #898

This commit is contained in:
Christophe Riccio
2019-09-07 13:41:08 +02:00
parent 823125a6cd
commit 61b2a73e21
17 changed files with 238 additions and 228 deletions

View File

@@ -33,10 +33,10 @@ int test_log2()
Error += glm::abs(double(A) - B) <= 24 ? 0 : 1;
assert(!Error);
printf("Log2(%d) error A=%d, B=%d\n", 1 << i, A, B);
std::printf("Log2(%d) error A=%d, B=%d\n", 1 << i, A, B);
}
printf("log2 error=%d\n", Error);
std::printf("log2 error=%d\n", Error);
return Error;
}

View File

@@ -17,7 +17,7 @@ int test_decl()
glm::vec4 B;
};
printf("vec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
std::printf("vec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
Error += sizeof(S1) >= sizeof(S2) ? 0 : 1;
}
@@ -35,7 +35,7 @@ int test_decl()
glm::aligned_vec3 B;
};
printf("vec3 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
std::printf("vec3 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
Error += sizeof(S1) <= sizeof(S2) ? 0 : 1;
}
@@ -53,7 +53,7 @@ int test_decl()
glm::vec4 B;
};
printf("vec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
std::printf("vec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
Error += sizeof(S1) >= sizeof(S2) ? 0 : 1;
}
@@ -71,7 +71,7 @@ int test_decl()
glm::dvec4 B;
};
printf("dvec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
std::printf("dvec4 - Aligned: %d, unaligned: %d\n", static_cast<int>(sizeof(S1)), static_cast<int>(sizeof(S2)));
Error += sizeof(S1) >= sizeof(S2) ? 0 : 1;
}
@@ -82,11 +82,11 @@ int test_decl()
template<typename genType>
void print(genType const& Mat0)
{
printf("mat4(\n");
printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[0][0]), static_cast<double>(Mat0[0][1]), static_cast<double>(Mat0[0][2]), static_cast<double>(Mat0[0][3]));
printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[1][0]), static_cast<double>(Mat0[1][1]), static_cast<double>(Mat0[1][2]), static_cast<double>(Mat0[1][3]));
printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[2][0]), static_cast<double>(Mat0[2][1]), static_cast<double>(Mat0[2][2]), static_cast<double>(Mat0[2][3]));
printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f))\n\n", static_cast<double>(Mat0[3][0]), static_cast<double>(Mat0[3][1]), static_cast<double>(Mat0[3][2]), static_cast<double>(Mat0[3][3]));
std::printf("mat4(\n");
std::printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[0][0]), static_cast<double>(Mat0[0][1]), static_cast<double>(Mat0[0][2]), static_cast<double>(Mat0[0][3]));
std::printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[1][0]), static_cast<double>(Mat0[1][1]), static_cast<double>(Mat0[1][2]), static_cast<double>(Mat0[1][3]));
std::printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f)\n", static_cast<double>(Mat0[2][0]), static_cast<double>(Mat0[2][1]), static_cast<double>(Mat0[2][2]), static_cast<double>(Mat0[2][3]));
std::printf("\tvec4(%2.9f, %2.9f, %2.9f, %2.9f))\n\n", static_cast<double>(Mat0[3][0]), static_cast<double>(Mat0[3][1]), static_cast<double>(Mat0[3][2]), static_cast<double>(Mat0[3][3]));
}
int perf_mul()