X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fmatrix.h;h=cb61e292f0eaad46a195995f6c92a5bbf7c1afe8;hp=971d2b362e5441ab2d1dd5f8ff7496424d6d1021;hb=bec07999d95b76f4b47cffcc564d0cd0afc0435e;hpb=a40fc85277dba5c34402a0e703d038efd30cc57b diff --git a/source/matrix.h b/source/matrix.h index 971d2b36..cb61e292 100644 --- a/source/matrix.h +++ b/source/matrix.h @@ -38,6 +38,8 @@ public: Matrix operator*(const Matrix &m) const { return static_cast(*this)*static_cast(m); } Matrix &operator*=(const Matrix &m) { Base::operator*=(m); return *this; } + Matrix operator*(float s) const { return static_cast(*this)*s; } + Matrix &operator*=(float s) { Base::operator*=(s); return *this; } Vector4 operator*(const Vector4 &v) const { return static_cast(*this)*v; } Vector3 operator*(const Vector3 &v) const { return ((*this)*compose(v, 1.0f)).slice<3>(0); } float operator[](unsigned) const;