110 constexpr operator T*();
115 constexpr operator const T*() const;
214 constexpr auto delimiter =
')';
215 std::getline(is, s, delimiter);
216 mtx.fromString(s.append(1, delimiter));
223#include <math/TMatrix22.hpp>
Generic 2 x 2 matrix template.
Definition TMatrix22.h:16
static constexpr auto tolerance
Tolerance for when comparing in the equal operator.
Definition TMatrix22.h:177
void copyTo(T[2][2]) const
Copy to matrix to 2 by 2 value_type array.
TMatrix22 transposed() const
Gets the transposed version of the matrix. A transposed rotation matrix inverts the rotation.
TMatrix22 & fromString(const std::string &s) noexcept(false)
Gets matrix values from the string representation formed like '({1.2,4.5},{5.6,7.8})'....
TMatrix22 & resetOrientation()
Reset the matrix to the so-called 'identity' matrix where a vector is not changed during transformati...
bool isEqual(const TMatrix22 &m, T tol=tolerance) const
Compares the passed matrix within the set tolerance.
TMatrix22(const TMatrix22 &m)
Copy constructor.
T getRotation() const
Gets the rotation of the matrix when it is a square matrix.
TMatrix22()
Default constructor.
TVector2D< T > transformed(const TVector2D< T > &) const
Vector transformation method.
T value_type
Type accessible when implemented.
Definition TMatrix22.h:21
std::string toString() const
Gets the string representation of the matrix formed like '((m00,m01),(m10,m11))'.
TMatrix22(TMatrix22 &&) noexcept
Move constructor.
TMatrix22 & assign(const T[2][2])
Assignment using a 2 by 2 array.
void setRotation(T angle)
Sets the rotation for the matrix.
union sf::TMatrix22::data_type _data
2-dimensional vector for math operations.
Definition TVector2D.h:23
Definition Application.h:10
_GII_FUNC std::istream & operator>>(std::istream &is, ResultData &)
Stream operator for setting up this instance with a setup std::string.
_GII_FUNC std::ostream & operator<<(std::ostream &os, const ResultData &)
Stream operator for the setup std::string.
Storage union of the 2x2 matrix.
Definition TMatrix22.h:184