On Apr 1, 2010, at 5:31 AM, Gábor Szuromi wrote:
The edge_index internal property map is not created by default, so you have to define it explicitly:
typedef adjacency_list
> MyGraph; typedef property_map ::type MyEdgeIndexMap; ... // Retrieve the edge index map associated with the graph MyEdgeIndexMap emap = get(edge_index, g); ... // Convert the edge descriptor to an integer value cout << index[ get(emap, e, g) ] << endl;
A follow-up question, if I may... It seems like an awful lot of setup
is required just to iterate through the edge indices. For example,
here's what I'm doing now:
typedef property_map