|
Boost Users : |
From: Solomon Gibbs (solomon.gibbs_at_[hidden])
Date: 2003-08-11 19:02:20
Hello,
I've been trying to use the write_graphviz function in BGL, and I've noticed
that it appears to be sensitive to the type of VertexList used in the graph.
adjacency_lists using a boost::vecS produce vertex indices in integer form
like:
graph G {
0[label="0"];
1[label="1"];
0--1 [label="2.8"];
}
but the same code backed by boost::listS seems to not dereference completely:
graph G {
0x80545f0[label="10"];
0x8054608[label="11"];
0x80545f0--0x8054608 [label="2.8"];
}
dot doesn't like this.
I notice that write_graphviz dereferences
boost::graph_traits<Graph>::vertex_iterator to print the vertex.
Are the listS and vecS *operators different somehow?
The vector backed adjacency_list also seems to be automagically setting the
vertex_index property to the actual index of the vertex in the storage vector
instead of the value given in add_vertex().
My question is: Is this the expected behavior for these classes or some
problem I've managed to create on my own?
Thanks,
Solomon
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net