i965: Advertise 8 bits subpixel precision for viewport bounds on gen6+
authorDanylo Piliaiev <danylo.piliaiev@gmail.com>
Mon, 18 Jun 2018 12:50:57 +0000 (15:50 +0300)
committerLionel Landwerlin <lionel.g.landwerlin@intel.com>
Mon, 20 Aug 2018 14:11:57 +0000 (15:11 +0100)
We use floating-points for viewport bounds so VIEWPORT_SUBPIXEL_BITS
should reflect this.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105975

Signed-off-by: Danylo Piliaiev <danylo.piliaiev@globallogic.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/mesa/drivers/dri/i965/brw_context.c

index 0d0b95e78a5ae354c43c4d9b8df56e2a797ca95f..0c551d774c9d50834461352edc5013d03497c165 100644 (file)
@@ -695,7 +695,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.
        */