llvmpipe: Fix MSVC build.
[mesa.git] / src / gallium / drivers / llvmpipe / lp_state_fs.h
index 593cd4de6beefa5fdf2a1e82e600fc55578fe21a..ddad117acacdfbe4ff626ad35b50264a1b56df19 100644 (file)
@@ -34,6 +34,7 @@
 #include "pipe/p_state.h"
 #include "tgsi/tgsi_scan.h" /* for tgsi_shader_info */
 #include "gallivm/lp_bld_sample.h" /* for struct lp_sampler_static_state */
+#include "gallivm/lp_bld_tgsi.h" /* for lp_tgsi_info */
 
 
 struct tgsi_token;
@@ -49,17 +50,20 @@ struct lp_fragment_shader_variant_key
 {
    struct pipe_depth_state depth;
    struct pipe_stencil_state stencil[2];
-   struct pipe_alpha_state alpha;
    struct pipe_blend_state blend;
-   enum pipe_format zsbuf_format;
+
+   struct {
+      unsigned enabled:1;
+      unsigned func:3;
+   } alpha;
+
    unsigned nr_cbufs:8;
+   unsigned nr_samplers:8;     /* actually derivable from just the shader */
    unsigned flatshade:1;
-   unsigned scissor:1;
    unsigned occlusion_count:1;
 
-   struct {
-      ubyte colormask;
-   } cbuf_blend[PIPE_MAX_COLOR_BUFS];
+   enum pipe_format zsbuf_format;
+   enum pipe_format cbuf_format[PIPE_MAX_COLOR_BUFS];
 
    struct lp_sampler_static_state sampler[PIPE_MAX_SAMPLERS];
 };
@@ -93,15 +97,22 @@ struct lp_fragment_shader
 {
    struct pipe_shader_state base;
 
-   struct tgsi_shader_info info;
+   struct lp_tgsi_info info;
 
    struct lp_fs_variant_list_item variants;
 
+   struct draw_fragment_shader *draw_data;
+
    /* For debugging/profiling purposes */
+   unsigned variant_key_size;
    unsigned no;
    unsigned variants_created;
    unsigned variants_cached;
 };
 
 
+void
+lp_debug_fs_variant(const struct lp_fragment_shader_variant *variant);
+
+
 #endif /* LP_STATE_FS_H_ */