|
|
@@ -289,7 +289,7 @@ namespace bgfx { namespace d3d12
|
|
|
|
|
|
for (uint32_t attr = 0; attr < Attrib::Count; ++attr)
|
|
|
{
|
|
|
- if (0xff != _decl.m_attributes[attr])
|
|
|
+ if (UINT16_MAX != _decl.m_attributes[attr])
|
|
|
{
|
|
|
memcpy(elem, &s_attrib[attr], sizeof(D3D12_INPUT_ELEMENT_DESC) );
|
|
|
|
|
|
@@ -1821,13 +1821,13 @@ data.NumQualityLevels = 0;
|
|
|
{
|
|
|
VertexDecl decl;
|
|
|
memcpy(&decl, &_vertexDecl, sizeof(VertexDecl) );
|
|
|
- const uint8_t* attrMask = _program.m_vsh->m_attrMask;
|
|
|
+ const uint16_t* attrMask = _program.m_vsh->m_attrMask;
|
|
|
|
|
|
for (uint32_t ii = 0; ii < Attrib::Count; ++ii)
|
|
|
{
|
|
|
- uint8_t mask = attrMask[ii];
|
|
|
- uint8_t attr = (decl.m_attributes[ii] & mask);
|
|
|
- decl.m_attributes[ii] = attr == 0 ? 0xff : attr == 0xff ? 0 : attr;
|
|
|
+ uint16_t mask = attrMask[ii];
|
|
|
+ uint16_t attr = (decl.m_attributes[ii] & mask);
|
|
|
+ decl.m_attributes[ii] = attr == 0 ? UINT16_MAX : attr == UINT16_MAX ? 0 : attr;
|
|
|
}
|
|
|
|
|
|
D3D12_INPUT_ELEMENT_DESC* elem = fillVertexDecl(_vertexElements, decl);
|
|
|
@@ -1939,13 +1939,13 @@ data.NumQualityLevels = 0;
|
|
|
|
|
|
VertexDecl decl;
|
|
|
memcpy(&decl, &m_vertexDecls[_declIdx], sizeof(VertexDecl) );
|
|
|
- const uint8_t* attrMask = program.m_vsh->m_attrMask;
|
|
|
+ const uint16_t* attrMask = program.m_vsh->m_attrMask;
|
|
|
|
|
|
for (uint32_t ii = 0; ii < Attrib::Count; ++ii)
|
|
|
{
|
|
|
- uint8_t mask = attrMask[ii];
|
|
|
- uint8_t attr = (decl.m_attributes[ii] & mask);
|
|
|
- decl.m_attributes[ii] = attr == 0 ? 0xff : attr == 0xff ? 0 : attr;
|
|
|
+ uint16_t mask = attrMask[ii];
|
|
|
+ uint16_t attr = (decl.m_attributes[ii] & mask);
|
|
|
+ decl.m_attributes[ii] = attr == 0 ? UINT16_MAX : attr == UINT16_MAX ? 0 : attr;
|
|
|
}
|
|
|
|
|
|
bx::HashMurmur2A murmur;
|
|
|
@@ -2947,7 +2947,7 @@ data.NumQualityLevels = 0;
|
|
|
|
|
|
if (Attrib::Count != attr)
|
|
|
{
|
|
|
- m_attrMask[attr] = 0xff;
|
|
|
+ m_attrMask[attr] = UINT16_MAX;
|
|
|
}
|
|
|
}
|
|
|
|