22 Jan
2012
22 Jan
'12
9:57 p.m.
If you use a filtered_graph on top of the grid_graph, the trick I mentioned above will work, but you'd want to check the filter condition on the coordinates before using them in the filtered_graph.
Thanks, I didn't know about filtered_graph. The example here http://www.boost.org/doc/libs/1_48_0/libs/graph/doc/filtered_graph.html shows how to filter edges - I made this example to show how to filter vertices by their vertex_descriptor: http://programmingexamples.net/wiki/CPP/Boost/BGL/FilteredGraph David