Finished porting BoundingBox to XS

This commit is contained in:
Alessandro Ranellucci
2014-01-07 12:48:09 +01:00
parent ea47f3b6e7
commit b17d06f9d1
24 changed files with 160 additions and 262 deletions

View File

@@ -193,4 +193,32 @@ Pointf::from_SV(SV* point_sv)
}
#endif
void
Pointf::scale(double factor)
{
this->x *= factor;
this->y *= factor;
}
void
Pointf::translate(double x, double y)
{
this->x += x;
this->y += y;
}
void
Pointf3::scale(double factor)
{
Pointf::scale(factor);
this->z *= factor;
}
void
Pointf3::translate(double x, double y, double z)
{
Pointf::translate(x, y);
this->z += z;
}
}