nv20: set surface status in clear()
[mesa.git] / src / gallium / drivers / softpipe / sp_headers.h
index 0ae31d87961e68db4d377dbbd950fb7987939079..4a42cb3c192d965dbd71dd59cbaeacee1c1e830b 100644 (file)
@@ -31,7 +31,8 @@
 #ifndef SP_HEADERS_H
 #define SP_HEADERS_H
 
-#include "pipe/tgsi/exec/tgsi_exec.h"
+#include "pipe/p_state.h"
+#include "tgsi/tgsi_exec.h"
 
 #define PRIM_POINT 1
 #define PRIM_LINE  2
  * Encodes everything we need to know about a 2x2 pixel block.  Uses
  * "Channel-Serial" or "SoA" layout.  
  */
-struct quad_header {
+struct quad_header_input
+{
    int x0;
    int y0;
-   unsigned mask:4;
+   float coverage[QUAD_SIZE];    /** fragment coverage for antialiasing */
    unsigned facing:1;   /**< Front (0) or back (1) facing? */
    unsigned prim:2;     /**< PRIM_POINT, LINE, TRI */
+};
+
+struct quad_header_inout
+{
+   unsigned mask:4;
+};
 
-   struct {
-      float color[NUM_CHANNELS][QUAD_SIZE];    /* rrrr, gggg, bbbb, aaaa */
-      float depth[QUAD_SIZE];
-   } outputs;
+struct quad_header_output
+{
+   /** colors in SOA format (rrrr, gggg, bbbb, aaaa) */
+   float color[PIPE_MAX_COLOR_BUFS][NUM_CHANNELS][QUAD_SIZE];
+   float depth[QUAD_SIZE];
+};
 
-   float coverage[QUAD_SIZE];    /** fragment coverage for antialiasing */
+struct quad_header {
+   struct quad_header_input input;
+   struct quad_header_inout inout;
+   struct quad_header_output output;
 
    const struct tgsi_interp_coef *coef;
    const struct tgsi_interp_coef *posCoef;
@@ -78,5 +91,5 @@ struct quad_header {
    unsigned nr_attrs;
 };
 
-
 #endif /* SP_HEADERS_H */
+