Skip to content

Commit

Permalink
Additional improvements
Browse files Browse the repository at this point in the history
- Rename from "amplitude" to "height", since we're defining an unsigned wave that travels from zero to height, not a signed wave that travels from -amplitude to amplitude.
- Clarify the description of the node.
  • Loading branch information
jstone-lucasfilm committed Jul 9, 2023
1 parent f53362f commit a3cb1dd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions libraries/stdlib/stdlib_defs.mtlx
Original file line number Diff line number Diff line change
Expand Up @@ -2548,11 +2548,11 @@

<!--
Node: <trianglewave>
A triangle wave of the given amplitude and period.
A triangle wave that varies between zero and height over the given period.
-->
<nodedef name="ND_trianglewave_float" node="trianglewave" nodegroup="math">
<input name="in" type="float" uiname="in" value="0" />
<input name="amplitude" type="float" value="1" />
<input name="height" type="float" value="1" />
<input name="period" type="float" value="1" />
<output name="out" type="float" />
</nodedef>
Expand Down
4 changes: 2 additions & 2 deletions libraries/stdlib/stdlib_ng.mtlx
Original file line number Diff line number Diff line change
Expand Up @@ -1543,7 +1543,7 @@

<!--
Node: <trianglewave>
A triangle wave of the given amplitude and period.
A triangle wave that varies between zero and height over the given period.
-->
<nodegraph name="NG_trianglewave_float" nodedef="ND_trianglewave_float">
<absval name="absval1" type="float">
Expand All @@ -1570,7 +1570,7 @@
</subtract>
<multiply name="multiply3" type="float">
<input name="in1" type="float" nodename="subtract2" />
<input name="in2" type="float" interfacename="amplitude" />
<input name="in2" type="float" interfacename="height" />
</multiply>
<output name="out" type="float" nodename="multiply3" />
</nodegraph>
Expand Down

0 comments on commit a3cb1dd

Please sign in to comment.