summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/llvmpipe/lp_state.h
diff options
context:
space:
mode:
authorJosé Fonseca <jfonseca@vmware.com>2009-08-19 20:42:50 +0100
committerJosé Fonseca <jfonseca@vmware.com>2009-08-29 09:21:37 +0100
commit9ae47069b4a2b67e381b02d805f1ca74f31ea7b8 (patch)
tree69928d0be32cc2efe339791ed815920365ccfd9d /src/gallium/drivers/llvmpipe/lp_state.h
parentb5e397c3693fbae6b2c91c602454d9a70651c9c4 (diff)
llvmpipe: Code generate alpha testing and append to generated fragment shader.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_state.h')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_state.h27
1 files changed, 25 insertions, 2 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_state.h b/src/gallium/drivers/llvmpipe/lp_state.h
index f8b3793a59..db21096f21 100644
--- a/src/gallium/drivers/llvmpipe/lp_state.h
+++ b/src/gallium/drivers/llvmpipe/lp_state.h
@@ -70,6 +70,28 @@ typedef void
void *depth,
struct tgsi_sampler **samplers);
+
+struct lp_fragment_shader;
+
+
+/**
+ * Subclass of pipe_shader_state (though it doesn't really need to be).
+ *
+ * This is starting to look an awful lot like a quad pipeline stage...
+ */
+struct lp_fragment_shader_variant
+{
+ struct lp_fragment_shader *shader;
+ struct pipe_alpha_state alpha;
+
+ LLVMValueRef function;
+
+ lp_shader_fs_func jit_function;
+
+ struct lp_fragment_shader_variant *next;
+};
+
+
/**
* Subclass of pipe_shader_state (though it doesn't really need to be).
*
@@ -83,9 +105,9 @@ struct lp_fragment_shader
struct llvmpipe_screen *screen;
- LLVMValueRef function;
+ struct lp_fragment_shader_variant *variants;
- lp_shader_fs_func jit_function;
+ struct lp_fragment_shader_variant *current;
};
@@ -183,6 +205,7 @@ void llvmpipe_set_vertex_buffers(struct pipe_context *,
unsigned count,
const struct pipe_vertex_buffer *);
+void llvmpipe_update_fs(struct llvmpipe_context *lp);
void llvmpipe_update_derived( struct llvmpipe_context *llvmpipe );