Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Finding the a face in a mesh that is coplanar to a given point

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Finding the a face in a mesh that is coplanar to a given point


Chronological Thread 
  • From: Marc Eder <>
  • To:
  • Subject: Re: [cgal-discuss] Finding the a face in a mesh that is coplanar to a given point
  • Date: Fri, 25 Oct 2019 10:41:33 -0400
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=Pass ; spf=None
  • Ironport-phdr: 9a23:i0TpdhGm2kxJIl8McuCGbp1GYnF86YWxBRYc798ds5kLTJ78o82wAkXT6L1XgUPTWs2DsrQY0rGQ4vurBjxIyK3CmUhKSIZLWR4BhJdetC0bK+nBN3fGKuX3ZTcxBsVIWQwt1Xi6NU9IBJS2PAWK8TW94jEIBxrwKxd+KPjrFY7OlcS30P2594HObwlSizexfL1/IA+yoAjfucUbg4hvIbstxxXUpXdFZ/5Yzn5yK1KJmBb86Maw/Jp9/ClVpvks6c1OX7jkcqohVbBXAygoPG4z5M3wqBnMVhCP6WcGUmUXiRVHHQ7I5wznU5jrsyv6su192DSGPcDzULs5Vyiu47ttRRT1jioMKjw3/3zNisFog61brhCuqRxxzYDXfY+bKuZxc7jHct8GX2dMRNpdWzBDD466coABD/ABPeFdr4TloFUBtwG+ChWxD+3g1zBHmGX21rA93uQkDw7JwRIvH8gVvXvIt9X5LroSUeapw6XS0zrMcu5W1C775YPVfB4hpvSMUqhxccrX0UQvERnKgU6LpozhITyZzPgCs2+e7+Z4Se2vhHQoqwVrrjio3McshY/EjZ8WxFDc7Sh13po5KNmiREN4YdOoCoVcuz+HO4dsTc4vQmdlszsgxLIco560Zi0KxYwnxxHBb/yHdJCF4hf5W+aQJTd0nXxkeKiiixqr/0itxezxWtO70FZNqSpFnd3MuW4X2xPP7ciHT+Nx/kan2TmRywDe8v9ILVwwmKbBKJMswqQ8moQNvUjeBCP7l0T7gLeTdko+++io7+rnYq/hpp+ZL4J0jx/xPbkwlcylGuk3LhMOU3KG+eS6yLLv51P2T6hXjvEuiKnWrIjaJdgHpq6+GwJazokj5Ay7Dzu/zdsYnGIHI05YeBKclIjkIErOIfD9DfenmVugijZrx/bcPr3gGJrBNHbDkK2yNYp6vkVTwQ52wdFE7I9PEZkAJujyUwn/ro/2FBg8Zim92e2vJdlwzMtKXG+DD7WxO7iUrFmDoO8jPr/fN8cupD/hJq19tLbVhngjlApFJPX77d4scHm9W89eDQCBe3O12IUKCiEXuAF4QeD32gXbDGxjIk2qVqd53QkVTYKrCYCZG9Koib2FmTihR9hYOj4ABVeLHnPlMY6DXqVUMXPAEopaijUBEIOZZcok3BCquhX9zuM9fOHPvDAevtTu2MUnvuA=

While I'm not sure if this is possible as I'm far from in-depth-experienced with CGAL.... I suspect you can build a custom AABB tree around face normals (just parameterize each normal as a point on a unit sphere (S2)). Then, look for the closest point in that AABB tree, treating your query point normal also as a point on the unit sphere.

On Fri, Oct 25, 2019 at 10:36 AM Andreas Fabri <> wrote:

I do  not see where that helps.  A point coplanar to a face  f
can be far away from f and be close to a non-coplanar face.

      ************
      *                      *
 p   f1                     ***f2**
      *                                    *
      ******************   

p is coplanar with f2 but f1 is closer

On 10/25/2019 4:27 PM, Sebastien Loriot (GeometryFactory) wrote:
You can use AABB_tree::closest_point_and_primitive()

https://doc.cgal.org/latest/AABB_tree/classCGAL_1_1AABB__tree.html#a1b3ac9521fd7257f760deafff3743437

Sebastien.

On 10/24/19 6:05 PM, aseverino wrote:
Hello,

I'm trying to find the face index that has its points coplanar to another
given point. This given point is guaranteed to be coplanar to the mesh
*somewhere*.

Is there a more optimized method to find that face without having to iterate
over all of them (in the worst case)?



--
Sent from: http://cgal-discuss.949826.n4.nabble.com/


-- 
Andreas Fabri, PhD
Chief Officer, GeometryFactory
Editor, The CGAL Project

phone: +33.492.954.912    skype: andreas.fabri


--
Marc Eder
Ph.D. Candidate, Computer Science
University of North Carolina at Chapel Hill



Archive powered by MHonArc 2.6.18.

Top of Page