diff --git a/test/gtc/gtc_round.cpp b/test/gtc/gtc_round.cpp index aa6cf1a1..074987f6 100644 --- a/test/gtc/gtc_round.cpp +++ b/test/gtc/gtc_round.cpp @@ -354,7 +354,7 @@ namespace ceilMultiple }; int Error(0); - + for(std::size_t i = 0, n = sizeof(Data) / sizeof(type); i < n; ++i) { glm::float64 Result = glm::ceilMultiple(Data[i].Source, Data[i].Multiple); @@ -364,10 +364,31 @@ namespace ceilMultiple return Error; } + int test_int() + { + type const Data[] = + { + {3, 4, 4}, + {7, 8, 4}, + {5, 8, 4}, + }; + + int Error(0); + + for(std::size_t i = 0, n = sizeof(Data) / sizeof(type); i < n; ++i) + { + int Result = glm::ceilMultiple(Data[i].Source, Data[i].Multiple); + Error += Data[i].Return == Result ? 0 : 1; + } + + return Error; + } + int test() { int Error(0); + Error += test_int(); Error += test_float(); return Error;