mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 06:48:06 +02:00
dri/nouveau: Don't try to validate uninitialized teximages.
This commit is contained in:
parent
d03f04bfb5
commit
bc578caefb
1 changed files with 4 additions and 4 deletions
|
|
@ -183,10 +183,10 @@ teximage_fits(struct gl_texture_object *t, int level)
|
||||||
struct nouveau_surface *s = &to_nouveau_texture(t)->surfaces[level];
|
struct nouveau_surface *s = &to_nouveau_texture(t)->surfaces[level];
|
||||||
struct gl_texture_image *ti = t->Image[0][level];
|
struct gl_texture_image *ti = t->Image[0][level];
|
||||||
|
|
||||||
return ti && (t->Target == GL_TEXTURE_RECTANGLE ||
|
return ti && to_nouveau_teximage(ti)->surface.bo &&
|
||||||
(s->bo && s->width == ti->Width &&
|
(t->Target == GL_TEXTURE_RECTANGLE ||
|
||||||
s->height == ti->Height &&
|
(s->bo && s->format == ti->TexFormat &&
|
||||||
s->format == ti->TexFormat));
|
s->width == ti->Width && s->height == ti->Height));
|
||||||
}
|
}
|
||||||
|
|
||||||
static GLboolean
|
static GLboolean
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue