mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-29 18:50:10 +01:00
nv30: only bail on color/depth bpp mismatch when surfaces are swizzled
The actual restriction is a little weaker than I originally thought. See https://bugs.freedesktop.org/show_bug.cgi?id=92306#c17 for the suggestion. This also explain why things weren't *always* failing before, only sometimes. We will allocate a non-swizzled depth buffer for NPOT winsys buffer sizes, which they almost always are. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Cc: mesa-stable@lists.freedesktop.org
This commit is contained in:
parent
d82f8d9772
commit
8caf2cb0c0
1 changed files with 3 additions and 2 deletions
|
|
@ -379,8 +379,9 @@ nv30_set_framebuffer_state(struct pipe_context *pipe,
|
|||
struct nv30_miptree *zeta_mt = nv30_miptree(fb->zsbuf->texture);
|
||||
|
||||
if (color_mt->swizzled != zeta_mt->swizzled ||
|
||||
(util_format_get_blocksize(fb->zsbuf->format) > 2) !=
|
||||
(util_format_get_blocksize(fb->cbufs[0]->format) > 2)) {
|
||||
(color_mt->swizzled &&
|
||||
(util_format_get_blocksize(fb->zsbuf->format) > 2) !=
|
||||
(util_format_get_blocksize(fb->cbufs[0]->format) > 2))) {
|
||||
nv30->framebuffer.zsbuf = NULL;
|
||||
debug_printf("Mismatched color and zeta formats, ignoring zeta.\n");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue