filled in scale() transformation in util/Transform

git-svn-id: svn://anubis/fart/trunk@28 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
Josh Holtrop committed 2009-01-22 20:36:05 +00:00
1 parent 13d7d90b87
commit cd9530d21b
3 files changed
+11 -21

No files matched your search

+5 -1
View File
@@ -22,5 +22,9 @@ void Transform::rotate(double amt, double xv, double yv, double zv)
void Transform::scale(double xs, double ys, double zs)
{
/* TODO: fill in */
Matrix t = Matrix::identity();
t[0][0] = xs;
t[1][1] = ys;
t[2][2] = zs;
m_matrix *= t;
}
+1
View File
@@ -12,6 +12,7 @@ class Transform
void translate(double x, double y, double z);
void rotate(double amt, double xv, double yv, double zv);
void scale(double xs, double ys, double zs);
Matrix & getMatrix() { return m_matrix; }
protected:
Matrix m_matrix;