Subject: CGAL users discussion list
List archive
- From: "Sebastien Loriot (GeometryFactory)" <>
- To:
- Subject: Re: [cgal-discuss] problem
- Date: Wed, 20 Jul 2011 22:18:22 +0200
Several problems.
First you did not correct the bug I already told you in my previous
mail about const FT x() const that should be const FT& x() const
(same for y()).
Second, here:
http://www.cgal.org/Manual/latest/doc_html/cgal_manual/Kernel_23/Chapter_main.html
first sentence:
CGAL, the Computational Geometry Algorithms Library, is written in C++ and consists of three major parts. The first part is the kernel, which consists of constant-size non-modifiable geometric primitive objects and operations on these objects.
which basically mean that you cannot change one coordinate of a point
but only the whole point. Like:
K::Point_2 p = p + K::Vector_2(1,2);
Third, here:
http://www.cgal.org/Manual/latest/doc_html/cgal_manual/Polygon_ref/Class_Polygon_2.html
you have:
Point_2 pgn [ std::size_t i ] const Returns a (const) reference to the
i-th vertex.
So you cannot modify the point at all.
Once the points are inserted into the polygon, you cannot modify them
except removing them. You probably need to modify them before inserting
them in the polygon.
Sebastien.
On 07/20/2011 04:50 PM, Yue Biek wrote:
Hi,
I came front another 2 problems.They are as follows:
P1: Now that I create my own C_point class,I wish to create a C_Ploygon
which is based on the C_Point. I define
a translation function on the polygon. This function just move every
point of the polygon to another place.But it fails.
I wish to know the reason?
P2:Some of the properties in my C_Point are determinate by some
operations on the contours,how can I do with it?
May be my depict are not clear,a example has been attached in the
attachment and my complier is VS2008 in Win7.
Thank you!
- [cgal-discuss] problem, Yue Biek, 07/20/2011
- Re: [cgal-discuss] problem, Sebastien Loriot (GeometryFactory), 07/20/2011
- Re: [cgal-discuss] problem, Yue Biek, 07/21/2011
- Re: [cgal-discuss] problem, ravi teja, 07/21/2011
- Re: [cgal-discuss] problem, Yue Biek, 07/21/2011
- Re: [cgal-discuss] problem, Sebastien Loriot (GeometryFactory), 07/20/2011
Archive powered by MHonArc 2.6.16.