r600: clear position enable bit when when wpos is not used by FP
authorAndre Maasikas <amaasikas@gmail.com>
Tue, 29 Sep 2009 06:46:29 +0000 (09:46 +0300)
committerAlex Deucher <alexdeucher@gmail.com>
Thu, 15 Oct 2009 15:16:41 +0000 (11:16 -0400)
Makes doom3 alot nicer..

src/mesa/drivers/dri/r600/r700_fragprog.c

index 78ce3ae4366efe52f7b6090f8b1ab33359e8acfc..62a1ea1a22abd9b0fff2aaaf6e26e76fabd4b144 100644 (file)
@@ -341,6 +341,11 @@ GLboolean r700SetupFragmentProgram(GLcontext * ctx)
         SETbit(r700->SPI_PS_IN_CONTROL_0.u32All, POSITION_ENA_bit);
         SETbit(r700->SPI_INPUT_Z.u32All, PROVIDE_Z_TO_SPI_bit);
     }
+    else
+    {
+        CLEARbit(r700->SPI_PS_IN_CONTROL_0.u32All, POSITION_ENA_bit);
+        CLEARbit(r700->SPI_INPUT_Z.u32All, PROVIDE_Z_TO_SPI_bit);
+    }
 
     ui = (unNumOfReg < ui) ? ui : unNumOfReg;