SPV: Don't put locations on OpTypeStruct. Related to Issue #291.
This commit is contained in:
parent
75ce84538d
commit
22e0d41448
@ -1961,14 +1961,6 @@ spv::Id TGlslangToSpvTraverser::convertGlslangToSpvType(const glslang::TType& ty
|
|||||||
if (type.getQualifier().hasXfbBuffer())
|
if (type.getQualifier().hasXfbBuffer())
|
||||||
builder.addDecoration(spvType, spv::DecorationXfbBuffer, type.getQualifier().layoutXfbBuffer);
|
builder.addDecoration(spvType, spv::DecorationXfbBuffer, type.getQualifier().layoutXfbBuffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (type.getBasicType() != glslang::EbtBlock && (type.getQualifier().storage == glslang::EvqVaryingIn || type.getQualifier().storage == glslang::EvqVaryingOut))
|
|
||||||
{
|
|
||||||
// The layout of a structure type used as an Input or Output depends on whether it is also a Block (i.e. has a Block decoration).
|
|
||||||
// If it is a not a Block, then the structure type must have a Location decoration.
|
|
||||||
if (type.getQualifier().hasLocation())
|
|
||||||
builder.addDecoration(spvType, spv::DecorationLocation, type.getQualifier().layoutLocation);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|||||||
@ -65,7 +65,6 @@ Linked vertex stage:
|
|||||||
MemberDecorate 60(SS) 0 Flat
|
MemberDecorate 60(SS) 0 Flat
|
||||||
MemberDecorate 60(SS) 1 Flat
|
MemberDecorate 60(SS) 1 Flat
|
||||||
MemberDecorate 60(SS) 2 Flat
|
MemberDecorate 60(SS) 2 Flat
|
||||||
Decorate 60(SS) Location 0
|
|
||||||
Decorate 62(var) Location 0
|
Decorate 62(var) Location 0
|
||||||
MemberDecorate 63(MS) 0 Location 17
|
MemberDecorate 63(MS) 0 Location 17
|
||||||
Decorate 63(MS) Block
|
Decorate 63(MS) Block
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user