Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Delaunay triangulation by contour

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Delaunay triangulation by contour


Chronological Thread 
  • From: Aurélien .... <>
  • To:
  • Subject: Re: [cgal-discuss] Delaunay triangulation by contour
  • Date: Thu, 29 Jul 2010 11:23:15 +0200
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=UmLircYt9uqvFvTBy/4BolXLS0ySoRoaNKutIcC1FAeWphgB8e2R/VvW6NH0/mejhK vZUPHNP1o3DnQzFj/AexTaQrTZzdFpJUwA/g9LzXGfMXMTZSUpZBeEwQMMZUBP+QbCom fCnK06xeOr5XRgjKPx/yfCUbdBIaXC9dt/veA=

Hello Manuel,

I tried with the is_in_domain() function, but it returns always false..

What does it mean ?

Thank you very much,

Aurélien

On Thu, Jul 29, 2010 at 10:41 AM, Manuel Caroli <> wrote:
Dear Aurélien,

I don't know the 2D mesher very well but there seems to be a member function is_in_domain() for the faces:
http://www.cgal.org/Manual/latest/doc_html/cgal_manual/Mesh_2_ref/Concept_DelaunayMeshFaceBase_2.html

If you use this function to filter your output you should get what you want.

Hope this helps

Manuel



On 28/07/10 21:59, Aurélien .... wrote:
Hello everyone,

I have a polygon defined by a contour which is define by its points.

I tried to make a thing like a L :
 __
|    |
|    |
|    |___
|______|

But after drawing the faces, I have something like that
 __
|    \
|      \
|       \
|_____|

My code (approximative) :
typedef CGAL::Exact_predicates_inexact_constructions_kernel K;
typedef CGAL::Triangulation_vertex_base_2<K> Vbase;
typedef CGAL::Triangulation_vertex_base_with_info_2<unsigned int,
K,Vbase> Vb;
typedef CGAL::Delaunay_mesh_face_base_2<K> Fb;
typedef CGAL::Triangulation_data_structure_2<Vb, Fb> Tds;
typedef CGAL::Constrained_Delaunay_triangulation_2<K, Tds> CDT;
typedef CGAL::Delaunay_mesh_size_criteria_2<CDT> Criteria;
typedef CGAL::Delaunay_mesher_2<CDT, Criteria> Mesher;
typedef CDT::Vertex_handle Vertex_handle;
typedef CDT::Point Point;
typedef CDT::Face_iterator        Face_iterator;
typedef CDT::Vertex_iterator    Vertex_iterator;

CDT cdt;
cdt.insert_constraint(Point(100, 100), Point(100, 200));
cdt.insert_constraint(Point(100, 200), Point(150, 200));
cdt.insert_constraint(Point(150, 200), Point(150, 150));
cdt.insert_constraint(Point(150, 150), Point(200, 150));
cdt.insert_constraint(Point(200, 150), Point(200, 100));
cdt.insert_constraint(Point(200, 100), Point(100, 100));

In fact, it's drawing all faces I need but also the face which make the
geometry wrong. The only difference I saw is that the "wrong face" was
in clockwise and others in counter clockwise...

Is there is a way to archieve what I want to make ?

Thank you very much,

Aurélien


--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://lists-sop.inria.fr/wws/info/cgal-discuss





Archive powered by MHonArc 2.6.16.

Top of Page