Subject: CGAL users discussion list
List archive
Re: [cgal-discuss] CGAL Arrangements: connecting edges to arbitrary points on a bezier curve. Feedback wanted.
Chronological Thread
- From: Efi Fogel <>
- To:
- Subject: Re: [cgal-discuss] CGAL Arrangements: connecting edges to arbitrary points on a bezier curve. Feedback wanted.
- Date: Thu, 9 Dec 2021 11:04:03 +0200
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=Pass ; spf=None
- Ironport-data: A9a23:Aakk/a21i9/WjOPL4vbD5bBwkn2cJEfYwER7XOPLsXnJhj930GBUzmdKDDuGbq2JMDegf4okboTi8kMH657SnNcSHQtv/xmBbVoa8JufXYzxwmTYZn7JcJWbFCqL1yivAzX5BJhcokT0+1H9YtANkVEmjfvRH+CkWbaeUsxMbVYMpBkJ2UoLd9ER2dYAbeiRW2thiPuqyyHtEAfNNw1cbgr435m+RCZH55wejt+3UmsWPpintHeG/5Uc4Ql2yauZdxMUSaEMdgK2qnqq8V23wo/Z109F5tKNl7/6dggVWOeXM1TfzHVRXKemj15JoSlaPqQTbqJNLxcKzW/TxpYtmb2htrToIestFqDCmeoaXBRcOy57NKxCvrTAJBBTtOTCkRadLiS2qxlpJBhuYddwFvxMKWpB/PhdJDEWZQ2YnMqt0bejQ69tgN4iJY/lJusiVttI2WmMV7B5VcmWG+OS8YUNhHFq15EXCa2LP4xEfWU6RQrkSBhrFlczKZsYoP2MuHjaZ2QA/QLR+L5fD3P7yQVw1P3yKoOQdIDbA8pSmUmcqyTN+GGRP/3TD/THoRLtz55mrrSnceLHtIMu+HmQ8/drhBiM3DVWBkFHE1S8pva9hwi1XNc3x4k8ksYxhfBayaBpZoCVs96ETLqssRsVWt4WGOo/gO1I4rSB+B6XXwDoURYYAOHLd6YKqfgC2VqAntevDjtq2FFQYRpx6Z/MxQ6P1eMpwaPuqMPKocbpIzUunW3rsi/ycw==
- Ironport-hdrordr: A9a23:nglTOKNfvrBKk8BcTqKjsMiBIKoaSvp037BL7SBMoHNuGfBw+/rFoB15737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Pgk5/v2jXAjg1MdfK+p3YEWaH+iBPhmLV+ZMjLRhMwcGzIKohYmV76tz0aTVCZaIXe0RaM1oD8hT5m3CJ/KAYGrjrvG1yiyGthaZ3tNF0uXQkrubJiOe+sJbHeSPtN5iW5DEqOwTpcokxCorg7zjbR9afHF/zUR8pPl2t8y7OLakVQ+9Cd/Et+GgFyLVHx+om4YW2o2wLxnuh46jUyS1LBxxf1eD91aof1TFRwrMIbViO18Bde1UQ3IepKFSU2tX869Ug02G9k+yttLb0dmEMi5lTjC2TCrCvkbje+lHpsxp4/S3jDfIMlwzz6S2acggV4pT89nOmivh6o5/A/WUd2a236FnrqnIPxPlBXG832OmDLmVK5wXwt5UKGDVncaNBK+RTHR6UbLTrvoArMiYFMpIS+qL6JLbpj2lwwDSquyftvZZG21liG7AhPantux
Hi Kevin,
1. The first approach defeats the purpose of the Bezier traits.
They were developed under those constraints, which enabled efficient code.
2. I think that it is possible to convert a Bezier curve to an implicit form, but it's not trivial.
If the degree of the Bezier curve is fixed or at least bounded, then you can find implicit forms (perhaps using tools like sage).
Is it fixed or bounded?
3. Writing your own Bezier traits is, of course, possible, but not trivial.
The complicated functions are make_x_monotone_2() and intersect_2().
4. Reducing the requirements of your application is always a good thing to do, regardless of the difficulties one faces when not doing it.
As you know now, with the Bezier traits you can only obtain approximations of intersection points.
It implies that theoretically the arrangement where real points are replaced with their approximations (and thus slightly shifted) is not always topologically equivalent to the original arrangement.
This may happen very rarely and may not necessarily be a problem.
Efi
____ _ ____ _
/_____/_) o /__________ __ //
(____ ( ( ( (_/ (_/-(-'_(/
_/
/_____/_) o /__________ __ //
(____ ( ( ( (_/ (_/-(-'_(/
_/
On Tue, 7 Dec 2021 at 06:01, Kevin Morgan <> wrote:
Hi All,I want to connect edges to arbitrary points on a bezier curve.I've posted previously about using Arr_bezier_curve_traits. I want to use it with Algebraic vertices. which are not supported.The main issue is that I want to connect edges to points on a Bezier that may not be endpoints.There are a few ways that I might proceed, and I'd like some feedback from the authors and other users about that.One approach I can take is to attempt to rework Arr_bezier_curve_traits to support Algebraic vertices. That seems daunting to me, because of the underlying exact representation, but I might be overestimating the difficulty and the issues that can arise.Another way, suggested by Efi, is to use Arr_algebraic_segments_traits. The issue with that is that you provide the curves in an implicit form, and Beziers don't have an equivalent implicit form, as far as I can tell. Maybe there's some way to rework it to do what I want.Yet another approach would be to just write my own support for Beziers, independent of that class. I'm familiar with the math involved, but not so much with the CGAL framework, and with template metaprogramming, so this would be a bit of a project. And it seems silly to do this if the functionality exists somewhere in the CGAL framework already.A fourth approach would be to try to work around the issues in my application. Specifically, to replace any bezier segments that have algebraic vertices with new resampled segments that have rational vertices. This would lose information about the original curves. Also, It's not clear how well this would work, because there's not a guarantee about the precision or representation of the intersection points. But I can probably make it work as long as the intersection vertices all agree about the Algebraic to Rational mapping.Comments and suggestions are welcome, and feel free to correct me about any errors or misunderstandings I have about any of this.Thanks,Kevin
--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://sympa.inria.fr/sympa/info/cgal-discuss
- [cgal-discuss] CGAL Arrangements: connecting edges to arbitrary points on a bezier curve. Feedback wanted., Kevin Morgan, 12/07/2021
- Re: [cgal-discuss] CGAL Arrangements: connecting edges to arbitrary points on a bezier curve. Feedback wanted., Efi Fogel, 12/09/2021
Archive powered by MHonArc 2.6.19+.