asahi: Implement scissors and scissor to viewport
authorAlyssa Rosenzweig <alyssa@rosenzweig.io>
Fri, 28 May 2021 02:51:09 +0000 (22:51 -0400)
committerMarge Bot <eric+marge@anholt.net>
Sun, 30 May 2021 23:32:02 +0000 (23:32 +0000)
commitf285a1220ea5a8e9ef32683a957bfb2aec728dd6
tree0b57a1bb311bc300823c3153606f1ea97774b1bc
parent6fbc1cb52a06a6cc67fff57eab5235ec4ef3d992
asahi: Implement scissors and scissor to viewport

Construct a scissor descriptor correpsonding to the intersection of the
framebuffer, the viewport, and the region selected for scissoring by the app.
Use the intersected scissor in the "clip tile" fields in the viewport. Select
this scissor descriptor from the command stream.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11084>
src/gallium/drivers/asahi/agx_state.c