summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/softpipe/sp_context.h
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2011-07-21 09:55:22 -0600
committerBrian Paul <brianp@vmware.com>2011-07-21 10:32:15 -0600
commit57aa597b3d5dac0fc59c05557dafec59e14e1019 (patch)
tree8b08868af2be97c6f2032fbc1363f4461d5ead34 /src/gallium/drivers/softpipe/sp_context.h
parentc534f11164bbecf25eb2b1e697f9511eceb0c86f (diff)
downloadexternal_mesa3d-57aa597b3d5dac0fc59c05557dafec59e14e1019.zip
external_mesa3d-57aa597b3d5dac0fc59c05557dafec59e14e1019.tar.gz
external_mesa3d-57aa597b3d5dac0fc59c05557dafec59e14e1019.tar.bz2
softpipe: use the polygon stipple utility module
This is an alternative to the draw module's polygon stipple stage. The softpipe implementation here is just a test. The advantange of using the new polygon stipple utility module (with other drivers) is we can avoid software vertex processing in the draw module and get much better performance. Polygon stipple doesn't require special vertex processing like the other draw module stage.
Diffstat (limited to 'src/gallium/drivers/softpipe/sp_context.h')
-rw-r--r--src/gallium/drivers/softpipe/sp_context.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/gallium/drivers/softpipe/sp_context.h b/src/gallium/drivers/softpipe/sp_context.h
index 79291ab..410b0a6 100644
--- a/src/gallium/drivers/softpipe/sp_context.h
+++ b/src/gallium/drivers/softpipe/sp_context.h
@@ -38,8 +38,11 @@
#include "sp_quad_pipe.h"
-/** Do polygon stipple in the driver here, or in the draw module? */
-#define DO_PSTIPPLE_IN_DRAW_MODULE 1
+/** Do polygon stipple in the draw module? */
+#define DO_PSTIPPLE_IN_DRAW_MODULE 0
+
+/** Do polygon stipple with the util module? */
+#define DO_PSTIPPLE_IN_HELPER_MODULE 1
struct softpipe_vbuf_render;
@@ -144,6 +147,13 @@ struct softpipe_context {
struct pipe_query *render_cond_query;
uint render_cond_mode;
+ /** Polygon stipple items */
+ struct {
+ struct pipe_resource *texture;
+ struct pipe_sampler_state *sampler;
+ struct pipe_sampler_view *sampler_view;
+ } pstipple;
+
/** Software quad rendering pipeline */
struct {
struct quad_stage *shade;