Correct Inputs to PMP::refine() #7047
Replies: 3 comments 1 reply
-
Error messages
|
Beta Was this translation helpful? Give feedback.
-
|
Hello |
Beta Was this translation helpful? Give feedback.
-
|
I quote part of your code: std::tuple<Eigen::MatrixX3d, Eigen::MatrixX3i> refine_patch(const Eigen::MatrixX3d &vertices, const Eigen::MatrixX3i &faces){
Mesh m;
vf_to_mesh(m, vertices, faces);
Polyhedron poly;
CGAL::copy_face_graph(m, poly);
std::vector<Polyhedron::Facet_handle> new_facets;
std::vector<Vertex_handle> new_vertices;
pmp::refine(poly, faces(poly),
std::back_inserter(new_facets),
std::back_inserter(new_vertices),
CGAL::parameters::density_control_factor(2.));Here you call Note that Jane is right: you can call pmp::refine(m, faces(m),
std::back_inserter(new_facets),
std::back_inserter(new_vertices),
CGAL::parameters::density_control_factor(2.)); |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Issue Details
I'm trying to use PMP::refine() to do refining over a mesh. I'm using Pybind11 to accept vertices and faces from a python script, first turn them into a surface_mesh and then convert to a Polyhedron_3 so it can be input to PMP::refine(). I apologize for the redundancy here since I'm pretty new to both C++ and CGAL. It looks like PMP::refine() has problem accepting such a Polyhedron. I'm pasting my code and error messages as follows. Thanks in advance for any suggestions!
Source Code
Environment
Beta Was this translation helpful? Give feedback.
All reactions