projects
/
platform
/
upstream
/
glslang.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
86ff4bc
)
handleEntryPointAttributes add EatInstance case
author
Gabriele Di Bari
<dbgabri@gmail.com>
Sat, 21 May 2022 15:00:24 +0000
(17:00 +0200)
committer
Gabriele Di Bari
<dbgabri@gmail.com>
Sat, 21 May 2022 15:00:24 +0000
(17:00 +0200)
glslang/HLSL/hlslParseHelper.cpp
patch
|
blob
|
history
diff --git
a/glslang/HLSL/hlslParseHelper.cpp
b/glslang/HLSL/hlslParseHelper.cpp
index
e9369a0
..
ffa1d7a
100644
(file)
--- a/
glslang/HLSL/hlslParseHelper.cpp
+++ b/
glslang/HLSL/hlslParseHelper.cpp
@@
-1754,6
+1754,18
@@
void HlslParseContext::handleEntryPointAttributes(const TSourceLoc& loc, const T
intermediate.setLocalSize(lid, sequence[lid]->getAsConstantUnion()->getConstArray()[0].getIConst());
break;
}
+ case EatInstance:
+ {
+ int invocations;
+
+ if (!it->getInt(invocations)) {
+ error(loc, "invalid instance", "", "");
+ } else {
+ if (!intermediate.setInvocations(invocations))
+ error(loc, "cannot change previously set instance attribute", "", "");
+ }
+ break;
+ }
case EatMaxVertexCount:
{
int maxVertexCount;