[Mesa-dev] [PATCH] svga: fix default case in svga_get_sample_position()
Brian Paul
brianp at vmware.com
Thu Jul 20 15:15:51 UTC 2017
If called for an unsupported number of samples, always return (.5, .5).
Fixes the Piglit arb_texture_multisample-fb-completeness test for
unsupported sample counts, such as 2.
Ideally, this function should not get called for unsupported sample
counts, but that'll be additional work...
---
src/gallium/drivers/svga/svga_surface.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/gallium/drivers/svga/svga_surface.c b/src/gallium/drivers/svga/svga_surface.c
index d7c9850..64a85cf 100644
--- a/src/gallium/drivers/svga/svga_surface.c
+++ b/src/gallium/drivers/svga/svga_surface.c
@@ -899,6 +899,7 @@ svga_get_sample_position(struct pipe_context *context,
break;
default:
positions = pos1;
+ sample_index = 0;
}
pos_out[0] = positions[sample_index][0];
--
1.9.1
More information about the mesa-dev
mailing list