1 #include "RParametrization.hh"
2 #include <Base/Common/W32Compat.hh>
4 #include <Base/Debug/Exception.hh>
5 #include <Base/Common/CompareFloatingPoint.hh>
6 #include <Base/Geometry/HomgPoint2D.hh>
7 #include <Base/Geometry/HomgPoint2DCov.hh>
8 #include <Base/Geometry/RMatrixBase.hh>
9 #include <Base/Geometry/Quaternion.hh>
28 Set(Qvec, covariance);
35 if (Qvec.
size() != 4){
36 BEXCEPTION(
"invalid vector size, must be 4");
47 BEXCEPTION(
"dimension of argument covariance matrix does not match!\n");
75 Load(
const std::string& file)
77 std::ifstream ifs(file.c_str());
91 Save(
const std::string& file)
const
93 std::ofstream ofs(file.c_str());
109 os<<
"orientation= "<<p.
GetVec();
121 is>>temp>>temp>>orientation>>temp>>cov;
122 p.
Set(orientation, cov);
RMatrixBase GetRotationMatrix() const
returns the rotation matrix computed from parametrization
Subscript num_cols() const
void Set(const Vector< Q_TYPE > &Qvec)
Set this from R parametrization.
const Vector< Q_TYPE > & GetVec() const
returns a vector of dimension 6 where first 2 entries are the epipole and the last 4 entries are the ...
Quaternion< Q_TYPE > GetQ() const
returns the quaternion
const Matrix< Q_TYPE > & GetCovarianceMatrix() const
returns the covariance matrix associated with the EQ vector
Slim class bundeling rotation matrix parametrization and associated covariance matrix.
int SetFromQuaternion(const Quaternion< ROTATION_MATRIX_TYPE > &q)
Set rotation matrix from a quaternion.
class Vector4 contains a Vector of dim.
void SetZero()
Sets all values to zero.
std::ostream & operator<<(std::ostream &os, const Array2D< T > &arg)
bool Save(const std::string &file) const
Implements a 3D rotation matrix.
Subscript num_rows() const
bool Load(const std::string &file)
void SetCovarianceMatrix(const Matrix< Q_TYPE > &Cov)
Sets covariance matrix from Cov.
class for rotation with axis and angle
BIASCommon_EXPORT std::istream & operator>>(std::istream &is, BIAS::TimeStamp &ts)
Standard input operator for TimeStamps.