Prusa Slicer 2.6.0
Loading...
Searching...
No Matches
Eigen::RefBase< Derived > Class Template Reference

#include <src/eigen/Eigen/src/Core/Ref.h>

+ Inheritance diagram for Eigen::RefBase< Derived >:
+ Collaboration diagram for Eigen::RefBase< Derived >:

Public Types

typedef MapBase< Derived > Base
 

Public Member Functions

EIGEN_DEVICE_FUNC Index innerStride () const
 
EIGEN_DEVICE_FUNC Index outerStride () const
 
EIGEN_DEVICE_FUNC RefBase ()
 

Protected Types

typedef Stride< StrideType::OuterStrideAtCompileTime, StrideType::InnerStrideAtCompileTime > StrideBase
 

Protected Member Functions

template<typename Expression >
EIGEN_DEVICE_FUNC void construct (Expression &expr)
 

Protected Attributes

StrideBase m_stride
 

Private Types

typedef internal::traits< Derived >::PlainObjectType PlainObjectType
 
typedef internal::traits< Derived >::StrideType StrideType
 

Detailed Description

template<typename Derived>
class Eigen::RefBase< Derived >

Member Typedef Documentation

◆ Base

template<typename Derived >
typedef MapBase<Derived> Eigen::RefBase< Derived >::Base

◆ PlainObjectType

template<typename Derived >
typedef internal::traits<Derived>::PlainObjectType Eigen::RefBase< Derived >::PlainObjectType
private

◆ StrideBase

template<typename Derived >
typedef Stride<StrideType::OuterStrideAtCompileTime,StrideType::InnerStrideAtCompileTime> Eigen::RefBase< Derived >::StrideBase
protected

◆ StrideType

template<typename Derived >
typedef internal::traits<Derived>::StrideType Eigen::RefBase< Derived >::StrideType
private

Constructor & Destructor Documentation

◆ RefBase()

template<typename Derived >
EIGEN_DEVICE_FUNC Eigen::RefBase< Derived >::RefBase ( )
inline
83 : Base(0,RowsAtCompileTime==Dynamic?0:RowsAtCompileTime,ColsAtCompileTime==Dynamic?0:ColsAtCompileTime),
84 // Stride<> does not allow default ctor for Dynamic strides, so let' initialize it with dummy values:
85 m_stride(StrideType::OuterStrideAtCompileTime==Dynamic?0:StrideType::OuterStrideAtCompileTime,
86 StrideType::InnerStrideAtCompileTime==Dynamic?0:StrideType::InnerStrideAtCompileTime)
87 {}
internal::traits< Derived >::StrideType StrideType
Definition Ref.h:62
StrideBase m_stride
Definition Ref.h:120
MapBase< Derived > Base
Definition Ref.h:66
const int Dynamic
Definition Constants.h:21

Member Function Documentation

◆ construct()

template<typename Derived >
template<typename Expression >
EIGEN_DEVICE_FUNC void Eigen::RefBase< Derived >::construct ( Expression &  expr)
inlineprotected
97 {
99
100 if(PlainObjectType::RowsAtCompileTime==1)
101 {
102 eigen_assert(expr.rows()==1 || expr.cols()==1);
103 ::new (static_cast<Base*>(this)) Base(expr.data(), 1, expr.size());
104 }
105 else if(PlainObjectType::ColsAtCompileTime==1)
106 {
107 eigen_assert(expr.rows()==1 || expr.cols()==1);
108 ::new (static_cast<Base*>(this)) Base(expr.data(), expr.size(), 1);
109 }
110 else
111 ::new (static_cast<Base*>(this)) Base(expr.data(), expr.rows(), expr.cols());
112
113 if(Expression::IsVectorAtCompileTime && (!PlainObjectType::IsVectorAtCompileTime) && ((Expression::Flags&RowMajorBit)!=(PlainObjectType::Flags&RowMajorBit)))
114 ::new (&m_stride) StrideBase(expr.innerStride(), StrideType::InnerStrideAtCompileTime==0?0:1);
115 else
116 ::new (&m_stride) StrideBase(StrideType::OuterStrideAtCompileTime==0?0:expr.outerStride(),
117 StrideType::InnerStrideAtCompileTime==0?0:expr.innerStride());
118 }
#define eigen_assert(x)
Definition Macros.h:579
#define EIGEN_STATIC_ASSERT_SAME_MATRIX_SIZE(TYPE0, TYPE1)
Definition StaticAssert.h:189
internal::traits< Derived >::PlainObjectType PlainObjectType
Definition Ref.h:61
EIGEN_DEVICE_FUNC Index innerStride() const
Definition Ref.h:69
Stride< StrideType::OuterStrideAtCompileTime, StrideType::InnerStrideAtCompileTime > StrideBase
Definition Ref.h:93
EIGEN_DEVICE_FUNC Index outerStride() const
Definition Ref.h:74
const unsigned int RowMajorBit
Definition Constants.h:61
if(!(yy_init))
Definition lexer.c:1190

