Use access chain for looking up builtins from struct. Refs #2911

This commit is contained in:
baldurk
2023-04-20 11:12:25 +01:00
parent 86b575b0e5
commit f129b5c745
@@ -652,8 +652,7 @@ void AnnotateShader(const ShaderReflection &refl, const SPIRVPatchData &patchDat
rdcspv::Id subElement = locationGather.add(
rdcspv::OpAccessChain(ptrType, editor.MakeId(), patchData.inputs[i].ID, chain));
ret =
locationGather.add(rdcspv::OpLoad(loadType, editor.MakeId(), patchData.inputs[i].ID));
ret = locationGather.add(rdcspv::OpLoad(loadType, editor.MakeId(), subElement));
}
if(loadType != varType)