Subject: CGAL users discussion list
List archive
Re: [cgal-discuss] compatibility problem (old subject: compiling problem in linux)
Chronological Thread
- From: Mahmood NT <>
- To:
- Subject: Re: [cgal-discuss] compatibility problem (old subject: compiling problem in linux)
- Date: Sat, 17 Nov 2007 10:25:49 -0800 (PST)
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Message-ID; b=GcsLBZWANzzNHu/dGe0ozgOFE5oupeERrP90xfuVHX4y0u6/CLq5BXBVg3PoP0wo1U8ww3Pw+Cr2bjVJvJrjoFF6+H00NnBoDvIV56do17wlPMzWmdVO1RzYlmBpIFZcMi9bYDX8348b0v/Cglkz9HjHTzM6c+khKFhApTVOYm8=;
>It hasn't been solved, as you didn't listen to what Camille wrote
>namely to post YOUR code and not sniplets of CGAL code
>namely to post YOUR code and not sniplets of CGAL code
Since the code is long and the message will be lengthy, I decided to mention important things (from what I understand) and put the ALL files in http://ce.sharif.edu/~m_naderan
in Polygon_Voronoi_diagram_2.h, I have:
#ifndef CGAL_POLYGON_VORONOI_DIAGRAM_2_H
#define CGAL_POLYGON_VORONOI_DIAGRAM_2_H
#include <CGAL/tags.h>
#include <CGAL/Polygon_2.h>
#include <CGAL/Segment_Delaunay_graph_hierarchy_2.h>
#include <CGAL/Segment_Delaunay_graph_filtered_traits_2.h>
#include <CGAL/Segment_Delaunay_graph_traits_2.h>
#include <CGAL/Polygon_2.h>
#include <CGAL/Segment_Delaunay_graph_hierarchy_2.h>
#include <CGAL/Segment_Delaunay_graph_filtered_traits_2.h>
#include <CGAL/Segment_Delaunay_graph_traits_2.h>
#include <CGAL/Polygon_feature_2.h>
CGAL_BEGIN_NAMESPACE
/*!
* \class
* Representation of the Voronoi diagram of a set of disjoint polygons.
* Supports the insertion of polygons and the traversal of the finite diagram
* edges.
*/
template <class Kernel_>
class Polygon_Voronoi_diagram_2
{
protected:
* \class
* Representation of the Voronoi diagram of a set of disjoint polygons.
* Supports the insertion of polygons and the traversal of the finite diagram
* edges.
*/
template <class Kernel_>
class Polygon_Voronoi_diagram_2
{
protected:
typedef Kernel_ Kernel;
// Define the (linear) objects from the kernel.
typedef typename Kernel::Segment_2 Segment_2;
typedef typename Kernel::Point_2 Point_2;
typedef Polygon_2<Kernel> Polygon_2;
/*!
* Representation of the sites that constitute a finite Voronoi edge.
* The edge separates between the sites p and q, and its source and
* target points are determined by the point equidistant from <p, q, s>
* and from <p, q, t> respectively.
*/
struct Edge_sites_2
{
class Site_data_2
{
private:
typedef typename Kernel::Segment_2 Segment_2;
typedef typename Kernel::Point_2 Point_2;
typedef Polygon_2<Kernel> Polygon_2;
/*!
* Representation of the sites that constitute a finite Voronoi edge.
* The edge separates between the sites p and q, and its source and
* target points are determined by the point equidistant from <p, q, s>
* and from <p, q, t> respectively.
*/
struct Edge_sites_2
{
class Site_data_2
{
private:
enum
{
UNDEFINED,
POINT_SITE,
SEGMENT_SITE,
} _type; // The site type (a point or a segment).
Point_2 _point; // The point (if is_point is true).
Segment_2 _segment; // The segment (if is_point is false).
int _id; // The polygon this site belongs to.
....
}
....
}
...
private:
{
UNDEFINED,
POINT_SITE,
SEGMENT_SITE,
} _type; // The site type (a point or a segment).
Point_2 _point; // The point (if is_point is true).
Segment_2 _segment; // The segment (if is_point is false).
int _id; // The polygon this site belongs to.
....
}
....
}
...
private:
// Define the traits class for constructing the Voronoi diagram:
// Our segments are non-intersection, as they are edges of simple,
// disjoint polygons. We also work with filtering.
typedef Segment_Delaunay_graph_filtered_traits_without_intersections_2
<Kernel, Ring_tag, Kernel, Ring_tag> Sdg_traits_2;
// Our segments are non-intersection, as they are edges of simple,
// disjoint polygons. We also work with filtering.
typedef Segment_Delaunay_graph_filtered_traits_without_intersections_2
<Kernel, Ring_tag, Kernel, Ring_tag> Sdg_traits_2;
// Since the segments in the diagram are not intersecting, it is sufficient
// to use a simple storage site -- therefore we supply Tag_false as the
// second template parameter.
typedef Segment_Delaunay_graph_vertex_base_2
<Sdg_traits_2, Tag_false> Sdg_vertex_base_2;
...
}
// to use a simple storage site -- therefore we supply Tag_false as the
// second template parameter.
typedef Segment_Delaunay_graph_vertex_base_2
<Sdg_traits_2, Tag_false> Sdg_vertex_base_2;
...
}
the error is:
error C2065: 'Ring_tag' : undeclared identifier
error C2065: 'Ring_tag' : undeclared identifier
in Segment_Delaunay_graph_2.h (CGAL 3.3.1):
CGAL_SEGMENT_DELAUNAY_GRAPH_2_END_NAMESPACE
template<class Gt, class ST, class STag, class DS, class LTag >
class Segment_Delaunay_graph_hierarchy_2;
template<class Gt,
class ST = Segment_Delaunay_graph_storage_traits_2<Gt>,
class DS = Triangulation_data_structure_2 <
Segment_Delaunay_graph_vertex_base_2<ST>,
Triangulation_face_base_2<Gt> >,
class LTag = Tag_false >
class Segment_Delaunay_graph_2
: private Triangulation_2<
Segment_Delaunay_graph_traits_wrapper_2<Gt>, DS >
{
friend class Segment_Delaunay_graph_hierarchy_2<Gt,ST,Tag_true,DS,LTag>;
friend class Segment_Delaunay_graph_hierarchy_2<Gt,ST,Tag_false,DS,LTag>;
protected:
// LOCAL TYPES
//------------
typedef Segment_Delaunay_graph_2<Gt,ST,DS,LTag> Self;
class ST = Segment_Delaunay_graph_storage_traits_2<Gt>,
class DS = Triangulation_data_structure_2 <
Segment_Delaunay_graph_vertex_base_2<ST>,
Triangulation_face_base_2<Gt> >,
class LTag = Tag_false >
class Segment_Delaunay_graph_2
: private Triangulation_2<
Segment_Delaunay_graph_traits_wrapper_2<Gt>, DS >
{
friend class Segment_Delaunay_graph_hierarchy_2<Gt,ST,Tag_true,DS,LTag>;
friend class Segment_Delaunay_graph_hierarchy_2<Gt,ST,Tag_false,DS,LTag>;
protected:
// LOCAL TYPES
//------------
typedef Segment_Delaunay_graph_2<Gt,ST,DS,LTag> Self;
typedef Segment_Delaunay_graph_traits_wrapper_2<Gt> Modified_traits;
typedef Triangulation_2<Modified_traits,DS> DG;
typedef DG Delaunay_graph;
typedef Triangulation_2<Modified_traits,DS> DG;
typedef DG Delaunay_graph;
typedef LTag List_tag;
public:
// PUBLIC TYPES
//-------------
typedef DS Data_structure;
typedef DS Triangulation_data_structure;
typedef Gt Geom_traits;
typedef ST Storage_traits;
typedef typename Gt::Site_2 Site_2;
typedef typename Gt::Point_2 Point_2;
// PUBLIC TYPES
//-------------
typedef DS Data_structure;
typedef DS Triangulation_data_structure;
typedef Gt Geom_traits;
typedef ST Storage_traits;
typedef typename Gt::Site_2 Site_2;
typedef typename Gt::Point_2 Point_2;
typedef typename DS::Edge Edge;
typedef typename DS::Vertex_handle Vertex_handle;
typedef typename DS::Face_handle Face_handle;
typedef typename DS::Vertex Vertex;
typedef typename DS::Face Face;
typedef typename DS::Vertex_handle Vertex_handle;
typedef typename DS::Face_handle Face_handle;
typedef typename DS::Vertex Vertex;
typedef typename DS::Face Face;
typedef typename DS::size_type size_type;
typedef typename DS::Vertex_circulator Vertex_circulator;
typedef typename DS::Edge_circulator Edge_circulator;
typedef typename DS::Face_circulator Face_circulator;
typedef typename DS::Edge_circulator Edge_circulator;
typedef typename DS::Face_circulator Face_circulator;
typedef typename DS::Face_iterator All_faces_iterator;
typedef typename DS::Vertex_iterator All_vertices_iterator;
typedef typename DS::Edge_iterator All_edges_iterator;
typedef typename DS::Vertex_iterator All_vertices_iterator;
typedef typename DS::Edge_iterator All_edges_iterator;
typedef typename DG::Finite_faces_iterator Finite_faces_iterator;
typedef typename DG::Finite_vertices_iterator Finite_vertices_iterator;
typedef typename DG::Finite_edges_iterator Finite_edges_iterator;
typedef typename DG::Finite_vertices_iterator Finite_vertices_iterator;
typedef typename DG::Finite_edges_iterator Finite_edges_iterator;
typedef typename Storage_traits::Point_container Point_container;
typedef typename Storage_traits::Point_handle Point_handle;
typedef typename Storage_traits::const_Point_handle const_Point_handle;
typedef typename Storage_traits::Point_handle Point_handle;
typedef typename Storage_traits::const_Point_handle const_Point_handle;
protected:
typedef typename Geom_traits::Arrangement_type_2 AT2;
typedef typename AT2::Arrangement_type Arrangement_type;
typedef typename Geom_traits::Arrangement_type_2 AT2;
typedef typename AT2::Arrangement_type Arrangement_type;
....
}
I get:
error C2039: 'Arrangement_type_2' : is not a member of 'CGAL::Sdgtw2<Gt_base>'
error C2039: 'const_Point_handle' : is not a member of 'CGAL::Boolean_tag<b>'
with
[
b=true
]
error C2039: 'Point_handle' : is not a member of 'CGAL::Boolean_tag<b>'
with
[
b=true
]
...
there are some other errors, but I think they are related to bad instantiation for
typedef Segment_Delaunay_graph_filtered_traits_without_intersections_2
<Kernel, Ring_tag, Kernel, Ring_tag> Sdg_traits_2;
as Camille said.
typedef Segment_Delaunay_graph_filtered_traits_without_intersections_2
<Kernel, Ring_tag, Kernel, Ring_tag> Sdg_traits_2;
as Camille said.
I think if this problem get solved, some other errors consequently will be solved.
Hope I provide complete and correct imformation.
Thanks,
----- Original Message ----
From: Andreas Fabri <>
To:
Sent: Saturday, November 17, 2007 7:32:05 PM
Subject: Re: [cgal-discuss] compiling problem in linux
Mahmood NT wrote:
> >You should switch to CGAL 3.3.1 or use a gcc compiler available at the
> time
> >when CGAL 3.2 was released. When we release we cannot test with compilers
> >which do not yet exist
> >What about trying CGAL 3.3 ?
> I have a code which is compatible with CGAL 3.2. when I use CGAL 3.3.1,
> I have some errors and I recently post "errors I get from
> segment_delaunay_graph_2.h" and although I have some question and answer
> with Camille Wormser, but it has not solved yet.
It hasn't been solved, as you didn't listen to what Camille wrote
namely to post YOUR code and not sniplets of CGAL code
> so I decided to
> use previous and compatible version of CGAL.
>
> >It might be helpful to write WHERE you type make.
>
> when I am in my project folder (which has a makefile) and try to make.
> CGAL has been installed successfully.
> >Is it really the same, or is it just the same function name.
> >Note that there exist millions of programs with a function
> >called main() without having much in common. So if my main
> >and compiles it might well be that your's doesn't ===:>-
> nice tip ;) it was my fault. but what should I do?
>
> Thanks,
>
> **
>
>
> ----- Original Message ----
> From: Andreas Fabri <>
> To:
> Sent: Saturday, November 17, 2007 7:00:46 PM
> Subject: Re: [cgal-discuss] compiling problem in linux
>
> <mailto:> wrote:
> > Hello,
> > After some challenge with MS .NET 2003, I decided to compile in
> linux. the specifications are:
> >
> > CGAL 3.2
>
> You should switch to CGAL 3.3.1 or use a gcc compiler available at the time
> when CGAL 3.2 was released. When we release we cannot test with compilers
> which do not yet exist
>
>
> > OS: i686_Linux-2.6
> > Compiler: GNU 3.4.2
> > Support for: BOOST, X11, GMP, MPFR, CORE, ZLIB, and QT.
> >
> >
> > by using "make" I get some errors in a file, one of them is:
>
> It might be helpful to write WHERE you type make.
>
> [snip]
> >
> > An intresting thing is the same finite_edges_begin() is used in
> "Alpha" example but with different definition and without compilation
> error. I mean in "Alpha_shape_3.h" it is:
> >
> > typedef typename Dt::Finite_cells_iterator Finite_cells_iterator;
> > ....
> > Finite_edges_iterator eit = finite_edges_begin();
> > for( ; eit != finite_edges_end() ; ++eit){
> > if (classify(*eit, alpha) == type) *it++ = *eit;
> > ...
> >
> > what is wrong with finite_edges_begin() or GCC? if installation menu
> shows that it supports for GCC 3.4, so why it does have problem?
> >
>
> Is it really the same, or is it just the same function name.
> Note that there exist millions of programs with a function
> called main() without having much in common. So if my main
> and compiles it might well be that your's doesn't ===:>-
>
> andreas
>
>
> >
> > Thanks,
> --
> You are currently subscribed to cgal-discuss.
> To unsubscribe or access the archives, go to
> https://lists-sop.inria.fr/wws/info/cgal-discuss
>
>
> ------------------------------------------------------------------------
> Get easy, one-click access to your favorites. Make Yahoo! your homepage.
> <http://us.rd.yahoo.com/evt=51443/*http://www.yahoo.com/r/hs>
--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://lists-sop.inria.fr/wws/info/cgal-discuss
From: Andreas Fabri <>
To:
Sent: Saturday, November 17, 2007 7:32:05 PM
Subject: Re: [cgal-discuss] compiling problem in linux
Mahmood NT wrote:
> >You should switch to CGAL 3.3.1 or use a gcc compiler available at the
> time
> >when CGAL 3.2 was released. When we release we cannot test with compilers
> >which do not yet exist
> >What about trying CGAL 3.3 ?
> I have a code which is compatible with CGAL 3.2. when I use CGAL 3.3.1,
> I have some errors and I recently post "errors I get from
> segment_delaunay_graph_2.h" and although I have some question and answer
> with Camille Wormser, but it has not solved yet.
It hasn't been solved, as you didn't listen to what Camille wrote
namely to post YOUR code and not sniplets of CGAL code
> so I decided to
> use previous and compatible version of CGAL.
>
> >It might be helpful to write WHERE you type make.
>
> when I am in my project folder (which has a makefile) and try to make.
> CGAL has been installed successfully.
> >Is it really the same, or is it just the same function name.
> >Note that there exist millions of programs with a function
> >called main() without having much in common. So if my main
> >and compiles it might well be that your's doesn't ===:>-
> nice tip ;) it was my fault. but what should I do?
>
> Thanks,
>
> **
>
>
> ----- Original Message ----
> From: Andreas Fabri <>
> To:
> Sent: Saturday, November 17, 2007 7:00:46 PM
> Subject: Re: [cgal-discuss] compiling problem in linux
>
> <mailto:> wrote:
> > Hello,
> > After some challenge with MS .NET 2003, I decided to compile in
> linux. the specifications are:
> >
> > CGAL 3.2
>
> You should switch to CGAL 3.3.1 or use a gcc compiler available at the time
> when CGAL 3.2 was released. When we release we cannot test with compilers
> which do not yet exist
>
>
> > OS: i686_Linux-2.6
> > Compiler: GNU 3.4.2
> > Support for: BOOST, X11, GMP, MPFR, CORE, ZLIB, and QT.
> >
> >
> > by using "make" I get some errors in a file, one of them is:
>
> It might be helpful to write WHERE you type make.
>
> [snip]
> >
> > An intresting thing is the same finite_edges_begin() is used in
> "Alpha" example but with different definition and without compilation
> error. I mean in "Alpha_shape_3.h" it is:
> >
> > typedef typename Dt::Finite_cells_iterator Finite_cells_iterator;
> > ....
> > Finite_edges_iterator eit = finite_edges_begin();
> > for( ; eit != finite_edges_end() ; ++eit){
> > if (classify(*eit, alpha) == type) *it++ = *eit;
> > ...
> >
> > what is wrong with finite_edges_begin() or GCC? if installation menu
> shows that it supports for GCC 3.4, so why it does have problem?
> >
>
> Is it really the same, or is it just the same function name.
> Note that there exist millions of programs with a function
> called main() without having much in common. So if my main
> and compiles it might well be that your's doesn't ===:>-
>
> andreas
>
>
> >
> > Thanks,
> --
> You are currently subscribed to cgal-discuss.
> To unsubscribe or access the archives, go to
> https://lists-sop.inria.fr/wws/info/cgal-discuss
>
>
> ------------------------------------------------------------------------
> Get easy, one-click access to your favorites. Make Yahoo! your homepage.
> <http://us.rd.yahoo.com/evt=51443/*http://www.yahoo.com/r/hs>
--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://lists-sop.inria.fr/wws/info/cgal-discuss
Be a better pen pal. Text or chat with friends inside Yahoo! Mail. See how.
- Re: [cgal-discuss] compatibility problem (old subject: compiling problem in linux), Mahmood NT, 11/17/2007
Archive powered by MHonArc 2.6.16.