diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-07-11 18:11:13 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-07-11 18:11:13 +0200 |
commit | 4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0 (patch) | |
tree | f000dd831240707a03b8c806db292c2a15cde3ce /gfx/angle/src/compiler/translator/VariableInfo.cpp | |
parent | 3b7ffb477eec078c7036c92c6a51bb5de6de4f28 (diff) | |
download | UXP-4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0.tar UXP-4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0.tar.gz UXP-4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0.tar.lz UXP-4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0.tar.xz UXP-4f2ecd53a9daaf88bb7d075745eefb6e2e4741e0.zip |
Roll back to ANGLE/2845
Diffstat (limited to 'gfx/angle/src/compiler/translator/VariableInfo.cpp')
-rwxr-xr-x | gfx/angle/src/compiler/translator/VariableInfo.cpp | 71 |
1 files changed, 41 insertions, 30 deletions
diff --git a/gfx/angle/src/compiler/translator/VariableInfo.cpp b/gfx/angle/src/compiler/translator/VariableInfo.cpp index 07fe12e5d..7e1e5cd82 100755 --- a/gfx/angle/src/compiler/translator/VariableInfo.cpp +++ b/gfx/angle/src/compiler/translator/VariableInfo.cpp @@ -559,43 +559,54 @@ void CollectVariables::visitInfoList(const TIntermSequence &sequence, } } -bool CollectVariables::visitDeclaration(Visit, TIntermDeclaration *node) +bool CollectVariables::visitAggregate(Visit, TIntermAggregate *node) { - const TIntermSequence &sequence = *(node->getSequence()); - ASSERT(!sequence.empty()); + bool visitChildren = true; - const TIntermTyped &typedNode = *(sequence.front()->getAsTyped()); - TQualifier qualifier = typedNode.getQualifier(); - - if (typedNode.getBasicType() == EbtInterfaceBlock) + switch (node->getOp()) { - visitInfoList(sequence, mInterfaceBlocks); - return false; - } - else if (qualifier == EvqAttribute || qualifier == EvqVertexIn || qualifier == EvqFragmentOut || - qualifier == EvqUniform || IsVarying(qualifier)) - { - switch (qualifier) + case EOpDeclaration: { - case EvqAttribute: - case EvqVertexIn: - visitInfoList(sequence, mAttribs); - break; - case EvqFragmentOut: - visitInfoList(sequence, mOutputVariables); - break; - case EvqUniform: - visitInfoList(sequence, mUniforms); - break; - default: - visitInfoList(sequence, mVaryings); - break; - } + const TIntermSequence &sequence = *(node->getSequence()); + ASSERT(!sequence.empty()); - return false; + const TIntermTyped &typedNode = *(sequence.front()->getAsTyped()); + TQualifier qualifier = typedNode.getQualifier(); + + if (typedNode.getBasicType() == EbtInterfaceBlock) + { + visitInfoList(sequence, mInterfaceBlocks); + visitChildren = false; + } + else if (qualifier == EvqAttribute || qualifier == EvqVertexIn || + qualifier == EvqFragmentOut || qualifier == EvqUniform || + IsVarying(qualifier)) + { + switch (qualifier) + { + case EvqAttribute: + case EvqVertexIn: + visitInfoList(sequence, mAttribs); + break; + case EvqFragmentOut: + visitInfoList(sequence, mOutputVariables); + break; + case EvqUniform: + visitInfoList(sequence, mUniforms); + break; + default: + visitInfoList(sequence, mVaryings); + break; + } + + visitChildren = false; + } + break; + } + default: break; } - return true; + return visitChildren; } bool CollectVariables::visitBinary(Visit, TIntermBinary *binaryNode) |