panfrost: Add an helper to retrieve the currently active shader state
authorBoris Brezillon <boris.brezillon@collabora.com>
Thu, 5 Mar 2020 09:46:39 +0000 (10:46 +0100)
committerBoris Brezillon <boris.brezillon@collabora.com>
Tue, 10 Mar 2020 11:47:33 +0000 (12:47 +0100)
commitb28f4bb67ce385b8e87c8d2c4d29195fe557547c
tree09ad2853ec93f4f69a92255610f05a1257d41c7a
parenta0402f79601c69089cc3cefab51adab9c3331669
panfrost: Add an helper to retrieve the currently active shader state

Doing that improves readability and helps avoiding code duplication.

Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4083>
src/gallium/drivers/panfrost/pan_context.c
src/gallium/drivers/panfrost/pan_context.h
src/gallium/drivers/panfrost/pan_varyings.c