Mesa (master): nvfx: fix support for more than 8 texture units ( fixes etqw crash)
Luca Barbieri
lb at kemper.freedesktop.org
Fri Sep 3 14:16:54 UTC 2010
Module: Mesa
Branch: master
Commit: 6ddfdaead85df873de96939239013c772dca745f
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=6ddfdaead85df873de96939239013c772dca745f
Author: Luca Barbieri <luca at luca-barbieri.com>
Date: Fri Sep 3 15:44:27 2010 +0200
nvfx: fix support for more than 8 texture units (fixes etqw crash)
---
src/gallium/drivers/nvfx/nvfx_context.h | 4 ++--
src/gallium/drivers/nvfx/nvfx_screen.c | 3 +--
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/gallium/drivers/nvfx/nvfx_context.h b/src/gallium/drivers/nvfx/nvfx_context.h
index 4c654bf..9e46f5d 100644
--- a/src/gallium/drivers/nvfx/nvfx_context.h
+++ b/src/gallium/drivers/nvfx/nvfx_context.h
@@ -199,8 +199,8 @@ struct nvfx_context {
int use_vertex_buffers;
unsigned hw_vtxelt_nr;
- uint8_t hw_samplers;
- uint32_t hw_txf[8];
+ unsigned hw_samplers;
+ uint32_t hw_txf[16];
struct nvfx_render_target hw_rt[4];
struct nvfx_render_target hw_zeta;
int hw_pointsprite_control;
diff --git a/src/gallium/drivers/nvfx/nvfx_screen.c b/src/gallium/drivers/nvfx/nvfx_screen.c
index 65ca265..affed96 100644
--- a/src/gallium/drivers/nvfx/nvfx_screen.c
+++ b/src/gallium/drivers/nvfx/nvfx_screen.c
@@ -25,8 +25,7 @@ nvfx_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
switch (param) {
case PIPE_CAP_MAX_TEXTURE_IMAGE_UNITS:
- /* TODO: check this */
- return screen->is_nv4x ? 16 : 8;
+ return 16;
case PIPE_CAP_NPOT_TEXTURES:
return !!screen->is_nv4x;
case PIPE_CAP_TWO_SIDED_STENCIL:
More information about the mesa-commit
mailing list