From f8a647883a14694f1b758c12187b3f35b9d039a7 Mon Sep 17 00:00:00 2001 From: Matt Turner Date: Sat, 11 Jul 2015 22:46:19 -0700 Subject: mesa: Use floats for viewport bounds. ARB_viewport_array specifies that DEPTH_RANGE consists of double- precision parameters (corresponding commit d4dc35987), and a preparatory commit (6340e609a) added _mesa_get_viewport_xform() which returned double-precision scale[3] and translate[3] vectors, even though X, Y, Width, and Height were still floats. All users of _mesa_get_viewport_xform() immediately convert the double scale and translation vectors into floats (which were floats originally, but were converted to doubles in _mesa_get_viewport_xform(), sigh). i965 at least cannot consume doubles (see SF_CLIP_VIEWPORT). If we want to pass doubles to hardware, we should have a different function that does that. Acked-by: Mathias Froehlich --- src/mesa/main/viewport.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/main/viewport.h') diff --git a/src/mesa/main/viewport.h b/src/mesa/main/viewport.h index 899dc2d0bcc..b0675db1096 100644 --- a/src/mesa/main/viewport.h +++ b/src/mesa/main/viewport.h @@ -73,6 +73,6 @@ _mesa_ClipControl(GLenum origin, GLenum depth); extern void _mesa_get_viewport_xform(struct gl_context *ctx, unsigned i, - double scale[3], double translate[3]); + float scale[3], float translate[3]); #endif -- cgit v1.2.3