mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-01 20:18:15 +01:00
Merge pull request #11691 from hrydgard/workaround-harvest-moon-adreno-bug
WIP: Vulkan/adreno: Apply workaround for Harvest Moon issue #10421
This commit is contained in:
1 file changed
+14
@@ -235,6 +235,20 @@ void DrawEngineVulkan::ConvertStateToVulkanKey(FramebufferManagerVulkan &fbManag
|
||||
}
|
||||
|
||||
key.colorWriteMask = (rmask ? VK_COLOR_COMPONENT_R_BIT : 0) | (gmask ? VK_COLOR_COMPONENT_G_BIT : 0) | (bmask ? VK_COLOR_COMPONENT_B_BIT : 0) | (amask ? VK_COLOR_COMPONENT_A_BIT : 0);
|
||||
|
||||
// Workaround proposed in #10421, for bug where the color write mask is not applied correctly on Adreno.
|
||||
if ((gstate.pmskc & 0x00FFFFFF) == 0x00FFFFFF && vulkan_->GetPhysicalDeviceProperties(vulkan_->GetCurrentPhysicalDevice()).vendorID == VULKAN_VENDOR_QUALCOMM) {
|
||||
key.colorWriteMask = VK_COLOR_COMPONENT_R_BIT | VK_COLOR_COMPONENT_G_BIT | VK_COLOR_COMPONENT_B_BIT | VK_COLOR_COMPONENT_A_BIT;
|
||||
if (!key.blendEnable) {
|
||||
key.blendEnable = true;
|
||||
key.blendOpAlpha = VK_BLEND_OP_ADD;
|
||||
key.srcAlpha = VK_BLEND_FACTOR_ZERO;
|
||||
key.destAlpha = VK_BLEND_FACTOR_ONE;
|
||||
}
|
||||
key.blendOpColor = VK_BLEND_OP_ADD;
|
||||
key.srcColor = VK_BLEND_FACTOR_ZERO;
|
||||
key.destColor = VK_BLEND_FACTOR_ONE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user