Don't emit HC_SubA_HSPXYOS on CLE266.
authorKeith Whitwell <keith@tungstengraphics.com>
Wed, 12 Jan 2005 17:20:08 +0000 (17:20 +0000)
committerKeith Whitwell <keith@tungstengraphics.com>
Wed, 12 Jan 2005 17:20:08 +0000 (17:20 +0000)
src/mesa/drivers/dri/unichrome/via_ioctl.c

index 30ca7f67553525be80b44fa36aef38943f2e298d..efb7cf6b6cf21a049ff5b8835dc8c577fc7bab50 100644 (file)
@@ -531,11 +531,19 @@ static void via_emit_cliprect(viaContextPtr vmesa,
            
    vb[4] = ((HC_SubA_HDBBasL << 24) | (offset & 0xFFFFFF));
    vb[5] = ((HC_SubA_HDBBasH << 24) | ((offset & 0xFF000000)) >> 24); 
-   vb[6] = ((HC_SubA_HDBFM << 24) | HC_HDBLoc_Local | format | pitch);     
 
-   /* Seems to be ignored on CLE266:
+   /* HSPXYOS seems to be ignored on CLE266, don't emit.  This is
+    * required for hardware stipple conformance (as long as we still
+    * have drawXoff).
     */
-   vb[7] = ((HC_SubA_HSPXYOS << 24) | ((32 - vmesa->drawXoff) << HC_HSPXOS_SHIFT));
+   if (vmesa->viaScreen->deviceID == VIA_CLE266) {
+      vb[6] = HC_DUMMY;
+      vb[7] = ((HC_SubA_HDBFM << 24) | HC_HDBLoc_Local | format | pitch);     
+   }
+   else {
+      vb[6] = ((HC_SubA_HDBFM << 24) | HC_HDBLoc_Local | format | pitch);     
+      vb[7] = ((HC_SubA_HSPXYOS << 24) | ((32 - vmesa->drawXoff) << HC_HSPXOS_SHIFT));
+   }
 }