Open bernardkwok opened 4 years ago
Note that a graph like this will be handled after looking at #1062 which would encapsulate the nodegraph properly to avoid conflicts.
<?xml version="1.0"?>
<materialx version="1.37">
<!-- Check for inputs with same nodenames at different levels -->
<constant name="foo1" type="color3">
<parameter name="value" type="color3" value="1, 0, 0"/>
</constant>
<nodegraph name="nodename_check" >
<input name="in1" type="color3" nodename="foo1" />
<input name="in2" type="color3" value="0, 1, 0" />
<constant name="foo1" type="float">
<parameter name="value" type="float" value="0.5"/>
</constant>
<mix name="mix1" type="color3">
<input name="bg" type="color3" interfacename="in1" />
<input name="fg" type="color3" interfacename="in1" />
<input name="mix" type="float" nodename="foo1" />
</mix>
<output name="out_nodename_check" type="color3" nodename="mix1" />
</nodegraph>
</materialx>
Proposal
Allow for inputs to be explicitly listed "published" for nodegraphs.
Upgrade Path:
interfacename
attribute for now to maintain syntax compatibility.Examples
Here 2 inputs are defined
input1
andinput2
which route data to theadd
node.Example 2:
Here is the same example but connected to a non-nodegrah node
foo1
via input `input1.