Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Boolean operations on triangular meshes

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Boolean operations on triangular meshes


Chronological Thread 
  • From: SirM2X <>
  • To:
  • Subject: Re: [cgal-discuss] Boolean operations on triangular meshes
  • Date: Thu, 19 Nov 2015 15:18:45 -0800 (PST)
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=SoftFail ; spf=None
  • Ironport-phdr: 9a23:ZKvhcBBSuGny4/xFb3t0UyQJP3N1i/DPJgcQr6AfoPdwSP74pcbcNUDSrc9gkEXOFd2CrakU1qyI7+u5BCQp2tWojjMrSNR0TRgLiMEbzUQLIfWuLgnFFsPsdDEwB89YVVVorDmROElRH9viNRWJ+iXhpQAbFhi3DwdpPOO9QteU1JTqkb7usMSOKyxzxxODIppKZC2sqgvQssREyaBDEY0WjiXzn31TZu5NznlpL1/A1zz158O34YIxu38I46FppIZ8VvDxcK08CLBZFz87KHsd5cvxtBCFQxHcyGEbVzAtkwBtWTiNuBTzUZf2ry77nuV40Siee8bxSOZnCnyZ8653RUqw2288PDkj/TSPhw==

Taus,
Thank you very much for the detailed response. Especially, thanks for the
link to builder example. It will surely come in handy.
Regarding the Boolean operations, I wouldn't even think of implementing them
myself (toooo complicated).
So, if I understand everything correctly, CGAL won't be able to help me: the
meshes that I deal with are obtained using point cloud data and look
terrible (you can bet that they will have self-intersections, degeneracies,
and so on). Also, I'm sure many of the meshes that I use are not closed
(imagine a really bad 3D reconstruction of a ball and a box on a desk). I
can preprocess my meshes to remove degeneracies and self-intersections, but
I cannot guarantee that the mesh will be closed. So I'm assuming CGAL won't
work?

If the answer is no, then I may have to jettison the idea of using Boolean
operations for what I want to do.

Marius,
Thank you for the additional information.


Taus Møller wrote
> I have been struggling (and still is) with this exact problem for
> quite some time. There are quite a few issues and challenges in
> relation to this, and the documentation is largely useless on the
> issues related to use with C#. I have done boolean operations
> successfully but continually struggle with making it robust.
> .
> .
> .
> First, my advice would be to actually make you own boolean operations.
> At least if you need it for anything more than proof of concept. The
> performance of boolean operations in CGAL is horrendous. I have tried
> inquiring about method to speed them up, but it seem that is just the
> way it is. As an example doing a simple union between two meshes of
> around 400 triangles takes around 8 seconds, which is frankly
> ridiculous. My understanding is that this performance is the price you
> pay for having exact math in the calculation. This advantage is
> however mostly lost due to the fact you pulling the meshes out of
> CGAL. This is additionally compounded by the need to converted to and
> from Nef polyhedra. We are primarily using CGAL because implementing
> Booleans is hard(!) and we currently have the resources to do it.
> Additionally, CGAL provides a lot of additional functionality that is
> very convenient. Also, to be fair, it is my experience that appart
> from booleans CGAL is actually very quick.
>
> .
> .
> .
>
> To convert to Polyhedron_3 i found the best way was to implement
> Modifier_base as outlined here:
> http://doc.cgal.org/4.7/Polyhedron/Polyhedron_2polyhedron_prog_incr_builder_8cpp-example.html.
> This way you can provide you mesh as vertex list and triangle indices
> and get a Polyhedron_3 from it.
>
>
> In relation to robustness, before you convert to nef you have to be
> absolutely sure that you Polyhedron mesh is valid, closed and not self
> intersecting. If there is any kind of issue with the mesh, CGAL fails
> in a very unhelpful way. I am currently struggling to ensure mesh
> integrity on Polyhedron_3 meshes. CGAL does provide some useful
> functionality for this, but still leaves a lot to be desired.
>
> Hope it helps





--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/Boolean-operations-on-triangular-meshes-tp4661345p4661366.html
Sent from the cgal-discuss mailing list archive at Nabble.com.



Archive powered by MHonArc 2.6.18.

Top of Page