lima: avoid situations when scissor minx > maxx or miny > maxy
authorVasily Khoruzhick <anarsoul@gmail.com>
Fri, 3 Apr 2020 09:17:06 +0000 (02:17 -0700)
committerMarge Bot <eric+marge@anholt.net>
Sun, 5 Apr 2020 18:52:11 +0000 (18:52 +0000)
commitc04964c6909544ebcf4c631c2b8b91594cd387fe
tree958a2d2e72eaeb6ae8b86b52d4c4673517035743
parenteed5a009897a859ec118ef84c0437be174a49da3
lima: avoid situations when scissor minx > maxx or miny > maxy

Clip scissor to viewport and then to framebuffer to avoid that since
hardware can't handle this case.

Reviewed-by: Qiang Yu <yuq825@gmail.com>
Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4427>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4427>
src/gallium/drivers/lima/lima_context.h
src/gallium/drivers/lima/lima_draw.c