mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
* Refactoring of the class hierarchy: introduction of DenseDirectAccessBase, removal of extra _Base/_Options template parameters.
* Introduction of strides-at-compile-time so for example the optimized code really knows when it needs to evaluate to a temporary * StorageKind / XprKind * Quaternion::setFromTwoVectors: use JacobiSVD instead of SVD * ComplexSchur: support the 1x1 case
This commit is contained in:
@@ -43,7 +43,7 @@ template<typename MatrixType,int Direction>
|
||||
struct ei_traits<Homogeneous<MatrixType,Direction> >
|
||||
: ei_traits<MatrixType>
|
||||
{
|
||||
typedef typename ei_traits<MatrixType>::StorageType StorageType;
|
||||
typedef typename ei_traits<MatrixType>::StorageKind StorageKind;
|
||||
typedef typename ei_nested<MatrixType>::type MatrixTypeNested;
|
||||
typedef typename ei_unref<MatrixTypeNested>::type _MatrixTypeNested;
|
||||
enum {
|
||||
|
||||
@@ -513,7 +513,7 @@ inline Derived& QuaternionBase<Derived>::setFromTwoVectors(const MatrixBase<Deri
|
||||
{
|
||||
c = std::max<Scalar>(c,-1);
|
||||
Matrix<Scalar,2,3> m; m << v0.transpose(), v1.transpose();
|
||||
SVD<Matrix<Scalar,2,3> > svd(m);
|
||||
JacobiSVD<Matrix<Scalar,2,3> > svd(m);
|
||||
Vector3 axis = svd.matrixV().col(2);
|
||||
|
||||
Scalar w2 = (Scalar(1)+c)*Scalar(0.5);
|
||||
|
||||
Reference in New Issue
Block a user