mlivesu / cinolib

A generic programming header only C++ library for processing polygonal and polyhedral meshes

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

cut mesh

shalinsirwani opened this issue · comments

possible to cut mesh with set of 3d points on it.
if possible , example ??

I am not sure I understand the question.
What do you need to do precisely?

i have mesh
m1 - Copy.off.txt
and set of 3d points
tt.txt

now i need to cut this mesh with these set of 3d points ( these points are on the arbitrary plane ) ??

And what if i want to cut this mesh with any curved line ( set of 3d points ) ??

This is not a well posed problem, and depending on how one thinks about it, it can be solved with different tools.

As a starter: points do not "cut" a mesh. They can be "inserted" in the mesh, but unless they lie exactly on the surface, insertion is ambiguous too...

If points lie exactly on the surface, one could process each point separately, find the triangle that contains it, and split the triangle to incorporate it

If points do not lie on the surface, but they jointly sample a certain cutting membrane, one could first define an implicit surface that interpolates this membrane (e.g. using RBF), and then cut the mesh with the membrane, splitting triangles that are traversed by the zero level set of the radial basis function

These are just two simple ways that came on top of my mind, and for which cinolib has all the basic ingredients. Please note that this library does not aim to provide high level algorithms like the one you are perhaps looking for, but it's rather a set of low level atomic tools that you can combine to do what you want. This implies that you must know in advance what you want to do, and how to achieve it.

I am closing the issue.