Jiawei Shao e4f947637a D3D12: Replace dst-alpha with one for formats without alpha
This patch replaces D3D12_BLEND_DEST_ALPHA with D3D12_BLEND_ONE
when the color target formats have no alpha-channel.

Using D3D12_BLEND_ONE is an optimization over
D3D12_BLEND_DEST_ALPHA as it means the GPU hardware doesn't
need to get destination pixel at all. As D3D SPED requires the
default value for missing components in an element format is
"0" for any component except A, which gets "1", using
D3D12_BLEND_DEST_ALPHA takes same effect with
D3D12_BLEND_ONE when the color target formats have no alpha
channel.

In addition, replacing D3D12_BLEND_DEST_ALPHA with
D3D12_BLEND_ONE also serves as a workaround against an Intel
driver issue about alpha blending.

Bug: dawn:1579
Change-Id: If79e4c8007b68dd35e142ba9cf8a4921e611890a
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/120120
Kokoro: Kokoro <noreply+kokoro@google.com>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
2023-02-20 03:10:32 +00:00
..
2023-02-10 01:43:55 +00:00
2023-02-10 01:43:55 +00:00
2023-02-10 01:43:55 +00:00
2023-02-10 01:43:55 +00:00
2023-01-30 14:49:27 +00:00
2022-08-05 20:09:07 +00:00
2023-02-06 23:29:11 +00:00
2023-02-13 17:10:44 +00:00
2022-05-01 14:40:55 +00:00
2022-09-07 14:14:14 +00:00
2023-02-13 17:10:44 +00:00
2023-02-13 17:10:44 +00:00
2023-01-19 20:33:32 +00:00
2022-09-21 14:44:33 +00:00
2022-05-01 14:40:55 +00:00