Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Trouble cutting polyhedron using a plane.

Subject: CGAL users discussion list

List archive

[cgal-discuss] Trouble cutting polyhedron using a plane.


Chronological Thread 
  • From: <>
  • To:
  • Subject: [cgal-discuss] Trouble cutting polyhedron using a plane.
  • Date: Tue, 24 Feb 2009 01:16:05 +0100 (CET)


Hi,

I am writing code that constructs bsp-trees. For this I need a robust way of
cutting polyhedra (K-dops, K-discrete oriented polytopes) using a plane. Given
a plane description and a polyhedron I want 2 polyhedra back. As simple as
cutting a block of cheese in 2 with a knife.

I could not find a solution to my problem in the documentation, but I did find
the function polyhedron_cut_plane_3 in header CGAL/polyhedron_cut_plane_3.h

I also found an example program for it:
Polyhedron/polyhedron_prog_cut_cube.cpp
That example works, but when trying to use different splitting planes I get
problems.

Plane pl = Plane(0,1,0,0.5 ); // orientation (0,1,0) offset 0.5, straight
through the [0,1]^3 cube

ERROR: coplanar planes used for computing intersecting point.
Return ORIGIN. Don't trust result.
ERROR: coplanar planes used for computing intersecting point.
Return ORIGIN. Don't trust result.

And it does not modify the given polyhedron.

What is going on? A cutting function that can not cut a cube in 2 equal
halves?
How can I get rid of this problem?

Any help is appreciated,

Thanks,

F!



Archive powered by MHonArc 2.6.16.

Top of Page