Direct-BT v3.3.0-1-gc2d430c
Direct-BT - Direct Bluetooth Programming.
|
Represents a affine 2x3 transformation matrix in column major order (memory layout). More...
#include <affine_transform.hpp>
Public Member Functions | |
constexpr | AffineTransform () noexcept |
Initialized to identity. More... | |
constexpr | AffineTransform (AffineTransform &&o) noexcept=default |
constexpr | AffineTransform (const AffineTransform &o) noexcept=default |
constexpr | AffineTransform (const float m00_, const float m10_, const float m01_, const float m11_, const float m02_, const float m12_) noexcept |
AffineTransform (const float mat2xN[], const jau::nsize_t mat_len) noexcept | |
AffineTransform & | concat (const AffineTransform &tR) noexcept |
Concatenates the given matrix to this. More... | |
AffineTransform | createInverse () const |
void | deltaTransform (const float src[], float dst[], size_t length) const noexcept |
float | determinant () const noexcept |
constexpr bool | equals (const AffineTransform &o, const float epsilon=std::numeric_limits< float >::epsilon()) const noexcept |
void | getMatrix (float mat2xN[], const jau::nsize_t mat_len) const noexcept |
AffineTransformType | getType () const noexcept |
void | inverseTransform (const float src[], float dst[], size_t length) const |
bool | isIdentity () const noexcept |
constexpr AffineTransform & | operator= (AffineTransform &&) noexcept=default |
constexpr AffineTransform & | operator= (const AffineTransform &) noexcept=default |
constexpr bool | operator== (const AffineTransform &rhs) const noexcept |
AffineTransform & | preConcat (const AffineTransform &tL) noexcept |
Pre-concatenates the given matrix to this. More... | |
AABBox3f & | resizeBox (AABBox3f &box, const AABBox3f &newBox) noexcept |
Resize the aabbox3f to encapsulate another AABox, which will be transformed on the fly first. More... | |
AffineTransform & | rotate (const float angle, AffineTransform &tmp) noexcept |
AffineTransform & | rotate (const float angle, const float px, const float py, AffineTransform &tmp) noexcept |
AffineTransform & | scale (const float scx, const float scy, AffineTransform &tmp) noexcept |
float | scaleX () const noexcept |
float | scaleY () const noexcept |
AffineTransform & | set (const float m00_, const float m10_, const float m01_, const float m11_, const float m02_, const float m12_) noexcept |
AffineTransform & | setToIdentity () noexcept |
AffineTransform & | setToRotation (const float angle) noexcept |
AffineTransform & | setToRotation (const float angle, const float px, const float py) noexcept |
AffineTransform & | setToScale (const float scx, const float scy) noexcept |
AffineTransform & | setToShear (const float shx, const float shy) noexcept |
AffineTransform & | setToTranslation (const float mx, const float my) noexcept |
AffineTransform & | shear (const float shx, const float shy, AffineTransform &tmp) noexcept |
float | shearX () const noexcept |
float | shearY () const noexcept |
std::string | toString () const noexcept |
AABBox3f & | transform (const AABBox3f &src, AABBox3f &dst) const noexcept |
float * | transform (const float src[], float dst[]) const noexcept |
void | transform (const float src[], float dst[], size_t length) const noexcept |
Vec2f | transform (const Vec2f &src) const noexcept |
Vec2f & | transform (const Vec2f &src, Vec2f &dst) const noexcept |
Vec3f | transform (const Vec3f &src) const noexcept |
Vec3f & | transform (const Vec3f &src, Vec3f &dst) const noexcept |
AffineTransform & | translate (const float mx, const float my, AffineTransform &tmp) noexcept |
float | translateX () const noexcept |
float | translateY () const noexcept |
Static Public Member Functions | |
static AffineTransform | mul (const AffineTransform &tL, const AffineTransform &tR) noexcept |
Multiply matrix of two AffineTransform objects. More... | |
Static Public Attributes | |
static constexpr const float | ZERO = (float)1E-10 |
The min absolute value equivalent to zero, aka EPSILON. More... | |
Represents a affine 2x3 transformation matrix in column major order (memory layout).
Field notation row-column: m10 (row 1, column 0).
Definition at line 86 of file affine_transform.hpp.
|
inlineconstexprnoexcept |
Initialized to identity.
Definition at line 113 of file affine_transform.hpp.
|
inlineconstexprnoexcept |
Definition at line 120 of file affine_transform.hpp.
|
inlinenoexcept |
mat2xN | either a 2x2 or 2x3 matrix depending on mat_len |
mat_len | either 6 for 2x3 matrix or 4 for 2x2 matrix |
Definition at line 131 of file affine_transform.hpp.
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
constexprdefaultnoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Definition at line 209 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 211 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 213 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 215 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 217 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 219 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 221 of file affine_transform.hpp.
|
inlinenoexcept |
mat2xN | either a 2x2 or 2x3 matrix depending on mat_len |
mat_len | either 6 for 2x3 matrix or 4 for 2x2 matrix |
Definition at line 227 of file affine_transform.hpp.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Definition at line 251 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 258 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 271 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 283 of file affine_transform.hpp.
|
inlinenoexcept |
|
inlinenoexcept |
Definition at line 314 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 322 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 326 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 330 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 334 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 338 of file affine_transform.hpp.
|
inlinestaticnoexcept |
Multiply matrix of two AffineTransform objects.
tL | - the AffineTransform object is a multiplicand (left argument) |
tR | - the AffineTransform object is a multiplier (right argument) |
Definition at line 349 of file affine_transform.hpp.
|
inlinenoexcept |
Concatenates the given matrix to this.
Implementations performs the matrix multiplication:
[this] = [this] X [tR]
tR | the right-argument of the matrix multiplication |
Definition at line 370 of file affine_transform.hpp.
|
inlinenoexcept |
Pre-concatenates the given matrix to this.
Implementations performs the matrix multiplication:
[this] = [tL] X [this]
tL | the left-argument of the matrix multiplication |
Definition at line 393 of file affine_transform.hpp.
|
inline |
Definition at line 405 of file affine_transform.hpp.
|
inlinenoexcept |
src | |
dst |
Definition at line 426 of file affine_transform.hpp.
|
inlinenoexcept |
src | |
dst |
src | float[2] source of transformation |
dst | float[2] destination of transformation, maybe be equal to src |
Definition at line 461 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 469 of file affine_transform.hpp.
|
inlinenoexcept |
src | source of transformation |
dst | destination of transformation, maybe be equal to src |
Definition at line 500 of file affine_transform.hpp.
src | source of transformation |
Definition at line 512 of file affine_transform.hpp.
|
inlinenoexcept |
src | source of transformation |
dst | destination of transformation, maybe be equal to src |
Definition at line 524 of file affine_transform.hpp.
src | source of transformation |
dst | destination of transformation, maybe be equal to src |
Definition at line 549 of file affine_transform.hpp.
|
inlinenoexcept |
Resize the aabbox3f to encapsulate another AABox, which will be transformed on the fly first.
newBox | aabbox3f to be encapsulated in |
t | the AffineTransform applied on newBox on the fly |
tmpV3 | temporary storage |
Definition at line 560 of file affine_transform.hpp.
|
inlinenoexcept |
src | |
dst |
Definition at line 579 of file affine_transform.hpp.
|
inline |
src | |
dst |
NoninvertibleTransformException | Vertex& inverseTransform(const Vertex& src, Vertex& dst) const { const float det = getDeterminant(); if (std::abs(det) < ZERO) { throw new NoninvertibleTransformException(determinantIsZero); } const float x = src.x() - m02; const float y = src.y() - m12; dst.setCoord((x * m11 - y * m01) / det, (y * m00 - x * m10) / det, src.z()); return dst; } |
Definition at line 607 of file affine_transform.hpp.
|
inlinenoexcept |
Definition at line 622 of file affine_transform.hpp.
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
Definition at line 639 of file affine_transform.hpp.
|
staticconstexpr |
The min absolute value equivalent to zero, aka EPSILON.
Definition at line 110 of file affine_transform.hpp.