r300g: define R300_MAX_TEXTURE_LEVELS
authorBrian Paul <brianp@vmware.com>
Mon, 8 Mar 2010 21:01:30 +0000 (14:01 -0700)
committerBrian Paul <brianp@vmware.com>
Mon, 8 Mar 2010 23:26:44 +0000 (16:26 -0700)
src/gallium/drivers/r300/r300_context.h

index 8c52d880a365af66aa1188c0219bca969fd3da87..c2825d5f2676923349d0de20758fa71ff8714421 100644 (file)
@@ -124,13 +124,15 @@ struct r300_texture_format_state {
     uint32_t format2; /* R300_TX_FORMAT2: 0x4500 */
 };
 
+#define R300_MAX_TEXTURE_LEVELS 13
+
 struct r300_texture_fb_state {
     /* Colorbuffer. */
-    uint32_t colorpitch[PIPE_MAX_TEXTURE_LEVELS]; /* R300_RB3D_COLORPITCH[0-3]*/
+    uint32_t colorpitch[R300_MAX_TEXTURE_LEVELS]; /* R300_RB3D_COLORPITCH[0-3]*/
     uint32_t us_out_fmt; /* R300_US_OUT_FMT[0-3] */
 
     /* Zbuffer. */
-    uint32_t depthpitch[PIPE_MAX_TEXTURE_LEVELS]; /* R300_RB3D_DEPTHPITCH */
+    uint32_t depthpitch[R300_MAX_TEXTURE_LEVELS]; /* R300_RB3D_DEPTHPITCH */
     uint32_t zb_format; /* R300_ZB_FORMAT */
 };
 
@@ -236,16 +238,16 @@ struct r300_texture {
     struct pipe_texture tex;
 
     /* Offsets into the buffer. */
-    unsigned offset[PIPE_MAX_TEXTURE_LEVELS];
+    unsigned offset[R300_MAX_TEXTURE_LEVELS];
 
     /* A pitch for each mip-level */
-    unsigned pitch[PIPE_MAX_TEXTURE_LEVELS];
+    unsigned pitch[R300_MAX_TEXTURE_LEVELS];
 
     /* Size of one zslice or face based on the texture target */
-    unsigned layer_size[PIPE_MAX_TEXTURE_LEVELS];
+    unsigned layer_size[R300_MAX_TEXTURE_LEVELS];
 
     /* Whether the mipmap level is macrotiled. */
-    enum r300_buffer_tiling mip_macrotile[PIPE_MAX_TEXTURE_LEVELS];
+    enum r300_buffer_tiling mip_macrotile[R300_MAX_TEXTURE_LEVELS];
 
     /**
      * If non-zero, override the natural texture layout with