0
votes

what does the output of delaunay triangulation represents?

After applying delaunay triangulation in matlab

how to find the vertices of triangle length of the edges of the triangle so that i have to find area of the triangle

please help me.

my output is http://i.stack.imgur.com/oO4aI.jpg

2
From the documentation for delaunay: "TRI is a matrix representing the set of triangles that make up the triangulation... Each row of TRI specifies a triangle defined by indices with respect to the points."beaker
so tri gives the index not the vertices...! can u please give me an idea how to get the vertices of all the triangles??user3260487
The 3 indices for the points of triangle m are given by TRI(m, 1), TRI(m, 2) and TRI(m, 3). The indices refer to the input vectors X and Y, so the coordinates of the first point of triangle m are X(TRI(m,1)) and Y(TRI(m,1))beaker

2 Answers

1
votes

I don't know about the implementation in matlab but a dt is a triangulation of a set of points especially so that the circumference of a circle with all 3 points of a triangle doesn't contain other points of the set. The dt is also useful to find the minimum spanning tree because it can reduce some edges and help to find the minimum spanning tree. You can look into half -edge to find the area. It contains the face, next edge and next vertex at the same time:Voronoi diagram, Delaunay triangulation - data structures.

0
votes

I am assuming that you are using delaunay triangulation on a black & white image.

1) Find the indices of the 'ones' in your b/w image- (Note- the 'ones' are also called as control points)-

[r c v] = find(BW==1);

2) Feed the r and c vectors to the function 'DelaunayTri()'-

dt = DelaunayTri(r,c);

3) dt(1,:) represents the indices of the 1'st triangle, dt(2,:) for the 2nd triangle, and so on.

4) Co-ordinates of the vertices of the 1st triangle are given by-

First vertex -

[ r(dt(1,1))  c(dt(1,1)) ]

Second Vertex -

[ r(dt(1,2))  c(dt(1,2)) ]

Third Vertex -

[ r(dt(1,3))  c(dt(1,3)) ]

5) and so on for other triangles.

Hope that helped.