Hi Dave,<br><br>It is still not clear.<br>What should my parameters be for the function add_edge() to construct the graph with bbox objects as edges?<br><br>Thanks,<br><br>Abde Ali<br><br><div class="gmail_quote">On Tue, Jun 24, 2008 at 5:45 AM, David Abrahams &lt;<a href="mailto:dave@boostpro.com">dave@boostpro.com</a>&gt; wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d">Abde Ali Kagalwalla wrote:<br>
&gt; I just started using the graph library.....<br>
&gt; I want to store a class I created called bbox as vertices of a graph.<br>
&gt; So, I just used the bundled properties mentioned as mentioned in the<br>
&gt; documentation.<br>
&gt;<br>
&gt; So here is a relevant portion of the code:<br>
&gt;<br>
&gt; vector&lt;bbox&gt; A;<br>
&gt;<br>
&gt; boost::adjacency_list&lt;vecS, vecS, undirectedS, bbox&gt; G;<br>
&gt;<br>
&gt; for (int i=0; i&lt;A.size(); i++){<br>
&gt; &nbsp; &nbsp;for(int j=i+1; j&lt;A.size();j++{<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp;add_edge(A[i], A[j], G);<br>
&gt; }}<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; But bbox is not accepted as a valid vertex_descriptor for add_edge<br>
&gt; function.<br>
<br>
</div>Right, your graph&#39;s vertex descriptor type is<br>
<br>
 &nbsp; boost::graph_traits&lt;<br>
<div class="Ih2E3d"> &nbsp; &nbsp; &nbsp; &nbsp;adjacency_list&lt;vecS, vecS, undirectedS, bbox&gt;<br>
</div> &nbsp; &gt;::vertex_descriptor<br>
<br>
which is almost certainly something like an int or a std::size_t<br>
<font color="#888888"><br>
--<br>
Dave Abrahams<br>
BoostPro Computing<br>
<a href="http://www.boostpro.com" target="_blank">http://www.boostpro.com</a><br>
_______________________________________________<br>
Boost-users mailing list<br>
<a href="mailto:Boost-users@lists.boost.org">Boost-users@lists.boost.org</a><br>
<a href="http://lists.boost.org/mailman/listinfo.cgi/boost-users" target="_blank">http://lists.boost.org/mailman/listinfo.cgi/boost-users</a><br>
</font></blockquote></div><br>