inline void connectClips( TGraph& graph ) { BOOST_FOREACH( typename TGraph::edge_descriptor ed, graph.getEdges() ) { typename TGraph::Edge& edge = graph.instance( ed ); typename TGraph::Vertex& vertexSource = graph.sourceInstance( ed ); typename TGraph::Vertex& vertexDest = graph.targetInstance( ed ); TUTTLE_TCOUT( "[connectClips] " << edge ); TUTTLE_TCOUT( vertexSource << "->" << vertexDest ); if( ! vertexDest.isFake() && ! vertexSource.isFake() ) { INode& sourceNode = vertexSource.getProcessNode(); INode& targetNode = vertexDest.getProcessNode(); sourceNode.connect( targetNode, sourceNode.getAttribute( edge.getInAttrName() ) ); } } }
inline void connectClips(TGraph& graph) { BOOST_FOREACH(typename TGraph::edge_descriptor ed, graph.getEdges()) { typename TGraph::Edge& edge = graph.instance(ed); typename TGraph::Vertex& vertexOutput = graph.targetInstance(ed); typename TGraph::Vertex& vertexInput = graph.sourceInstance(ed); TUTTLE_LOG_TRACE("[Connect Clips] " << edge); TUTTLE_LOG_TRACE("[Connect Clips] " << vertexOutput << " -> " << vertexInput); // TUTTLE_LOG_VAR( TUTTLE_TRACE, edge.getInAttrName() ); if(!vertexOutput.isFake() && !vertexInput.isFake()) { INode& outputNode = vertexOutput.getProcessNode(); INode& inputNode = vertexInput.getProcessNode(); inputNode.connect(outputNode, inputNode.getAttribute(edge.getInAttrName())); } } }