summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mesa/main/uniform_query.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/main/uniform_query.cpp b/src/mesa/main/uniform_query.cpp
index 2fdbc83be24..e6c78bf69c3 100644
--- a/src/mesa/main/uniform_query.cpp
+++ b/src/mesa/main/uniform_query.cpp
@@ -471,7 +471,7 @@ _mesa_get_uniform(struct gl_context *ctx, GLuint program, GLint location,
* a floating-point value is rounded to the
* nearest integer..."
*/
- dst[didx].i = IROUND(src[sidx].f);
+ dst[didx].i = (int64_t) roundf(src[sidx].f);
break;
case GLSL_TYPE_BOOL:
dst[didx].i = src[sidx].i ? 1 : 0;
@@ -482,7 +482,7 @@ _mesa_get_uniform(struct gl_context *ctx, GLuint program, GLint location,
case GLSL_TYPE_DOUBLE: {
double tmp;
memcpy(&tmp, &src[sidx].f, sizeof(tmp));
- dst[didx].i = IROUNDD(tmp);
+ dst[didx].i = (int64_t) round(tmp);
break;
}
case GLSL_TYPE_UINT64: {