Subject: CGAL users discussion list
List archive
Re: [cgal-discuss] CGAL polygon intersection predicate - precondition exception!
Chronological Thread
- From: ravi teja <>
- To:
- Subject: Re: [cgal-discuss] CGAL polygon intersection predicate - precondition exception!
- Date: Tue, 19 Jul 2011 15:39:55 +0530
ok...
--
On Tue, Jul 19, 2011 at 3:36 PM, Gernot H. Gutschi <> wrote:
Hi!
Which kernel are you using? You have to use an exact constructions kernel for intersections.
Ng
GernotAm 19.07.2011 11:47 schrieb "Gillian Ng" <>:
> I'm just trying to find out if two polygons intersect. However it gives this
> error, which seems odd... I'm using CGAL 3.6.1 with Visual Studio .NET 2005.
>
> ----------
> CGAL error: precondition violation!
> _expression_ : ! _predP->is_valid() || comp_f(object, _predP->object) !=
> SMALLER
> File : d:\libs\cgal_vc8\include\cgal\multiset.h
> Line : 2142
> Explanation:
> Refer to the bug-reporting instructions at
> http://www.cgal.org/bug_report.html
> ----------
>
> This is the code I wrote:
>
> ----------
> typedef CGAL::Exact_predicates_inexact_constructions_kernel K;
> typedef CGAL::Polygon_2 <K> Polygon_2;
>
> bool DoPolygonsIntersect( Polygon_2 &p1, Polygon_2 &p2 )
> {
> if ( CGAL::do_overlap( p1.bbox(), p2.bbox() ) )
> {
> if ( CGAL::do_intersect( p1, p2 ) )
> {
> return true;
> }
> }
>
> return false;
> }
> ----------
>
> Please help! Thanks a lot guys.
>
> --
> View this message in context: http://cgal-discuss.949826.n4.nabble.com/CGAL-polygon-intersection-predicate-precondition-exception-tp3677725p3677725.html
> Sent from the cgal-discuss mailing list archive at Nabble.com.
>
> --
> You are currently subscribed to cgal-discuss.
> To unsubscribe or access the archives, go to
> https://lists-sop.inria.fr/wws/info/cgal-discuss
>
--
This New Year, may your right hand always be stretched out
in friendship, never in want.
T.Raviteja
+91 9042 4379 38
T.Raviteja
+91 9042 4379 38
+91 9940 1334 61
- [cgal-discuss] CGAL polygon intersection predicate - precondition exception!, Gillian Ng, 07/19/2011
- Re: [cgal-discuss] CGAL polygon intersection predicate - precondition exception!, Gernot H. Gutschi, 07/19/2011
- Re: [cgal-discuss] CGAL polygon intersection predicate - precondition exception!, ravi teja, 07/19/2011
- [cgal-discuss] generating mesh from alpha shape, Farhad Bazyari, 07/19/2011
- Re: [cgal-discuss] generating mesh from alpha shape, Mariette Yvinec, 07/19/2011
- [cgal-discuss] Re: CGAL polygon intersection predicate - precondition exception!, Gillian Ng, 07/20/2011
- Re: [cgal-discuss] Re: CGAL polygon intersection predicate - precondition exception!, Sebastien Loriot (GeometryFactory), 07/20/2011
- [cgal-discuss] Re: CGAL polygon intersection predicate - precondition exception!, Gillian Ng, 07/21/2011
- Re: [cgal-discuss] Re: CGAL polygon intersection predicate - precondition exception!, Sebastien Loriot (GeometryFactory), 07/20/2011
- Re: [cgal-discuss] CGAL polygon intersection predicate - precondition exception!, Gernot H. Gutschi, 07/19/2011
Archive powered by MHonArc 2.6.16.