# distance two Polygon_2

5 messages
Open this post in threaded view
|

## distance two Polygon_2

 I have two polygon 2D (Polygon_2 type) How count distance between A and B   Distance is outer on one of shapes. similar this http://bankfotek.pl/image/2111309.jpeg   if edges of A and outher of B touch together distance is
Open this post in threaded view
|

## Re: distance two Polygon_2

 If the two polygons are CONVEX, you can use: https://doc.cgal.org/4.12/Polytope_distance_d/index.html#Chapter_Optimal_DistancesOn Tue, Feb 20, 2018 at 7:46 AM, xoru wrote:I have two polygon 2D (Polygon_2 type) How count distance between A and B   Distance is outer on one of shapes. similar this http://bankfotek.pl/image/2111309.jpeg   if edges of A and outher of B touch together distance is     -- Renato Silveira     Ph.D. in Computer Science     NTU / UFRGS | Núcleo de Tecnologia Urbana     Porto Alegre - RS - Brazil
Open this post in threaded view
|

## Re: distance two Polygon_2

 In reply to this post by xoru >If the two polygons are CONVEX, you can use: https://doc.cgal.org/4.12/Polytope_distance_d/index.html#Chapter_Optimal_Distances   Hm, ... Tell me letter 'T' or 'C' is convex? My shapes no have holes.   union of ( 0,0 1,0 1,1 0,1 ) and (1,1 2,1 2,2 1,2) is convex? /two box joined one corner/   ?   How count distance between A and B   Distance is outer on one of shapes. similar this http://bankfotek.pl/image/2111309.jpeg   if edges of A and outher of B touch together distance is