Added support for VK_DISPLAY_PLANE_ALPHA_OPAQUE_BIT_KHR for the D2D swapchain.
This commit is contained in:
parent
be70aff2ae
commit
9f0829336c
1 changed files with 6 additions and 3 deletions
|
|
@ -606,7 +606,7 @@ public:
|
||||||
|
|
||||||
VkDisplayPlaneCapabilitiesKHR planeCap;
|
VkDisplayPlaneCapabilitiesKHR planeCap;
|
||||||
vkGetDisplayPlaneCapabilitiesKHR(physicalDevice, displayMode, bestPlaneIndex, &planeCap);
|
vkGetDisplayPlaneCapabilitiesKHR(physicalDevice, displayMode, bestPlaneIndex, &planeCap);
|
||||||
VkDisplayPlaneAlphaFlagBitsKHR alphaMode;
|
VkDisplayPlaneAlphaFlagBitsKHR alphaMode = (VkDisplayPlaneAlphaFlagBitsKHR)0;
|
||||||
|
|
||||||
if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_PREMULTIPLIED_BIT_KHR)
|
if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_PREMULTIPLIED_BIT_KHR)
|
||||||
{
|
{
|
||||||
|
|
@ -614,13 +614,16 @@ public:
|
||||||
}
|
}
|
||||||
else if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_BIT_KHR)
|
else if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_BIT_KHR)
|
||||||
{
|
{
|
||||||
|
|
||||||
alphaMode = VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_BIT_KHR;
|
alphaMode = VK_DISPLAY_PLANE_ALPHA_PER_PIXEL_BIT_KHR;
|
||||||
}
|
}
|
||||||
else
|
else if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_GLOBAL_BIT_KHR)
|
||||||
{
|
{
|
||||||
alphaMode = VK_DISPLAY_PLANE_ALPHA_GLOBAL_BIT_KHR;
|
alphaMode = VK_DISPLAY_PLANE_ALPHA_GLOBAL_BIT_KHR;
|
||||||
}
|
}
|
||||||
|
else if (planeCap.supportedAlpha & VK_DISPLAY_PLANE_ALPHA_OPAQUE_BIT_KHR)
|
||||||
|
{
|
||||||
|
alphaMode = VK_DISPLAY_PLANE_ALPHA_OPAQUE_BIT_KHR;
|
||||||
|
}
|
||||||
|
|
||||||
VkDisplaySurfaceCreateInfoKHR surfaceInfo{};
|
VkDisplaySurfaceCreateInfoKHR surfaceInfo{};
|
||||||
surfaceInfo.sType = VK_STRUCTURE_TYPE_DISPLAY_SURFACE_CREATE_INFO_KHR;
|
surfaceInfo.sType = VK_STRUCTURE_TYPE_DISPLAY_SURFACE_CREATE_INFO_KHR;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue