mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-01-18 20:52:10 +01:00
[dxbc] Always allocate at least one input array element
Turns out that shaders with no inputs can still have an input signature, in which case we were generating a zero-length array which is illegal.
This commit is contained in:
parent
20f79a754b
commit
144f4badef
@ -7039,7 +7039,7 @@ namespace dxvk {
|
||||
// Define the array type. This will be two-dimensional
|
||||
// in some shaders, with the outer index representing
|
||||
// the vertex ID within an invocation.
|
||||
m_vArrayLength = m_isgn != nullptr ? m_isgn->maxRegisterCount() : 1;
|
||||
m_vArrayLength = m_isgn != nullptr ? std::max(1u, m_isgn->maxRegisterCount()) : 1;
|
||||
m_vArrayLengthId = m_module.lateConst32(getScalarTypeId(DxbcScalarType::Uint32));
|
||||
|
||||
uint32_t vectorTypeId = getVectorTypeId(info);
|
||||
|
Loading…
x
Reference in New Issue
Block a user