GLSL: Fix bug setting component=0 for an auto-location assignment.
Setting component=0 is later taken to mean the shader did so, which is not always legal. It should instead set the component as not set by the shader.
This commit is contained in:
@@ -5893,7 +5893,7 @@ void TParseContext::fixBlockLocations(const TSourceLoc& loc, TQualifier& qualifi
|
||||
if (nextLocation >= (int)TQualifier::layoutLocationEnd)
|
||||
error(memberLoc, "location is too large", "location", "");
|
||||
memberQualifier.layoutLocation = nextLocation;
|
||||
memberQualifier.layoutComponent = 0;
|
||||
memberQualifier.layoutComponent = TQualifier::layoutComponentEnd;
|
||||
}
|
||||
nextLocation = memberQualifier.layoutLocation + intermediate.computeTypeLocationSize(*typeList[member].type);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user