spirv: Implement VertexId and InstanceId, refactor code

This commit is contained in:
ReinUsesLisp 2021-03-20 19:11:56 -03:00 committed by ameerj
parent e802512d8e
commit 76c8a962ac
10 changed files with 244 additions and 144 deletions

View file

@ -38,6 +38,12 @@ void GetAttribute(Info& info, IR::Attribute attribute) {
case IR::Attribute::PositionW:
info.loads_position = true;
break;
case IR::Attribute::InstanceId:
info.loads_instance_id = true;
break;
case IR::Attribute::VertexId:
info.loads_vertex_id = true;
break;
default:
throw NotImplementedException("Get attribute {}", attribute);
}