Skip to content

Commit

Permalink
Merge pull request prman-pixar#527 from a-e-k/master
Browse files Browse the repository at this point in the history
Fixed conditional visibility for 'or' in args files.
  • Loading branch information
prman-pixar authored Jul 20, 2017
2 parents 6928c15 + 1ee3fbb commit 22787e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions shader_parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ def parse_conditional_visop(hintdict):
'lessThan': '<'
}
visop = hintdict.find("string[@name='conditionalVisOp']").attrib['value']
if visop == 'and':
if visop in ('and', 'or'):
vis1op = hintdict.find(
"string[@name='conditionalVis1Op']").attrib['value']
vis1path = hintdict.find(
Expand Down Expand Up @@ -360,7 +360,7 @@ def parse_conditional_visop(hintdict):
vis2 = "float(getattr(node, '%s')) %s float(%s)" % \
(vis2path.rsplit('/', 1)[-1], op_map[vis2op], vis2Value)

return "%s and %s" % (vis1, vis2)
return "%s %s %s" % (vis1, visop, vis2)
else:
vispath = hintdict.find(
"string[@name='conditionalVisPath']").attrib['value']
Expand Down

0 comments on commit 22787e2

Please sign in to comment.