summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/context.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2001-06-13 14:56:14 +0000
committerBrian Paul <[email protected]>2001-06-13 14:56:14 +0000
commitcd1cefae9146fc14b35ee93a04bdb1b1590fba7b (patch)
tree01f74b0349d478ed65822a3271ce7cdf8384a304 /src/mesa/main/context.c
parentcc22179cd855dad85a28c40416873a07e8b7cc0c (diff)
Allow different max texture sizes for 1/2D, 3D and cube maps.
Diffstat (limited to 'src/mesa/main/context.c')
-rw-r--r--src/mesa/main/context.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 9da1526535e..63c30f2ee5d 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -1,4 +1,4 @@
-/* $Id: context.c,v 1.142 2001/06/12 22:08:41 brianp Exp $ */
+/* $Id: context.c,v 1.143 2001/06/13 14:56:14 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -728,10 +728,13 @@ init_attrib_groups( GLcontext *ctx )
assert(ctx);
+ assert(MAX_TEXTURE_LEVELS >= MAX_3D_TEXTURE_LEVELS);
+ assert(MAX_TEXTURE_LEVELS >= MAX_CUBE_TEXTURE_LEVELS);
+
/* Constants, may be overriden by device drivers */
ctx->Const.MaxTextureLevels = MAX_TEXTURE_LEVELS;
- ctx->Const.MaxTextureSize = 1 << (MAX_TEXTURE_LEVELS - 1);
- ctx->Const.MaxCubeTextureSize = ctx->Const.MaxTextureSize;
+ ctx->Const.Max3DTextureLevels = MAX_3D_TEXTURE_LEVELS;
+ ctx->Const.MaxCubeTextureLevels = MAX_CUBE_TEXTURE_LEVELS;
ctx->Const.MaxTextureUnits = MAX_TEXTURE_UNITS;
ctx->Const.MaxTextureMaxAnisotropy = MAX_TEXTURE_MAX_ANISOTROPY;
ctx->Const.MaxArrayLockSize = MAX_ARRAY_LOCK_SIZE;