![]() |
Microscopy Image Browser 2.91
MIB
|
TRIANGULATECURVEPAIR Compute triangulation between a pair of 3D curves. More...
Functions | |
| function [ vertices , facets ] = | triangulateCurvePair (curve1, curve2) |
| TRIANGULATECURVEPAIR Compute triangulation between a pair of 3D curves. | |
TRIANGULATECURVEPAIR Compute triangulation between a pair of 3D curves.
| function [ vertices , facets ] = triangulateCurvePair | ( | curve1, | |
| curve2 ) |
TRIANGULATECURVEPAIR Compute triangulation between a pair of 3D curves.
output = testTriangulateCurvePair(input)
Example % triangulate a surface patch between two ellipses % create two sample curves poly1 = ellipseToPolygon([50 50 40 20 0], 36); poly2 = ellipseToPolygon([50 50 40 20 60], 36); poly1 = poly1(1:end-1,:); poly2 = poly2(1:end-1,:); % transform to 3D polygons / curves curve1 = [poly1 10*ones(size(poly1, 1), 1)]; curve2 = [poly2 20*ones(size(poly2, 1), 1)]; % draw as 3D curves figure(1); clf; hold on; drawPolygon3d(curve1, b); drawPoint3d(curve1, bo); drawPolygon3d(curve2, g); drawPoint3d(curve2, go); view(3); axis equal; [vertices, faces] = triangulateCurvePair(curve1, curve2); % display the resulting mesh figure(2); clf; hold on; drawMesh(vertices, faces); drawPolygon3d(curve1, color, b, linewidth, 2); drawPolygon3d(curve2, color, g, linewidth, 2); view(3); axis equal;
References distancePoints(), min, and minDistancePoints().
