1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-19 05:52:11 +01:00

[d3d9] Fix opSelect condition vector size

Fixes invalid fixed function shaders
This commit is contained in:
Joshua Ashton 2020-01-22 22:54:27 +00:00
parent 7de15fe837
commit ff2c6a076f

View File

@ -1565,7 +1565,11 @@ namespace dxvk {
else
texture = m_module.opImageSampleImplicitLod(m_vec4Type, imageVarId, texcoord, imageOperands);
texture = m_module.opSelect(m_vec4Type, m_ps.samplers[i].bound, texture, m_module.constvec4f32(0.0f, 0.0f, 0.0f, 1.0f));
uint32_t bool_t = m_module.defBoolType();
uint32_t bvec4_t = m_module.defVectorType(bool_t, 4);
std::array<uint32_t, 4> boundIndices = { m_ps.samplers[i].bound, m_ps.samplers[i].bound, m_ps.samplers[i].bound, m_ps.samplers[i].bound };
uint32_t bound4 = m_module.opCompositeConstruct(bvec4_t, boundIndices.size(), boundIndices.data());
texture = m_module.opSelect(m_vec4Type, bound4, texture, m_module.constvec4f32(0.0f, 0.0f, 0.0f, 1.0f));
}
processedTexture = true;