diff options
author | marha <marha@users.sourceforge.net> | 2012-08-27 08:17:50 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2012-08-27 08:17:50 +0200 |
commit | b3462c12542a69eeaa3fe90fddfbb15d30c18158 (patch) | |
tree | 294230cca0e59ee250cd70060ba3f8c3742b4023 /mesalib/src/mesa/state_tracker/st_format.c | |
parent | e91ed68959d63f79e3b4973bc80c7ebcd07ed021 (diff) | |
download | vcxsrv-b3462c12542a69eeaa3fe90fddfbb15d30c18158.tar.gz vcxsrv-b3462c12542a69eeaa3fe90fddfbb15d30c18158.tar.bz2 vcxsrv-b3462c12542a69eeaa3fe90fddfbb15d30c18158.zip |
xwininfo fontconfig libX11 libXau libXext libxcb mesa pixman
xkeyboard-config git update 27 Aug 2012
Diffstat (limited to 'mesalib/src/mesa/state_tracker/st_format.c')
-rw-r--r-- | mesalib/src/mesa/state_tracker/st_format.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/mesalib/src/mesa/state_tracker/st_format.c b/mesalib/src/mesa/state_tracker/st_format.c index 962b09250..302b58c7b 100644 --- a/mesalib/src/mesa/state_tracker/st_format.c +++ b/mesalib/src/mesa/state_tracker/st_format.c @@ -1631,7 +1631,8 @@ st_ChooseTextureFormat_renderable(struct gl_context *ctx, GLint internalFormat, * Called via ctx->Driver.ChooseTextureFormat(). */ gl_format -st_ChooseTextureFormat(struct gl_context *ctx, GLint internalFormat, +st_ChooseTextureFormat(struct gl_context *ctx, GLenum target, + GLint internalFormat, GLenum format, GLenum type) { boolean want_renderable = @@ -1640,6 +1641,15 @@ st_ChooseTextureFormat(struct gl_context *ctx, GLint internalFormat, internalFormat == GL_RGB8 || internalFormat == GL_RGBA8 || internalFormat == GL_BGRA; + if (target == GL_TEXTURE_1D || target == GL_TEXTURE_1D_ARRAY) { + /* We don't do compression for these texture targets because of + * difficulty with sub-texture updates on non-block boundaries, etc. + * So change the internal format request to an uncompressed format. + */ + internalFormat = + _mesa_generic_compressed_format_to_uncompressed_format(internalFormat); + } + return st_ChooseTextureFormat_renderable(ctx, internalFormat, format, type, want_renderable); } |