References eigen_assert, EIGEN_STATIC_ASSERT_SAME_MATRIX_SIZE, Eigen::RefBase< Derived >::m_stride, and Eigen::RowMajorBit.

Referenced by Eigen::Ref< PlainObjectType, Options, StrideType >::Ref(), Eigen::Ref< SparseMatrix< MatScalar, MatOptions, MatIndex >, Options, StrideType >::Ref(), Eigen::Ref< SparseVector< MatScalar, MatOptions, MatIndex >, Options, StrideType >::Ref(), Eigen::Ref< SparseMatrix< MatScalar, MatOptions, MatIndex >, Options, StrideType >::Ref(), Eigen::Ref< PlainObjectType, Options, StrideType >::Ref(), Eigen::Ref< SparseMatrix< MatScalar, MatOptions, MatIndex >, Options, StrideType >::Ref(), Eigen::Ref< SparseVector< MatScalar, MatOptions, MatIndex >, Options, StrideType >::Ref(), Eigen::Ref< const TPlainObjectType, Options, StrideType >::construct(), Eigen::Ref< const SparseMatrix< MatScalar, MatOptions, MatIndex >, Options, StrideType >::construct(), Eigen::Ref< const SparseVector< MatScalar, MatOptions, MatIndex >, Options, StrideType >::construct(), Eigen::Ref< const TPlainObjectType, Options, StrideType >::construct(), Eigen::Ref< const SparseMatrix< MatScalar, MatOptions, MatIndex >, Options, StrideType >::construct(), and Eigen::Ref< const SparseVector< MatScalar, MatOptions, MatIndex >, Options, StrideType >::construct().

+ Here is the caller graph for this function:

◆ innerStride()

template<typename Derived >
EIGEN_DEVICE_FUNC Index Eigen::RefBase< Derived >::innerStride ( ) const
inline
70 {
71 return StrideType::InnerStrideAtCompileTime != 0 ? m_stride.inner() : 1;
72 }
EIGEN_DEVICE_FUNC Index inner() const
Definition Stride.h:80

References Eigen::Stride< _OuterStrideAtCompileTime, _InnerStrideAtCompileTime >::inner(), and Eigen::RefBase< Derived >::m_stride.

+ Here is the call graph for this function:

◆ outerStride()

template<typename Derived >
EIGEN_DEVICE_FUNC Index Eigen::RefBase< Derived >::outerStride ( ) const
inline
75 {
76 return StrideType::OuterStrideAtCompileTime != 0 ? m_stride.outer()
77 : IsVectorAtCompileTime ? this->size()
78 : int(Flags)&RowMajorBit ? this->cols()
79 : this->rows();
80 }
EIGEN_DEVICE_FUNC Index outer() const
Definition Stride.h:77
constexpr auto size(const C &c) -> decltype(c.size())
Definition span.hpp:183
size_t cols(const T &raster)
Definition MarchingSquares.hpp:60
size_t rows(const T &raster)
Definition MarchingSquares.hpp:55

References Eigen::RefBase< Derived >::m_stride, Eigen::Stride< _OuterStrideAtCompileTime, _InnerStrideAtCompileTime >::outer(), and Eigen::RowMajorBit.

+ Here is the call graph for this function:

Member Data Documentation

◆ m_stride


The documentation for this class was generated from the following file: