Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Re: Delaunay triangulation_2 opengl rendering problem

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Re: Delaunay triangulation_2 opengl rendering problem


Chronological Thread 
  • From: "Sebastien Loriot (GeometryFactory)" <>
  • To:
  • Subject: Re: [cgal-discuss] Re: Delaunay triangulation_2 opengl rendering problem
  • Date: Wed, 15 Feb 2012 07:06:04 +0100

On 02/15/2012 05:57 AM, mysmax wrote:
Thank you very much for reply.

I had checked before for line but also the issue is same in your
triangulation demo it is fine when an point is inserted the surrounding
edges renders fine but in my case it is missing does my assign is correct.

regards
mysmax

--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/Delaunay-triangulation-2-opengl-rendering-problem-tp4387073p4389508.html
Sent from the cgal-discuss mailing list archive at Nabble.com.


This should be rewritten:
pt1=eit->first->vertex(0)->point();
glVertex2d(pt1.x(),pt1.y());
pt2=eit->first->vertex(1)->point();
glVertex2d(pt2.x(),pt2.y());

as:

pt1=eit->first->vertex((eit->second+1)%3)->point();
glVertex2d(pt1.x(),pt1.y());
pt2=eit->first->vertex((eit->second+2)%3)->point();
glVertex2d(pt2.x(),pt2.y());

As you can see here:
http://www.cgal.org/Manual/latest/doc_html/cgal_manual/TDS_2_ref/Concept_TriangulationDataStructure_2.html#Cross_link_anchor_1336


typedef std::pair<Face_handle,int>
Edge; The edge type. The Edge(f,i) is edge common to faces f and f.neighbor(i). It is also the edge joining the vertices vertex(cw(i)) and vertex(ccw(i)) of f.

Sebastien.



Archive powered by MHonArc 2.6.16.

Top of Page