Subject: CGAL users discussion list
List archive
- From: Shrabani Ghosh <>
- To:
- Subject: Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?
- Date: Sat, 7 Sep 2019 13:54:42 -0500 (CDT)
- Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None ; spf=SoftFail ; spf=Pass
- Ironport-phdr: 9a23:9E+znxMU07pMPabzRdkl6mtUPXoX/o7sNwtQ0KIMzox0Lfn5rarrMEGX3/hxlliBBdydt6sezbOG6uu5AzxIyK3CmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+KPjrFY7OlcS30P2594HObwlSizexfK1+IA+roQjSq8UajpZuJrgyxxDUvnZGZuNayH9yK1mOhRj8/MCw/JBi8yRUpf0s8tNLXLv5caolU7FWFSwqPG8p6sLlsxnDVhaP6WAHUmoKiBpIAhPK4w/8U5zsryb1rOt92C2dPc3rUbA5XCmp4ql3RBP0jioMKjg0+3zVhMNtlqJWuByvqRxhzYDXYo6VOudwcazBct0VXmdBQsRcWzBdDo+gc4cDEewMNvtYoYnnoFsOqAOzCxSsBOP10DBHnWX53as70+88EA/G3AsgH8kOsH/Jq9j1L70SXvuzzKXSwjXDb/RW2Sz96IXMdh0suv6MXbdqfsrQzUkjDR/KjlKVqYH8OT6ey+oDs2+e7+V6VOKvjXYqqwdrrTe03cgsjpfGipgJxVDD8CV0xps+K96gSENjfNKpFJ9duzuUOoZ1WM8vQGBltDw7x7AHv5OwYTIEx449xxHFbvyKa4iI7QznVOaWOTp4gn1odKi5hxmo6kev0en8Wdeu3FlWqSpFl8HAtnEL1xPN9siKUuZx80Ol1DqV2Q3e6ftILEM1mKbBKpMsw6Y8lp8JvkTCGi/2ll/2jKiTdkg84eio8f/oYrP8qp+TN490jRr+MqQql8G7Guk4PQ0OUHKa+eS4zrHs4Ur5QLBSgv0sjqbZqIzaJdgcpqOhHwBV3Zws6xKmAzi70dQYhmUILE9eeBKclIXpIFHPIPXgDfilmViskTFrx+rHPrL7GJnNIGLDw//deuN25EdYjQYy1ttC/Il8C7cbIfu1VFWimsbfC0oCMxa9ye/hCZ1S1oQFWSrbGbWTNuXdsViT5rN+C+aJbY4R/j36Lq52tLbVkXYllApFLuGS1pwNZSXgR6k0EwCieXPpx+w5PyIKsw45FbG4jgHEVzdZbXK/Gak742NiUdP0PcL4XomoxYe58mK+F5xSaHpBDwnVQ3jtfoSAHfwLbXDJe5Mzonk/TbGkDrQZ+1S2rgajkuhoK+PV/msTspexjNU=
Thank you for your reply.
I tried to do something like this. But it's not working.
#include <string>
#include <CGAL/Simple_cartesian.h>
#include <CGAL/Surface_mesh.h>
#include <boost/foreach.hpp>
#include <fstream>
#include <list>
#include <iostream>
#include <CGAL/Polyhedron_items_with_id_3.h>
#include <boost/graph/kruskal_min_spanning_tree.hpp>
#include <boost/property_map/property_map.hpp>
typedef CGAL::Simple_cartesian<double> K;
typedef CGAL::Surface_mesh<K::Point_3> Mesh;
typedef Mesh::Vertex_index vertex_descriptor;
typedef boost::graph_traits<Mesh>::vertex_iterator vertex_iterator;
typedef boost::graph_traits<Mesh>::vertex_descriptor vertex_descriptor;
typedef Mesh::Face_index face_descriptor;
typedef boost::graph_traits<Mesh>::edge_descriptor edge_descriptor;
std::list<edge_descriptor> mst;
int main()
{
Mesh m;
std::ifstream is("../data/TwoBoxesEqualSideBySide_MM2M.off") ; is >> m ;
if (!CGAL::is_triangle_mesh(m)){
std::cerr << "Input geometry is not triangulated." << std::endl;
return EXIT_FAILURE;
}
// retrieve the point property for which exists a convenience function
Mesh::Property_map<vertex_descriptor, std::int> label;
BOOST_FOREACH( vertex_descriptor vd, m.vertices()) {
std::cout << get(vd, label) << std:: endl;
// std::cout << "point " << vd << " location " << location[vd] <<
std::endl;
}
return 0;
}
--
Sent from: http://cgal-discuss.949826.n4.nabble.com/
- [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/05/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/06/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/07/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/09/2019
- [cgal-discuss] ?????? [cgal-discuss] How can I fetch the label value of a meshvertices?, ????, 09/09/2019
- Re: [cgal-discuss] 回复: How can I fetch the label value of a meshvertices?, Shrabani Ghosh, 09/10/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/10/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/09/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Shrabani Ghosh, 09/07/2019
- Re: [cgal-discuss] How can I fetch the label value of a mesh vertices?, Sebastien Loriot (GeometryFactory), 09/06/2019
Archive powered by MHonArc 2.6.18.