[Mesa-dev] [PATCH 2/2] anv/formats: Make alpha blending a property of render targets

Jason Ekstrand jason at jlekstrand.net
Fri May 20 19:12:29 UTC 2016


Seems reasonable.

Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>

On Fri, May 20, 2016 at 9:55 AM, Nanley Chery <nanleychery at gmail.com> wrote:

> From: Nanley Chery <nanley.g.chery at intel.com>
>
> In agreement with the SNB PRM, alpha blending is a property that render
> targets may or may not support.
>
> Signed-off-by: Nanley Chery <nanley.g.chery at intel.com>
> ---
>  src/intel/vulkan/anv_formats.c | 6 ++----
>  1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/src/intel/vulkan/anv_formats.c
> b/src/intel/vulkan/anv_formats.c
> index a920ab4..a0fa976 100644
> --- a/src/intel/vulkan/anv_formats.c
> +++ b/src/intel/vulkan/anv_formats.c
> @@ -329,11 +329,9 @@ get_image_format_properties(int gen, enum isl_format
> base,
>         format.swizzle.a == ISL_CHANNEL_SELECT_ALPHA) {
>        flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT |
>                 VK_FORMAT_FEATURE_BLIT_DST_BIT;
> -   }
>
> -   if (info->alpha_blend <= gen &&
> -       format.swizzle.a == ISL_CHANNEL_SELECT_ALPHA) {
> -      flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT;
> +      if (info->alpha_blend <= gen)
> +         flags |= VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BLEND_BIT;
>     }
>
>     /* Load/store is determined based on base format.  This prevents RGB
> --
> 2.8.2
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160520/59eadc9f/attachment-0001.html>


More information about the mesa-dev mailing list