Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Splitting (and simplifying) complex polygon with holes

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Splitting (and simplifying) complex polygon with holes


Chronological Thread 
  • From: "Ch'Gans" <>
  • To:
  • Subject: Re: [cgal-discuss] Splitting (and simplifying) complex polygon with holes
  • Date: Sat, 8 Apr 2017 00:56:25 +1200
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=Pass ; spf=None
  • Ironport-phdr: 9a23:xJaePhWkEIl6h+1roU4rfAFmh53V8LGtZVwlr6E/grcLSJyIuqrYYxSPt8tkgFKBZ4jH8fUM07OQ6PG8HzRYqb+681k6OKRWUBEEjchE1ycBO+WiTXPBEfjxciYhF95DXlI2t1uyMExSBdqsLwaK+i764jEdAAjwOhRoLerpBIHSk9631+ev8JHPfglEnjSwbLd9IRmssQndqtQdjJd/JKo21hbHuGZDdf5MxWNvK1KTnhL86dm18ZV+7SleuO8v+tBZX6nicKs2UbJXDDI9M2Ao/8LrrgXMTRGO5nQHTGoblAdDDhXf4xH7WpfxtTb6tvZ41SKHM8D6Uaw4VDK/5KptVRTmijoINyQh/W7VhMx+jKxVrhG8qRJh34HZe52VOOZkc6/BYd8WWWhMU8BMXCJBGIO8aI4PAvIPMetGr4nxpFoAogG4BQm3Cu/k1zhFiWP23a01yeshFxrG0RcvH9IIqnvYttL1NL0dUe2syqTD0DvNb/RT2Tjn6YjIdAgsru2DXb1qdcrd004vFxnKjliWtIfrPCuV2/wTv2SH6+dsT+Gihm49pw1vvDSj2t0ghpTLi48VzF3P6D93z5wvJdKiTU52ed6kH4VUtyGdL4Z2R9ktQ2BsuCoj070GuoK3cDEEyJg6xRPSa+aLc4eP4hLkW+aRJSl3iGh5d7K4gha+6UmgyuviWcmoyFtGsDZJn93Wun0O1xHf8NaLRuVh8ku7xDqC1QDe5vlBIU8ulKrbL5AhwqQ3lpoWqUnMAi/2mErsg6+QbUUp4eeo6+H9bbXnop+QLZN7igb7Mqg2gMywHfw4MhQSX2ic4emzyLLj8lf9QLlTk/I2k7LZv4zHJcQAva60GBRV04Ym6xanFTiqytUYnX8dLFJEYh2LlYbpO0udaMz/WPywilDpnDZwzO3dJZXgBI/MJz7NiuTPZ7F4vgR3yEUcxNZErdoAAbEOKfTockD3vZrfFBBvYF/8+PruFNgojtBWYmmIGKLMaK4=

On 31 March 2017 at 05:37, Efi Fogel
<>
wrote:
> Check out vertical decomposition; see
> http://doc.cgal.org/latest/Minkowski_sum_2/classCGAL_1_1Polygon__vertical__decomposition__2.html.

Hi Efi,

Is it me or it is not possible to apply the vertical decomposition to
general polygon with circle/segment edges?

The Polygon_vertical_decomposition_2 class uses these harcoded typedefs:
typedef CGAL::Polygon_2<Kernel, Container> Polygon_2;
typedef CGAL::Polygon_with_holes_2<Kernel, Container> Polygon_with_holes_2;
typedef CGAL::Arr_segment_traits_2<Kernel> Arr_segment_traits;
typedef CGAL::Gps_segment_traits_2<Kernel, Container, Arr_segment_traits>
Traits_2;
typedef CGAL::General_polygon_set_2<Traits_2>
General_polygon_set_2;


So I have tried to re-implement the vertical decomposition using
Gps_circle_segment_traits_2, but i'm stuck with a weird problem:
To build a vertical X_monotone_curve_2 connecting two arrangement
vertices (with associated '1 root' points) I need first a 'Kernel'
supporting line, and AFAICT, i cannot build one _exactly_ out of
algebraic numbers...
Actually I am not even sure what exactly a '1 root' point is, does
that mean that it has coordinates expressed as 'a0 +a1*sqrt(r)' with
a0=0 and a1=1? If so then that is an interesting property that i might
be able to exploit.

Another idea i had (but haven't tried yet), is to calculate, using the
Kernel, the intersection point of the supporting lines associated with
the first 2 incident edges of each vertices, they should be
geometrically equivalent to the '1 root' point of the shared vertex
but expressed using the kernel number type. But that would work only
with linear segment, ... bummer!

decomp() and vertical_decomposition() can be easily modified to work
with an arrangement based on Gps_circle_segment_traits_2, the only
blocker for me ATM is the add_vertical_segment()

Does anyone have tips to share on how to make the vertical
decomposition works with the Gps_circle_segment_traits_2, and maybe
could someone tell me if it is actually possible to do it in an exact
manner or not.

Thanks,
Chris



Archive powered by MHonArc 2.6.18.

Top of Page