diff options
author | Adam Jackson <ajax@redhat.com> | 2021-03-31 18:03:01 -0400 |
---|---|---|
committer | Marge Bot <eric+marge@anholt.net> | 2021-05-05 03:23:58 +0000 |
commit | 64e7248bfb65cb6c00ffa2a22a354d1755ecd8c2 (patch) | |
tree | 4deaf45911df60a287fa7222914db634d17e4be1 /src/mesa/main | |
parent | d7888294ac56b831c2da3e0582748a78adb0de28 (diff) |
mesa: Ignore the depth buffer when computing framebuffer floatness
Not that Z32F is especially common, but we shouldn't consider it to
imply that the color buffers are also float, which is what floatMode
is meant to mean.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10491>
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/framebuffer.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mesa/main/framebuffer.c b/src/mesa/main/framebuffer.c index a5460795b88..de79ae0d85a 100644 --- a/src/mesa/main/framebuffer.c +++ b/src/mesa/main/framebuffer.c @@ -447,6 +447,8 @@ _mesa_update_framebuffer_visual(struct gl_context *ctx, fb->Visual.floatMode = GL_FALSE; for (unsigned i = 0; i < BUFFER_COUNT; i++) { + if (i == BUFFER_DEPTH) + continue; if (fb->Attachment[i].Renderbuffer) { const struct gl_renderbuffer *rb = fb->Attachment[i].Renderbuffer; const mesa_format fmt = rb->Format; |