Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] convex partition with hole

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] convex partition with hole


Chronological Thread 
  • From: Efi Fogel <>
  • To:
  • Subject: Re: [cgal-discuss] convex partition with hole
  • Date: Mon, 18 Jun 2007 01:17:49 +0200


wrote:
i am trying to use


CGAL::approx_convex_partition_2()

with a 2D polygon with an hole
withouth hole no problems, but
with an hole partition is correct
but fill only partialy the polygon

I have used COUNTER_CLOCKWISE for external boundary
and CLOCK_WISE for internal boundary. No intersection
What do you mean? The input of the function consists of a single range.
Is this function compatible with polygon with holes ?
Quoting from the manual of CGAL::approx_convex_partition_2: "Points in the range /[first, beyond)/ must define a simple polygon whose vertices are oriented counterclockwise."

You can try to use CGAL::connect_holes(pwh) to create a sequence of points that define a single non (strictly) simple polygon, and feed it to
a decomposition function. Notice that if the input polygon of connect_holes() has one hole or more, the output polygon is not strictly simple, as its boundary contains overlapping segments, but there are no self intersections.

--
____ _ ____ _
/_____/_) o /__________ __ //
(____ ( ( ( (_/ (_/-(-'_(/
_/






Archive powered by MHonArc 2.6.16.

Top of Page