Skip to Content.
Sympa Menu

cgal-discuss - Re: Re: [cgal-discuss][Nef_polyhedron] How to convert aNef_polyhedron_3 into a Nef_polyhedron_2 if meaningful

Subject: CGAL users discussion list

List archive

Re: Re: [cgal-discuss][Nef_polyhedron] How to convert aNef_polyhedron_3 into a Nef_polyhedron_2 if meaningful


Chronological Thread 
  • From: "LoadCom" <>
  • To: "" <>
  • Subject: Re: Re: [cgal-discuss][Nef_polyhedron] How to convert aNef_polyhedron_3 into a Nef_polyhedron_2 if meaningful
  • Date: Wed, 9 Jan 2008 10:01:42 +0800
  • Disposition-notification-to: "LoadCom" <>
  • Organization: LoadCom

Hello Peter,

Thanks for your quick response. It's very helpful indeed.

It's not a surprise to know that the designer of CGAL has never thought
of such a *strange* conversion. Perhaps it's too wild. :-)

From your reply, it seems that it's still possible (I mean not so hard)
to write some code to get such a conversion.

At the present time, efficiency is probably not a main problem for me. The
result I desired is somthing that similar in topology to a Nef_2, or
perferrably,
in terms of a Polygon_with_hole data structure. With that, I can get to
calculte some geometric properties of this polygon, including center of area,
moment of inertia, and so on.

If possible, could you please give me some more detailed instruction with
which I could accomplish that needs?

I really appreciat the help you've given me.

B/Rgds
Max

----- Original Message ----
From: Peter Hachenberger
To:

Sent: 2008-01-08 18:38:41
Subject: Re: [cgal-discuss][Nef_polyhedron] How to convert aNef_polyhedron_3
into a Nef_polyhedron_2 if meaningful

>
Hi Max,

we never really thought about this conversion. So, we don't have it. An
easy thing to do is just to store the points of the Nef_3 and then pass
those points to the constructor of the Nef_2. I guess that any
conversion tool I could write would not be more efficient than that. The
main disadvantage to a real conversion is, that you loose the marks. The
constructor does not allow you to choose for every edge whether it is
selected or not. Does that help you?

Peter

On Mon, 2008-01-07 at 15:38 +0800, LoadCom wrote:
> Hello,
>
> Suppose I have a closed Nef_polyhedron_3 N, and I construct a plane with
> Nef_polyhedron_3 in this manner
>
> Nef_polyhedron_3 N; // closed
>
> // now constructing a plane Nef
> Plane_3 pl(1, 1, 1, 0);
> Nef_polyhedron_3 N_plane(Nef_polyhedron_3(pl) * !Nef_polyhedron_3(pl,
> Nef_polyhedron::EXCLUDED));
>
> // Now I intersect these 2 Nef:
>
> Nef_polyhedron_3 N_res = N * N_plane;
>
> Now N_res is actually a Nef_polyhedron_2, but is there a way to convert it
> into a Nef_polyhedron_2
> and then explore it accordingly?
>
> Thanks in advance.
> Max
>
--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://lists-sop.inria.fr/wws/info/cgal-discuss




Archive powered by MHonArc 2.6.16.

Top of Page