st/python: adapt to blend changes
authorRoland Scheidegger <sroland@vmware.com>
Mon, 25 Jan 2010 15:34:29 +0000 (16:34 +0100)
committerRoland Scheidegger <sroland@vmware.com>
Mon, 25 Jan 2010 15:34:29 +0000 (16:34 +0100)
src/gallium/state_trackers/python/samples/gs.py
src/gallium/state_trackers/python/samples/tri.py
src/gallium/state_trackers/python/st_device.c
src/gallium/state_trackers/python/tests/regress/fragment-shader/fragment-shader.py
src/gallium/state_trackers/python/tests/regress/vertex-shader/vertex-shader.py
src/gallium/state_trackers/python/tests/texture_render.py
src/gallium/state_trackers/python/tests/texture_sample.py

index a07cf557f2f14f4d4d2b849da5315ca9a98955c0..cd68abac9a163ab4c7d7d565b57a33f587c41afe 100644 (file)
@@ -72,11 +72,11 @@ def test(dev):
 
     # disabled blending/masking
     blend = Blend()
-    blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.colormask = PIPE_MASK_RGBA
+    blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].colormask = PIPE_MASK_RGBA
     ctx.set_blend(blend)
 
     # depth/stencil/alpha
index e5e168bdc8df06c2a39ca5791fde789d0f65b9f6..f0b5e3dc9842d597de7c79640bbc1cdd9806bc8e 100644 (file)
@@ -72,11 +72,11 @@ def test(dev):
 
     # disabled blending/masking
     blend = Blend()
-    blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.colormask = PIPE_MASK_RGBA
+    blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].colormask = PIPE_MASK_RGBA
     ctx.set_blend(blend)
 
     # depth/stencil/alpha
index d144af2447d1d8c0955f9b8acd5ba0ee1d723694..e41125f6f9940d24be280300eae613d2795fbdd0 100644 (file)
@@ -180,11 +180,11 @@ st_context_create(struct st_device *st_dev)
    {
       struct pipe_blend_state blend;
       memset(&blend, 0, sizeof(blend));
-      blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE;
-      blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE;
-      blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO;
-      blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO;
-      blend.colormask = PIPE_MASK_RGBA;
+      blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE;
+      blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE;
+      blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO;
+      blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO;
+      blend.rt[0].colormask = PIPE_MASK_RGBA;
       cso_set_blend(st_ctx->cso, &blend);
    }
 
index 8d3bf9d4d7e27d1b862176a646e191c6cc58dfc2..e9d844c71895e355522185055ff541bc926d20bc 100644 (file)
@@ -50,11 +50,11 @@ def test(dev, name):
 
     # disabled blending/masking
     blend = Blend()
-    blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.colormask = PIPE_MASK_RGBA
+    blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].colormask = PIPE_MASK_RGBA
     ctx.set_blend(blend)
 
     # depth/stencil/alpha
index 01bf5a3210d0f9bcade5a71d193d4947333fea41..a185474fa39e74a377046d7b885b2ff53c2b819e 100644 (file)
@@ -50,11 +50,11 @@ def test(dev, name):
 
     # disabled blending/masking
     blend = Blend()
-    blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-    blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-    blend.colormask = PIPE_MASK_RGBA
+    blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+    blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+    blend.rt[0].colormask = PIPE_MASK_RGBA
     ctx.set_blend(blend)
 
     # depth/stencil/alpha
index 79287f2caceaa115907cd1b9d7a588ea71d13598..0fac1ea5ef303c9b937ec951123e3e6b2b50b2e0 100755 (executable)
@@ -115,11 +115,11 @@ class TextureTest(TestCase):
     
         # disabled blending/masking
         blend = Blend()
-        blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.colormask = PIPE_MASK_RGBA
+        blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].colormask = PIPE_MASK_RGBA
         ctx.set_blend(blend)
     
         # no-op depth/stencil/alpha
index 520961c8051ef9e98f002c9312827dbfe1bab747..db32b537a1733f0d79c99f81045376be639a95a7 100755 (executable)
@@ -140,11 +140,11 @@ class TextureColorSampleTest(TestCase):
     
         # disabled blending/masking
         blend = Blend()
-        blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.colormask = PIPE_MASK_RGBA
+        blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].colormask = PIPE_MASK_RGBA
         ctx.set_blend(blend)
     
         # no-op depth/stencil/alpha
@@ -327,11 +327,11 @@ class TextureDepthSampleTest(TestCase):
     
         # disabled blending/masking
         blend = Blend()
-        blend.rgb_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.alpha_src_factor = PIPE_BLENDFACTOR_ONE
-        blend.rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
-        blend.colormask = PIPE_MASK_RGBA
+        blend.rt[0].rgb_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].alpha_src_factor = PIPE_BLENDFACTOR_ONE
+        blend.rt[0].rgb_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].alpha_dst_factor = PIPE_BLENDFACTOR_ZERO
+        blend.rt[0].colormask = PIPE_MASK_RGBA
         ctx.set_blend(blend)
     
         # depth/stencil/alpha