summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/context.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2001-07-26 20:02:10 +0000
committerBrian Paul <[email protected]>2001-07-26 20:02:10 +0000
commit172281dad8d1f1d32f5f31583a5fa565aa1bf5da (patch)
tree98cf5d057fe7f1c03868a27664ad9f9fb828e090 /src/mesa/main/context.c
parente2df5de01cbaf73c7f2b52459b318f9951f1e85a (diff)
fixes for proxy cube map texture images
Diffstat (limited to 'src/mesa/main/context.c')
-rw-r--r--src/mesa/main/context.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 4f2718140de..7576c8bc2c0 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -1,4 +1,4 @@
-/* $Id: context.c,v 1.145 2001/07/19 15:54:34 brianp Exp $ */
+/* $Id: context.c,v 1.146 2001/07/26 20:02:10 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -1351,9 +1351,11 @@ alloc_proxy_textures( GLcontext *ctx )
ctx->Texture.Proxy1D->Image[i] = _mesa_alloc_texture_image();
ctx->Texture.Proxy2D->Image[i] = _mesa_alloc_texture_image();
ctx->Texture.Proxy3D->Image[i] = _mesa_alloc_texture_image();
+ ctx->Texture.ProxyCubeMap->Image[i] = _mesa_alloc_texture_image();
if (!ctx->Texture.Proxy1D->Image[i]
|| !ctx->Texture.Proxy2D->Image[i]
- || !ctx->Texture.Proxy3D->Image[i]) {
+ || !ctx->Texture.Proxy3D->Image[i]
+ || !ctx->Texture.ProxyCubeMap->Image[i]) {
out_of_memory = GL_TRUE;
}
}
@@ -1368,10 +1370,14 @@ alloc_proxy_textures( GLcontext *ctx )
if (ctx->Texture.Proxy3D->Image[i]) {
_mesa_free_texture_image(ctx->Texture.Proxy3D->Image[i]);
}
+ if (ctx->Texture.ProxyCubeMap->Image[i]) {
+ _mesa_free_texture_image(ctx->Texture.ProxyCubeMap->Image[i]);
+ }
}
_mesa_free_texture_object(NULL, ctx->Texture.Proxy1D);
_mesa_free_texture_object(NULL, ctx->Texture.Proxy2D);
_mesa_free_texture_object(NULL, ctx->Texture.Proxy3D);
+ _mesa_free_texture_object(NULL, ctx->Texture.ProxyCubeMap);
return GL_FALSE;
}
else {