Home || Architecture || Video Search || Visual Search || Scripts || Applications || Important Messages || OGL || Src

bool BoostedGraph::doLayout (  )  [inline, private]

Definition at line 124 of file BoostedGraph.h.

References center, doInitialLayout(), graph, OglGui::OglWindow::H(), initialLayoutDone, nodes, position, and OglGui::OglWindow::W().

Referenced by DisplayFunc().

00124                         {
00125                 center.x = (W()-75)/2; center.y = (H()-20)/2;
00126                 if(!initialLayoutDone) doInitialLayout();
00127                 fruchterman_reingold_force_directed_layout(graph, position, 2*center.x-10, 2*center.y-10,
00128                                 force_pairs(all_force_pairs()).
00129                                 cooling(linear_cooling<double>(50)));
00130 
00131                 graph_traits<Graph>::vertex_iterator vi, vi_end;
00132                 for (tie(vi, vi_end) = vertices(graph); vi != vi_end; ++vi) {
00133                         string name = get(vertex_name, graph, *vi);
00134                         //ILOG_DEBUG(name + ": " + Impala::MakeString(position[*vi].x) + " " + Impala::MakeString(position[*vi].y));
00135                         int x, y, w, h;
00136                         nodes[name].second->GetDimensions(x, y, w, h);
00137                         nodes[name].second->SetDimensions(center.x+position[*vi].x, center.y+position[*vi].y, w, h);
00138                         nodes[name].second->ShapeBg(ARGB2COLOR(208,255,24,0));
00139                 }
00140                 return true;
00141         }

Here is the call graph for this function:


Generated on Fri Mar 19 10:31:55 2010 for ImpalaSrc by  doxygen 1.5.1