19 Oct
2004
19 Oct
'04
2:40 p.m.
"Martin Magnusson"
I'm using BGL, and I noticed that add_vertex returns a vertex_descriptor to the new vertex. However, I would like to have a vertex_iterator pointing to the same element. Is there a way to construct a vertex_iterator when given a vertex_descriptor?
Martin, If I have a BGL graph object g and a vertex descriptor vd, then std::find(vertices(g).first, vertices(g).second, vd) will return an iterator that points to vd. Hope this helps, David M. Jones