Fix and enable warning C4244 (Conversion from 'type1' to 'type2', possible loss of data)
Change-Id: Id0e06d7d6600344d858f00dabc219d79289bbc82
Reviewed-on: https://chromium-review.googlesource.com/265020
Tested-by: Minmin Gong <mgong@microsoft.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
diff --git a/src/tests/end2end_tests/IndexedPointsTest.cpp b/src/tests/end2end_tests/IndexedPointsTest.cpp
index 043ba28..026db32 100644
--- a/src/tests/end2end_tests/IndexedPointsTest.cpp
+++ b/src/tests/end2end_tests/IndexedPointsTest.cpp
@@ -103,8 +103,8 @@
for (size_t i = 0; i < mPointCount; i++)
{
- GLuint x = viewportSize[0] + (getIndexPositionX(i) * 0.5f + 0.5f) * (viewportSize[2] - viewportSize[0]);
- GLuint y = viewportSize[1] + (getIndexPositionY(i) * 0.5f + 0.5f) * (viewportSize[3] - viewportSize[1]);
+ GLuint x = static_cast<GLuint>(viewportSize[0] + (getIndexPositionX(i) * 0.5f + 0.5f) * (viewportSize[2] - viewportSize[0]));
+ GLuint y = static_cast<GLuint>(viewportSize[1] + (getIndexPositionY(i) * 0.5f + 0.5f) * (viewportSize[3] - viewportSize[1]));
if (i < firstIndex)
{