10 #ifndef EIGEN_SCALING_H 11 #define EIGEN_SCALING_H 14 #include "./InternalHeaderCheck.h" 39 template <
typename Scalar,
int Dim,
int Mode>
40 struct uniformscaling_times_affine_returntype {
42 typedef Transform<Scalar, Dim, NewMode> type;
46 template <
typename Scalar_>
47 class UniformScaling {
61 inline const Scalar& factor()
const {
return m_factor; }
62 inline Scalar& factor() {
return m_factor; }
74 template <
int Dim,
int Mode,
int Options>
78 res.prescale(factor());
84 template <
typename Derived>
86 return other * m_factor;
89 template <
typename Derived,
int Dim>
102 template <
typename NewScalarType>
108 template <
typename OtherScalarType>
110 m_factor =
Scalar(other.factor());
119 return internal::isApprox(m_factor, other.factor(), prec);
131 template <
typename Derived,
typename Scalar>
132 EIGEN_EXPR_BINARYOP_SCALAR_RETURN_TYPE(Derived, Scalar, product)
134 return matrix.derived() * s.factor();
142 template <
typename RealScalar>
148 template <
typename Scalar>
153 template <
typename Scalar>
161 template <
typename Derived>
167 template <
typename Derived>
182 template <
typename Scalar>
187 res.
linear().diagonal().fill(factor());
189 res(Dim, Dim) =
Scalar(1);
195 #endif // EIGEN_SCALING_H
DiagonalMatrix< float, 3 > AlignedScaling3f
Definition: Scaling.h:177
DiagonalMatrix< float, 2 > AlignedScaling2f
Definition: Scaling.h:173
Represents a diagonal matrix with its storage.
Definition: DiagonalMatrix.h:172
Namespace containing all symbols from the Eigen library.
Definition: B01_Experimental.dox:1
Definition: Constants.h:455
Holds information about the various numeric (i.e. scalar) types allowed by Eigen. ...
Definition: NumTraits.h:232
UniformScaling< float > Scaling(float s)
Definition: Scaling.h:138
Represents a translation transformation.
Definition: ForwardDeclarations.h:463
Common base class for compact rotation representations.
Definition: ForwardDeclarations.h:455
const DiagonalWrapper< const Derived > asDiagonal() const
Definition: DiagonalMatrix.h:347
RotationMatrixType toRotationMatrix() const
Definition: RotationBase.h:47
DiagonalMatrix< double, 3 > AlignedScaling3d
Definition: Scaling.h:179
DiagonalMatrix< double, 2 > AlignedScaling2d
Definition: Scaling.h:175
Expression of a diagonal matrix.
Definition: DiagonalMatrix.h:320
The matrix class, also used for vectors and row-vectors.
Definition: Matrix.h:186
Definition: Constants.h:458
Base class for all dense matrices, vectors, and expressions.
Definition: MatrixBase.h:52