Skip to content

Commit 63e93e7

Browse files
committed
Fix splitter state restoration at start of acquisition
1 parent 20e3bbf commit 63e93e7

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

Source/Processors/ProcessorGraph/ProcessorGraph.cpp

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -877,6 +877,7 @@ void ProcessorGraph::updateConnections()
877877
clearConnections(); // clear processor graph
878878

879879
Array<GenericProcessor*> splitters;
880+
Array<GenericProcessor*> splitters2;
880881
Array<int> splitterStates;
881882

882883
// keep track of which splitter is currently being explored, in case there's another
@@ -1002,20 +1003,23 @@ void ProcessorGraph::updateConnections()
10021003
if (splitters.size() > 0)
10031004
{
10041005
activeSplitter = splitters.getLast();
1006+
splitters2.insert(0, activeSplitter);
1007+
10051008
splitters.removeLast();
10061009
activeSplitter->switchIO(1);
10071010

10081011
source = activeSplitter;
10091012
GenericProcessor* newSource;
1013+
10101014
while (source->isSplitter() || source->isMerger())
10111015
{
10121016
newSource = source->getSourceNode();
10131017
newSource->setPathToProcessor(source);
10141018
source = newSource;
10151019
}
10161020

1017-
activeSplitter->switchIO(splitterStates.getLast());
1018-
splitterStates.removeLast();
1021+
//activeSplitter->switchIO(splitterStates.getLast());
1022+
//splitterStates.removeLast();
10191023
}
10201024
else
10211025
{
@@ -1026,6 +1030,10 @@ void ProcessorGraph::updateConnections()
10261030
} // end while source != 0
10271031
} // end "tabs" for loop
10281032

1033+
for (int i = 0; i < splitters2.size(); i++)
1034+
{
1035+
splitters2[i]->switchIO(splitterStates[i]);
1036+
}
10291037

10301038
// actually connect sources to each dest processor,
10311039
// in correct order by merger topography

0 commit comments

Comments
 (0)