From 0acb057ad16264b976b00aa7c6ecf285ca8c19e7 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 23 Oct 2009 16:36:15 -0600 Subject: mesa: fix broken _mesa_str_checksum() --- src/mesa/main/imports.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/mesa/main/imports.c b/src/mesa/main/imports.c index 30fa55997e..91d8d156b8 100644 --- a/src/mesa/main/imports.c +++ b/src/mesa/main/imports.c @@ -934,9 +934,9 @@ _mesa_str_checksum(const char *str) unsigned int sum, i; const char *c; sum = i = 1; - for (c = str; *c; c++) + for (c = str; *c; c++, i++) sum += *c * (i % 100); - return sum; + return sum + i; } -- cgit v1.2.3 From dc8b139aa23899b00baa919fd7f46c74bf4ef205 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 23 Oct 2009 18:21:59 -0600 Subject: mesa: remove FBO texture depth/stencil test The texture format should not be checked until validation time since the format might be changed by a subsequent glTexImage() call. --- src/mesa/main/fbobject.c | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src') diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 825a23090b..ed1db0feca 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -1511,18 +1511,6 @@ framebuffer_texture(GLcontext *ctx, const char *caller, GLenum target, return; } - if (texObj && attachment == GL_DEPTH_STENCIL_ATTACHMENT) { - /* the texture format must be depth+stencil */ - const struct gl_texture_image *texImg; - texImg = texObj->Image[0][texObj->BaseLevel]; - if (!texImg || texImg->_BaseFormat != GL_DEPTH_STENCIL) { - _mesa_error(ctx, GL_INVALID_OPERATION, - "glFramebufferTexture%sEXT(texture is not" - " DEPTH_STENCIL format)", caller); - return; - } - } - FLUSH_CURRENT(ctx, _NEW_BUFFERS); /* The above doesn't fully flush the drivers in the way that a * glFlush does, but that is required here: -- cgit v1.2.3