Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Transformation of 3d point without p.transform

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Transformation of 3d point without p.transform


Chronological Thread 
  • From: Sylvain Pion <>
  • To:
  • Subject: Re: [cgal-discuss] Transformation of 3d point without p.transform
  • Date: Wed, 25 Feb 2009 16:12:38 +0100
  • Organization: INRIA


wrote:
Hello,
how can i change directly the x, y, z, (w) value of an existing point_3
without
using transform?
I want to apply my own transformation on the point. I want to to change the x,
y, and z value for a point in a function and then return the same point with
the new values.

For example:

Point test(1.0,2.0,3.0)

Point transformation(Point in)
{

// in.x(5.3) ???
// in.y(2.3) ???
// in.z(6.4) ???

return in;
}

transformation(test);

This is actually an FAQ :
http://www.cgal.org/FAQ.html#modifiable_kernel

Unfortunately, it is not possible to do it with CGAL's kernels
currently.

The only way to modify a point is to construct a new point,
and assign it to the old one, like : p = Point_2(p.x(), p.y()+1); .

--
Sylvain Pion
INRIA Sophia-Antipolis
Geometrica Project-Team
CGAL, http://cgal.org/

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature




Archive powered by MHonArc 2.6.16.

Top of Page