Function removeEdge

Synopsis

#include <Source/Falcor/Utils/Algorithm/DirectedGraph.h>

void removeEdge(uint32_t edgeId)

Description

Remove an edge

Source

Lines 109-122 in Source/Falcor/Utils/Algorithm/DirectedGraph.h.

void removeEdge(uint32_t edgeId)
{
    if (mEdges.find(edgeId) == mEdges.end())
    {
        logWarning("Can't remove edge from DirectedGraph, edge ID doesn't exist");
        return;
    }
    const auto& edge = mEdges[edgeId];
    removeEdgeFromNode<true>(edgeId, mNodes[edge.getDestNode()]);
    removeEdgeFromNode<false>(edgeId, mNodes[edge.getSourceNode()]);
    mEdges.erase(edgeId);
}





Add Discussion as Guest

Log in