mesa: add check that non base level attachment is mipmap complete
authorTapani Pälli <tapani.palli@intel.com>
Tue, 19 Jan 2021 05:43:41 +0000 (07:43 +0200)
committerMarge Bot <eric+marge@anholt.net>
Mon, 1 Mar 2021 08:23:58 +0000 (08:23 +0000)
commit2683e3b241b9a652de64e545cc7d17fb3968e74d
tree9f9b67e932f3f5b4ad3eac98b7caff92d6acae29
parenta1e9a5d65344bd4d948075cdd0617cab961f9885
mesa: add check that non base level attachment is mipmap complete

Patch adds a check for mipmap completeness of framebuffer object texture
attachments. Since a glTexImage call might have updated miplevels
meanwhile, we test the completeness before setting framebuffer object
incomplete.

Fixes some upcoming framebuffer completeness CTS tests that explicitly
test case where we have mipmap incomplete non base level texture which
should make also framebuffer object incomplete. After update to the
texture it should make framebuffer object complete again.

Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8520>
src/mesa/main/fbobject.c