Module: Mesa Branch: master Commit: 4bd5ce853bd1a78889aa7b73dd8c748ba1e47f5c URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4bd5ce853bd1a78889aa7b73dd8c748ba1e47f5c
Author: Charmaine Lee <[email protected]> Date: Tue Oct 25 13:56:52 2016 -0700 svga: create BGRX render target view for BGRX_UNORM surface Currently we adjust the view format when we are asked to create a BGRA render target view for BGRX surface. But we only look for SVGA3D_B8G8R8X8_TYPELESS surface format. With this patch, we will also check for SVGA3D_B8G8R8X8_UNORM surface format, and use SVGA3D_B8G8R8X8_UNORM as the view format for that case. Reviewed-by: Brian Paul <[email protected]> --- src/gallium/drivers/svga/svga_surface.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/svga/svga_surface.c b/src/gallium/drivers/svga/svga_surface.c index 9353841..2ffdce5 100644 --- a/src/gallium/drivers/svga/svga_surface.c +++ b/src/gallium/drivers/svga/svga_surface.c @@ -461,7 +461,8 @@ svga_validate_surface_view(struct svga_context *svga, struct svga_surface *s) * svga_validate_pipe_sampler_view(). */ if (view_format == SVGA3D_B8G8R8A8_UNORM && - stex->key.format == SVGA3D_B8G8R8X8_TYPELESS) { + (stex->key.format == SVGA3D_B8G8R8X8_UNORM || + stex->key.format == SVGA3D_B8G8R8X8_TYPELESS)) { view_format = SVGA3D_B8G8R8X8_UNORM; } _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
