Rebuilding AudioProcessorGraph with a different Node sequence (VST)

Hello to everyone. I just came across this issue.
I’m using an AudioProcessorGraph to manage different AudioProcessor. After adding a Node to the graph I always check for feedback loops. I do it by using a Depth-First sorting algorythm: after it’s done I end up with ReferenceCountedArray< AudioProcessorGraph::Node > L that contains the sorted list of Nodes.
At this point I should clear the graph and add the nodes following L’s sequence.
Maybe there is somethign I’m missing, probably because I don’t have a great understanding of how the graph’s processBlock() method works.
Does the graph calls its Node’s processBlock() following the order of added nodes (therefore following each NodeID), or does it simply follow the connection chain?
If the second option was the one, then I should be able to rebuild the connections following L’s order and I should be fine.

I check out an old post that talks about creating an XML file with the graph’s informations and changing it, but currently there is no method for AudioProcessorGraphs for it.

I assume it follows the connection chain?

If you have the nodes, and the order they should be in, can’t you rebuild the graph yourself using AudioProcessorGraph:: addConnection() and the appropriate AudioProcessorGraph::Connection?

1 Like

yeah that’s what I assume as well. Will try soon, thanks!

1 Like

I don’t really know how the processing order is exactly managed internally, but I tried building the graph with different orders, where the nodes are non-tempo variant systems, and the results are different. This means the graph’s processblock() method called does not follow the added node’s order, but follows the connection chain.