<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Hey Danylo,<br>
<br>
Thanks for this patch.<br>
I'm not really an expert here but my understanding is that it
should reflect the number of bits in fixed point precision.<br>
We use 32bits floats in the packets sent to the hardware.<br>
Quoting the spec :<br>
<br>
"If the implementation truely has floating point viewport bounds,
it may report a sufficiently high value to indicate this.
"<br class="Apple-interchange-newline">
<br>
Maybe we should use something a bit bigger than 8?<br>
<br>
Cheers,<br>
<br>
-<br>
Lionel<br>
<br>
On 18/06/18 13:50, Danylo Piliaiev wrote:<br>
</div>
<blockquote type="cite"
cite="mid:1529326361-16523-1-git-send-email-danylo.piliaiev@globallogic.com">
<pre wrap="">We use floating-points for viewport bounds so VIEWPORT_SUBPIXEL_BITS
should reflect this.
Bugzilla: <a class="moz-txt-link-freetext" href="https://bugs.freedesktop.org/show_bug.cgi?id=105975">https://bugs.freedesktop.org/show_bug.cgi?id=105975</a>
Signed-off-by: Danylo Piliaiev <a class="moz-txt-link-rfc2396E" href="mailto:danylo.piliaiev@globallogic.com"><danylo.piliaiev@globallogic.com></a>
---
src/mesa/drivers/dri/i965/brw_context.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
index 9ced230..eacf326 100644
--- a/src/mesa/drivers/dri/i965/brw_context.c
+++ b/src/mesa/drivers/dri/i965/brw_context.c
@@ -688,7 +688,7 @@ brw_initialize_context_constants(struct brw_context *brw)
/* ARB_viewport_array, OES_viewport_array */
if (devinfo->gen >= 6) {
ctx->Const.MaxViewports = GEN6_NUM_VIEWPORTS;
- ctx->Const.ViewportSubpixelBits = 0;
+ ctx->Const.ViewportSubpixelBits = 8;
/* Cast to float before negating because MaxViewportWidth is unsigned.
*/
</pre>
</blockquote>
<p><br>
</p>
</body>
</html>