15 #ifndef __IPSDKMATH_HOMOGRAPHY3D_H__ 16 #define __IPSDKMATH_HOMOGRAPHY3D_H__ 20 #pragma warning (push) 21 #pragma warning (disable : 4251) 23 #include <IPSDKMath/Geometry/3d/Transform/BaseLinearGeometricTransform3d.h> 65 _matA(0, 0) = 1; _matA(0, 1) = 0; _matA(0, 2) = 0; _matA(0, 3) = 0;
66 _matA(1, 0) = 0; _matA(1, 1) = 1; _matA(1, 2) = 0; _matA(1, 3) = 0;
67 _matA(2, 0) = 0; _matA(2, 1) = 0; _matA(2, 2) = 1; _matA(2, 3) = 0;
68 _matA(3, 0) = 0; _matA(3, 1) = 0; _matA(3, 2) = 0; _matA(3, 3) = 1;
79 _matA(0, 0) = axx; _matA(0, 1) = axy; _matA(0, 2) = axz; _matA(0, 3) = axw;
80 _matA(1, 0) = ayx; _matA(1, 1) = ayy; _matA(1, 2) = ayz; _matA(1, 3) = ayw;
81 _matA(2, 0) = azx; _matA(2, 1) = azy; _matA(2, 2) = azz; _matA(2, 2) = azw;
82 _matA(3, 0) = awx; _matA(3, 1) = awy; _matA(3, 2) = awz; _matA(3, 2) = aww;
92 static bool transform(
const Matrix4d& matA,
95 return transform(matA(0, 0), matA(0, 1), matA(0, 2), matA(0, 3),
96 matA(1, 0), matA(1, 1), matA(1, 2), matA(1, 3),
97 matA(2, 0), matA(2, 1), matA(2, 2), matA(2, 3),
98 matA(3, 0), matA(3, 1), matA(3, 2), matA(3, 3),
107 const ipReal64 xTmp = axx*x + axy*y + axz*z + axw;
108 const ipReal64 yTmp = ayx*x + ayy*y + ayz*z + ayw;
109 const ipReal64 zTmp = azx*x + azy*y + azz*z + azw;
128 transform(0, 0) = axx; transform(0, 1) = axy; transform(0, 2) = axz; transform(0, 3) = axw;
129 transform(1, 0) = ayx; transform(1, 1) = ayy; transform(1, 2) = ayz; transform(1, 3) = ayw;
130 transform(2, 0) = azx; transform(2, 1) = azy; transform(2, 2) = azz; transform(2, 2) = azw;
131 transform(3, 0) = awx; transform(3, 1) = awy; transform(3, 2) = awz; transform(3, 2) = aww;
153 matA(0, 0) = axx; matA(0, 1) = axy; matA(0, 2) = axz; matA(0, 3) = axw;
154 matA(1, 0) = ayx; matA(1, 1) = ayy; matA(1, 2) = ayz; matA(1, 3) = ayw;
155 matA(2, 0) = azx; matA(2, 1) = azy; matA(2, 2) = azz; matA(2, 2) = azw;
156 matA(3, 0) = awx; matA(3, 1) = awy; matA(3, 2) = awz; matA(3, 2) = aww;
157 getInvParams(matA(0, 0), matA(0, 1), matA(0, 2), matA(0, 3),
158 matA(1, 0), matA(1, 1), matA(1, 2), matA(1, 3),
159 matA(2, 0), matA(2, 1), matA(2, 2), matA(2, 3),
160 matA(3, 0), matA(3, 1), matA(3, 2), matA(3, 3));
175 static Vector getIdentityParams();
179 void setParams(
const Matrix4d& matA)
188 _matA(0, 0) = axx; _matA(0, 1) = axy; _matA(0, 2) = axz; _matA(0, 3) = axw;
189 _matA(1, 0) = ayx; _matA(1, 1) = ayy; _matA(1, 2) = ayz; _matA(1, 3) = ayw;
190 _matA(2, 0) = azx; _matA(2, 1) = azy; _matA(2, 2) = azz; _matA(2, 2) = azw;
191 _matA(3, 0) = awx; _matA(3, 1) = awy; _matA(3, 2) = awz; _matA(3, 2) = aww;
198 void setParams(
const Vector& params);
207 Matrix4d getHomogenousMatrix()
const;
213 bool isInvertible()
const;
218 Matrix4d getInvHomogenousMatrix()
const;
223 Vector getInvParams()
const;
247 #pragma warning (pop) 249 #endif // __IPSDKMATH_HOMOGRAPHY3D_H__ void setParams(const Matrix4d &matA)
select parameters associated to transformation
Definition: Homography3d.h:197
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
void setIdentity()
set transformation parameters to identity
Definition: Homography3d.h:253
Base class for linear geometric transformation 3d management.
Definition: BaseLinearGeometricTransform3d.h:27
double ipReal64
Base types definition.
Definition: BaseTypes.h:57
IPSDKGEOMETRY_API bool apply(const BaseGeometryTransform2d &transform, BaseGeometryEntity2d &entity)
function allowing to apply in situ a given transformation on an entity
#define IPSDK_DECLARE_TRANSFORM3D(className)
macro allowing to declare a geometric transformation 3d
Definition: Transform3dHdrMacros.h:54
boost::numeric::ublas::vector< ipReal64 > Vector
vector type associated to library
Definition: LinearAlgebraTypes.h:36
#define IPSDKMATH_API
Import/Export macro for library IPSDKMath.
Definition: IPSDKMathExports.h:27
boost::numeric::ublas::bounded_matrix< ipReal64, 4, 4 > Matrix4d
4d matrix (4x4) type associated to library
Definition: LinearAlgebraTypes.h:57
static Vector getIdentityParams()
retrieve identity parameters for transformation
Transformation class allowing to manage 3d homography transformations.
Definition: Homography3d.h:32
#define IPSDK_ENUM(enumTypeStr, enumSeq)
macro allowing to declare an enumerate for library
Definition: EnumMacros.h:26
eTransformParams
Definition: Homography3d.h:39