X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fmatrix.cpp;h=a4c36a022a9ecb338406a496760f12c1d0655540;hp=ddc0cdf58c8ac64c72e1d830e6226f0edc2dcfa7;hb=9d1fa012a23693768bbe287371e97751c03acc50;hpb=d8234c16eea3631c1b6e2c10f391ec86d9b97bfa diff --git a/source/matrix.cpp b/source/matrix.cpp index ddc0cdf5..a4c36a02 100644 --- a/source/matrix.cpp +++ b/source/matrix.cpp @@ -22,12 +22,6 @@ Matrix::Matrix(const LinAl::Matrix &other): Base(other) { } -Matrix &Matrix::multiply(const Matrix &other) -{ - *this = *this*other; - return *this; -} - Matrix &Matrix::translate(const Vector3 &t) { return multiply(translation(t)); @@ -43,26 +37,6 @@ Matrix &Matrix::scale(const Vector3 &s) return multiply(scaling(s)); } -Matrix Matrix::operator*(const Matrix &other) const -{ - return static_cast(*this)*static_cast(other); -} - -Matrix &Matrix::operator*=(const Matrix &other) -{ - return multiply(other); -} - -Vector4 Matrix::operator*(const Vector4 &vec) const -{ - return static_cast(*this)*LinAl::Vector(vec); -} - -Vector3 Matrix::operator*(const Vector3 &vec) const -{ - return ((*this)*compose(vec, 1.0f)).slice<3>(0); -} - float Matrix::operator[](unsigned i) const { if(i>=16)