Point_2d and Point_2f rotation is not well done.
R(origin,Theta) = T-1(origin).R(Theta).T(origin)
Note the following source code
Point_2d &Point_2d::rotate(const Point_2d &origin,
double theta)
{
Vector_2d t(origin.m_p);
*this -= t;
t.rotate(theta); // **** bug ****
*this += t;
return *this;
}
Which is rotating the origin vector around (0,0).
a fixed version should be:
Point_2d &Point_2d::rotate(const Point_2d &origin,
double theta)
{
Vector_2d t(origin.m_p);
*this -= t;
this->rotate(theta); // **** fixed *****
*this += t;
return *this;
}