1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-02-20 10:54:16 +01:00

[dxbc] Enable sample shading when using interpolation functions

Fixes artifacts on RADV when enabling MSAA in World of Warcraft (#456).
This commit is contained in:
Philip Rebohle 2018-11-05 17:07:11 +01:00
parent 5a1b37b770
commit 2ee7ef7689
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -2798,9 +2798,12 @@ namespace dxvk {
void DxbcCompiler::emitInterpolate(const DxbcShaderInstruction& ins) {
m_module.enableCapability(spv::CapabilityInterpolationFunction);
m_module.enableCapability(spv::CapabilitySampleRateShading);
// The SPIR-V instructions operate on input variable pointers,
// which are all declared as four-component float vectors.
const uint32_t registerId = ins.src[0].idx[0].offset;
uint32_t registerId = ins.src[0].idx[0].offset;
DxbcRegisterValue result;
result.type = getInputRegType(registerId);
@ -6125,7 +6128,6 @@ namespace dxvk {
void DxbcCompiler::emitPsInit() {
m_module.enableCapability(spv::CapabilityDerivativeControl);
m_module.enableCapability(spv::CapabilityInterpolationFunction);
m_module.setExecutionMode(m_entryPointId,
spv::ExecutionModeOriginUpperLeft);