aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/cell/common.h
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2008-09-10 18:22:00 -0600
committerBrian Paul <[email protected]>2008-09-11 10:39:28 -0600
commit284ab5a6127f8b452acaa0e10ac1d9ebc87fac3e (patch)
tree9a443b1d850966178360b17d208e28a1d05481c0 /src/gallium/drivers/cell/common.h
parentee582fd3a7a9ddbcb5595249201cf213a6c6f014 (diff)
cell: checkpoint commit of new per-fragment processing
Do code generation for alpha test, z test, stencil, blend, colormask and framebuffer/tile read/write as a single code block. Ian's previous blend/z/stencil test code is still there but mostly disabled and will be removed soon.
Diffstat (limited to 'src/gallium/drivers/cell/common.h')
-rw-r--r--src/gallium/drivers/cell/common.h20
1 files changed, 17 insertions, 3 deletions
diff --git a/src/gallium/drivers/cell/common.h b/src/gallium/drivers/cell/common.h
index c0ca201e1d1..a62530c64da 100644
--- a/src/gallium/drivers/cell/common.h
+++ b/src/gallium/drivers/cell/common.h
@@ -97,6 +97,7 @@
#define CELL_CMD_STATE_LOGICOP 21
#define CELL_CMD_VS_EXECUTE 22
#define CELL_CMD_FLUSH_BUFFER_RANGE 23
+#define CELL_CMD_STATE_FRAGMENT_OPS 24
#define CELL_NUM_BUFFERS 4
@@ -112,30 +113,43 @@
/**
*/
-struct cell_command_depth_stencil_alpha_test {
+struct cell_command_depth_stencil_alpha_test
+{
uint64_t base; /**< Effective address of code start. */
unsigned size; /**< Size in bytes of SPE code. */
unsigned read_depth; /**< Flag: should depth be read? */
unsigned read_stencil; /**< Flag: should stencil be read? */
+ struct pipe_depth_stencil_alpha_state state;
};
/**
* Upload code to perform framebuffer blend operation
*/
-struct cell_command_blend {
+struct cell_command_blend
+{
uint64_t base; /**< Effective address of code start. */
unsigned size; /**< Size in bytes of SPE code. */
unsigned read_fb; /**< Flag: should framebuffer be read? */
};
-struct cell_command_logicop {
+struct cell_command_logicop
+{
uint64_t base; /**< Effective address of code start. */
unsigned size; /**< Size in bytes of SPE code. */
};
+#define SPU_MAX_FRAGMENT_OPS_INSTS 64
+
+struct cell_command_fragment_ops
+{
+ uint64_t opcode; /**< CELL_CMD_STATE_FRAGMENT_OPS */
+ unsigned code[SPU_MAX_FRAGMENT_OPS_INSTS];
+};
+
+
/**
* Tell SPUs about the framebuffer size, location
*/