
On Sunday 20 November 2005 12:15 pm, Daniel Mitchell wrote:
I'd like to add color map support to the named parameter version of dijkstra_shortest_paths, which requires the addition of color map arguments to dijkstra_dispatch1 and dijkstra_dispatch2.
Just to clarify, I'm imagining changing the call to dijkstra_dispatch1 from dijkstra_shortest_paths (named parameter version) to detail::dijkstra_dispatch1 (g, s, get_param(params, vertex_distance), choose_const_pmap(get_param(params, edge_weight), g, edge_weight), choose_const_pmap(get_param(params, vertex_index), g, vertex_index), params, get_param(params, color_map)); Inside dijkstra_dispatch1 we would have typename std::vector<default_color_type>::size_type n = is_default_param(color) ? num_vertices( g ) : 1; std::vector<default_color_type> color_map( n ); detail::dijkstra_dispatch2 (g, s, choose_param(distance, make_iterator_property_map (distance_map.begin(), index_map, distance_map[0])), weight, index_map, params, choose_param( color, make_iterator_property_map (color_map.begin(), index_map, color_map[0]))); Finally, dijkstra_dispatch2 would pass the color map to dijkstra_shortest_paths. Daniel