mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 00:38:48 +02:00
st/mesa: require RGBA2, RGB4, and RGBA4 to be renderable
If the driver does not support rendering to these formats but does
support texturing, we can end up in incompatibilities between textures
and renderbuffers that are then copied to.
Fixes KHR-GL45.copy_image.functional on nvc0
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Cc: 19.0 <mesa-stable@lists.freedesktop.org>
(cherry picked from commit cbd1ad6165)
This commit is contained in:
parent
24bb2771b6
commit
ab70eccc75
1 changed files with 2 additions and 0 deletions
|
|
@ -2356,6 +2356,8 @@ st_ChooseTextureFormat(struct gl_context *ctx, GLenum target,
|
|||
bindings |= PIPE_BIND_DEPTH_STENCIL;
|
||||
else if (is_renderbuffer || internalFormat == 3 || internalFormat == 4 ||
|
||||
internalFormat == GL_RGB || internalFormat == GL_RGBA ||
|
||||
internalFormat == GL_RGBA2 ||
|
||||
internalFormat == GL_RGB4 || internalFormat == GL_RGBA4 ||
|
||||
internalFormat == GL_RGB8 || internalFormat == GL_RGBA8 ||
|
||||
internalFormat == GL_BGRA ||
|
||||
internalFormat == GL_RGB16F ||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue