summaryrefslogtreecommitdiffstats
path: root/src/mesa/pipe/p_state.h
diff options
context:
space:
mode:
authorBrian <[email protected]>2008-02-12 14:53:25 -0700
committerBrian <[email protected]>2008-02-12 14:53:25 -0700
commit4da1cdf78fa3b954840650fa46cf72da5daf149f (patch)
tree0496f6f4364e3608f7bb7af2a549a9ba3a898252 /src/mesa/pipe/p_state.h
parentb61b1a295b13a0ff2cf98c8d07e62147d71c08b9 (diff)
gallium: clean-up, simplification of mipmapped textures
Remove pipe_texture->first_level (always implicitly zero). This means there's never any unused mipmap levels at the top. In the state tracker, we no longer re-layout mipmapped textures if the MinLod/MaxLod texture parameters change. It's up to the driver to obey the pipe_sampler->min/max_lod clamps.
Diffstat (limited to 'src/mesa/pipe/p_state.h')
-rw-r--r--src/mesa/pipe/p_state.h14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/mesa/pipe/p_state.h b/src/mesa/pipe/p_state.h
index 83ca43f6785..4d3a6b2f413 100644
--- a/src/mesa/pipe/p_state.h
+++ b/src/mesa/pipe/p_state.h
@@ -234,14 +234,9 @@ struct pipe_sampler_state
unsigned compare_mode:1; /**< PIPE_TEX_COMPARE_x */
unsigned compare_func:3; /**< PIPE_FUNC_x */
unsigned normalized_coords:1; /**< Are coords normalized to [0,1]? */
- float shadow_ambient; /**< shadow test fail color/intensity */
- float min_lod;
- float max_lod;
- float lod_bias;
-#if 0 /* need these? */
- int BaseLevel; /**< min mipmap level, OpenGL 1.2 */
- int MaxLevel; /**< max mipmap level, OpenGL 1.2 */
-#endif
+ float shadow_ambient; /**< shadow test fail color/intensity */
+ float lod_bias; /**< LOD/lambda bias */
+ float min_lod, max_lod; /**< LOD clamp range, after bias */
float border_color[4];
float max_anisotropy;
};
@@ -277,8 +272,7 @@ struct pipe_texture
enum pipe_texture_target target; /**< PIPE_TEXTURE_x */
enum pipe_format format; /**< PIPE_FORMAT_x */
- unsigned first_level;
- unsigned last_level;
+ unsigned last_level; /**< Index of last mipmap level present/defined */
unsigned width[PIPE_MAX_TEXTURE_LEVELS];
unsigned height[PIPE_MAX_TEXTURE_LEVELS];