Subject: CGAL users discussion list
List archive
RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?
Chronological Thread
- From: Zhanghong Tang <>
- To: <>
- Subject: RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?
- Date: Wed, 25 Jan 2012 15:11:04 +1200
- Importance: Normal
Hi Guillaume,
Thank you very much for your kindly reply. Now I have the following code to unite many objects into one: typedef struct object { void *obj; }myobj; void UnionObject(myobj *object, void *unionobj, int nobject) { Polyhedron obj, UnitedObj; Nef_polyhedron nef_uni; for (int i=0;i<nobject;i++) { obj=*(Polyhedron *)object[i].obj; Nef_polyhedron nef_obj(obj); if(i==0) nef_uni = nef_obj; else nef_uni = nef_uni + nef_obj; } nef_uni.convert_to_polyhedron(UnitedObj); } However, the program crash in the line Nef_polyhedron nef_obj(obj); Is there any missing to do this? How to modify the code to let the multiple objects be united correctly? I checked the polyhedron obj of every object[i].obj and output them to OFF file and they are all correct (under Guillaume's help). Thanks From: To: Subject: RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL? Date: Wed, 25 Jan 2012 14:00:22 +1200
Hi Guillaume, Thank you very much for your kindly reply. Now I have the following code to unite many objects into one: typedef struct object { void *obj; }myobj; void UnionObject(myobj *object, void *unionobj, int nobject) { Polyhedron obj, UnitedObj; Nef_polyhedron nef_uni; for (int i=0;i<nobject;i++) { obj=*(Polyhedron *)object[i].obj; Nef_polyhedron nef_obj(obj); if(i==0) nef_uni = nef_obj; else nef_uni = nef_uni + nef_obj; } nef_uni.convert_to_polyhedron(UnitedObj); } However, the program crash in the line Nef_polyhedron nef_obj(obj); Is there any missing to do this? I checked the polyhedron obj of every object[i].obj and output them to OFF file and they are all correct (under Guillaume's help). Thanks Date: Tue, 24 Jan 2012 10:20:05 +0100 From: To: Subject: Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL? Hi,
The benefit is genericity.
No this is not possible: you have to use the format required by the incremental builder class...
Use ofstream. Cf for example http://www.cplusplus.com/doc/tutorial/files/ Guillaume
-- =================================================================== Guillaume DAMIAND CNRS, LIRIS UMR 5205 Université Claude Bernard Bâtiment Nautibus (710) 43 Boulevard du 11 Novembre 1918 69622 Villeurbanne Cedex (France) ------------------------------------------------------------------- Phone: +33 (0)4.72.43.26.62 Fax: +33 (0)4.72.43.15.36 Mail: =================================================================== |
- [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/12/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/18/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/18/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/18/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/24/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Guillaume Damiand, 01/24/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/24/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/24/2012
- Message not available
- Message not available
- Message not available
- Message not available
- FW: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/25/2012
- Re: FW: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Winnie Hellmann, 01/25/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/25/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/25/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/25/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/27/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/27/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/27/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/29/2012
- FW: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/30/2012
- Re: FW: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/30/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/30/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/31/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/24/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Guillaume Damiand, 01/24/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/24/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/18/2012
- RE: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Zhanghong Tang, 01/18/2012
- Re: [cgal-discuss] What's the minimal requirement to use the Constructive Solid Geometry (CSG) module of CGAL?, Sebastien Loriot (GeometryFactory), 01/18/2012
Archive powered by MHonArc 2.6.16.