Mesa (master): mesa: fix _mesa_texstore_argb8888() for MESA_FORMAT_XRGB8888
Brian Paul
brianp at kemper.freedesktop.org
Thu Oct 29 23:52:17 UTC 2009
Module: Mesa
Branch: master
Commit: f920d496e1b5b01a3ba9bcd7dcff5c19bc109da2
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f920d496e1b5b01a3ba9bcd7dcff5c19bc109da2
Author: Brian Paul <brianp at vmware.com>
Date: Thu Oct 29 17:49:50 2009 -0600
mesa: fix _mesa_texstore_argb8888() for MESA_FORMAT_XRGB8888
If we hit the general path and call _mesa_make_temp_chan_image() we
always want to get a GL_RGBA texture. We were getting a 3-channel
GL_RGB texture before and that messed up the memory layout.
---
src/mesa/main/texstore.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/mesa/main/texstore.c b/src/mesa/main/texstore.c
index 14cad6b..e48d472 100644
--- a/src/mesa/main/texstore.c
+++ b/src/mesa/main/texstore.c
@@ -1406,7 +1406,7 @@ _mesa_texstore_argb8888(TEXSTORE_PARAMS)
{
const GLboolean littleEndian = _mesa_little_endian();
const GLuint texelBytes = _mesa_get_format_bytes(dstFormat);
- const GLenum baseFormat = _mesa_get_format_base_format(dstFormat);
+ const GLenum baseFormat = GL_RGBA;
ASSERT(dstFormat == MESA_FORMAT_ARGB8888 ||
dstFormat == MESA_FORMAT_ARGB8888_REV ||
More information about the mesa-commit
mailing list