Scatter internal acoustic graph nodes
This commit is contained in:
parent
41453199ea
commit
d088580745
7 changed files with 31 additions and 17 deletions
|
|
@ -735,7 +735,18 @@ public static class FaustEmitter
|
|||
|
||||
var sourceInjection = NodeSourceExpression(name, node, sources);
|
||||
var reflection = $"{name}_graph_node_reflection_{node.Name}";
|
||||
foreach (var port in ports)
|
||||
if (ports.Count > 1)
|
||||
{
|
||||
var nodePressure = $"{name}_graph_node_pressure_{node.Name}";
|
||||
source.AppendLine($" {nodePressure} = 2.0 * ({string.Join(" + ", ports.Select(port => GraphIncoming(name, port)))}) / {F(ports.Count)};");
|
||||
foreach (var port in ports)
|
||||
{
|
||||
var outgoing = GraphOutgoing(name, port);
|
||||
var incoming = GraphIncoming(name, port);
|
||||
source.AppendLine($" {outgoing} = ({nodePressure} - {incoming}) * (1.0 - min(0.98, abs({reflection}))) + {incoming} * {reflection} + ({sourceInjection}) / {F(ports.Count)};");
|
||||
}
|
||||
}
|
||||
else foreach (var port in ports)
|
||||
{
|
||||
var outgoing = GraphOutgoing(name, port);
|
||||
var incoming = GraphIncoming(name, port);
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@ public static class PinkTromboneParityFixtures
|
|||
{
|
||||
return
|
||||
$$"""
|
||||
patch gain=0.028 soft_clip=true
|
||||
patch gain=0.02 soft_clip=true
|
||||
|
||||
tract_shape
|
||||
name=human
|
||||
|
|
|
|||
Loading…
Reference in a new issue