OpenCV  3.4.14
Open Source Computer Vision
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
cv::rgbd::RgbdOdometry Class Reference

#include <opencv2/rgbd.hpp>

Inheritance diagram for cv::rgbd::RgbdOdometry:
cv::rgbd::Odometry cv::Algorithm

Public Member Functions

 RgbdOdometry ()
 
 RgbdOdometry (const Mat &cameraMatrix, float minDepth=Odometry::DEFAULT_MIN_DEPTH(), float maxDepth=Odometry::DEFAULT_MAX_DEPTH(), float maxDepthDiff=Odometry::DEFAULT_MAX_DEPTH_DIFF(), const std::vector< int > &iterCounts=std::vector< int >(), const std::vector< float > &minGradientMagnitudes=std::vector< float >(), float maxPointsPart=Odometry::DEFAULT_MAX_POINTS_PART(), int transformType=Odometry::RIGID_BODY_MOTION)
 
cv::Mat getCameraMatrix () const CV_OVERRIDE
 
cv::Mat getIterationCounts () const
 
double getMaxDepth () const
 
double getMaxDepthDiff () const
 
double getMaxPointsPart () const
 
double getMaxRotation () const
 
double getMaxTranslation () const
 
double getMinDepth () const
 
cv::Mat getMinGradientMagnitudes () const
 
int getTransformType () const CV_OVERRIDE
 
virtual Size prepareFrameCache (Ptr< OdometryFrame > &frame, int cacheType) const CV_OVERRIDE
 
void setCameraMatrix (const cv::Mat &val) CV_OVERRIDE
 
void setIterationCounts (const cv::Mat &val)
 
void setMaxDepth (double val)
 
void setMaxDepthDiff (double val)
 
void setMaxPointsPart (double val)
 
void setMaxRotation (double val)
 
void setMaxTranslation (double val)
 
void setMinDepth (double val)
 
void setMinGradientMagnitudes (const cv::Mat &val)
 
void setTransformType (int val) CV_OVERRIDE
 
- Public Member Functions inherited from cv::rgbd::Odometry
bool compute (const Mat &srcImage, const Mat &srcDepth, const Mat &srcMask, const Mat &dstImage, const Mat &dstDepth, const Mat &dstMask, OutputArray Rt, const Mat &initRt=Mat()) const
 
bool compute (Ptr< OdometryFrame > &srcFrame, Ptr< OdometryFrame > &dstFrame, OutputArray Rt, const Mat &initRt=Mat()) const
 
- Public Member Functions inherited from cv::Algorithm
 Algorithm ()
 
virtual ~Algorithm ()
 
virtual void clear ()
 Clears the algorithm state. More...
 
virtual bool empty () const
 Returns true if the Algorithm is empty (e.g. in the very beginning or after unsuccessful read. More...
 
virtual String getDefaultName () const
 
virtual void read (const FileNode &fn)
 Reads algorithm parameters from a file storage. More...
 
virtual void save (const String &filename) const
 
virtual void write (FileStorage &fs) const
 Stores algorithm parameters in a file storage. More...
 
void write (const Ptr< FileStorage > &fs, const String &name=String()) const
 simplified API for language bindings This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 

Static Public Member Functions

static Ptr< RgbdOdometrycreate (const Mat &cameraMatrix=Mat(), float minDepth=Odometry::DEFAULT_MIN_DEPTH(), float maxDepth=Odometry::DEFAULT_MAX_DEPTH(), float maxDepthDiff=Odometry::DEFAULT_MAX_DEPTH_DIFF(), const std::vector< int > &iterCounts=std::vector< int >(), const std::vector< float > &minGradientMagnitudes=std::vector< float >(), float maxPointsPart=Odometry::DEFAULT_MAX_POINTS_PART(), int transformType=Odometry::RIGID_BODY_MOTION)
 
- Static Public Member Functions inherited from cv::rgbd::Odometry
static Ptr< Odometrycreate (const String &odometryType)
 
static float DEFAULT_MAX_DEPTH ()
 
static float DEFAULT_MAX_DEPTH_DIFF ()
 
static float DEFAULT_MAX_POINTS_PART ()
 
static float DEFAULT_MAX_ROTATION ()
 
static float DEFAULT_MAX_TRANSLATION ()
 
static float DEFAULT_MIN_DEPTH ()
 
- Static Public Member Functions inherited from cv::Algorithm
template<typename _Tp >
static Ptr< _Tp > load (const String &filename, const String &objname=String())
 Loads algorithm from the file. More...
 
template<typename _Tp >
static Ptr< _Tp > loadFromString (const String &strModel, const String &objname=String())
 Loads algorithm from a String. More...
 
template<typename _Tp >
static Ptr< _Tp > read (const FileNode &fn)
 Reads algorithm from the file node. More...
 

Protected Member Functions

virtual void checkParams () const CV_OVERRIDE
 
virtual bool computeImpl (const Ptr< OdometryFrame > &srcFrame, const Ptr< OdometryFrame > &dstFrame, OutputArray Rt, const Mat &initRt) const CV_OVERRIDE
 
- Protected Member Functions inherited from cv::Algorithm
void writeFormat (FileStorage &fs) const
 

Protected Attributes

Mat cameraMatrix
 
Mat iterCounts
 
double maxDepth
 
double maxDepthDiff
 
double maxPointsPart
 
double maxRotation
 
double maxTranslation
 
double minDepth
 
Mat minGradientMagnitudes
 
int transformType
 

Additional Inherited Members

- Public Types inherited from cv::rgbd::Odometry
enum  {
  ROTATION = 1,
  TRANSLATION = 2,
  RIGID_BODY_MOTION = 4
}
 

Detailed Description

Odometry based on the paper "Real-Time Visual Odometry from Dense RGB-D Images", F. Steinbucker, J. Strum, D. Cremers, ICCV, 2011.

Constructor & Destructor Documentation

◆ RgbdOdometry() [1/2]

cv::rgbd::RgbdOdometry::RgbdOdometry ( )

◆ RgbdOdometry() [2/2]

cv::rgbd::RgbdOdometry::RgbdOdometry ( const Mat cameraMatrix,
float  minDepth = Odometry::DEFAULT_MIN_DEPTH(),
float  maxDepth = Odometry::DEFAULT_MAX_DEPTH(),
float  maxDepthDiff = Odometry::DEFAULT_MAX_DEPTH_DIFF(),
const std::vector< int > &  iterCounts = std::vector< int >(),
const std::vector< float > &  minGradientMagnitudes = std::vector< float >(),
float  maxPointsPart = Odometry::DEFAULT_MAX_POINTS_PART(),
int  transformType = Odometry::RIGID_BODY_MOTION 
)

Constructor.

Parameters
cameraMatrixCamera matrix
minDepthPixels with depth less than minDepth will not be used (in meters)
maxDepthPixels with depth larger than maxDepth will not be used (in meters)
maxDepthDiffCorrespondences between pixels of two given frames will be filtered out if their depth difference is larger than maxDepthDiff (in meters)
iterCountsCount of iterations on each pyramid level.
minGradientMagnitudesFor each pyramid level the pixels will be filtered out if they have gradient magnitude less than minGradientMagnitudes[level].
maxPointsPartThe method uses a random pixels subset of size frameWidth x frameHeight x pointsPart
transformTypeClass of transformation

Member Function Documentation

◆ checkParams()

virtual void cv::rgbd::RgbdOdometry::checkParams ( ) const
protectedvirtual

Implements cv::rgbd::Odometry.

◆ computeImpl()

virtual bool cv::rgbd::RgbdOdometry::computeImpl ( const Ptr< OdometryFrame > &  srcFrame,
const Ptr< OdometryFrame > &  dstFrame,
OutputArray  Rt,
const Mat initRt 
) const
protectedvirtual

Implements cv::rgbd::Odometry.

◆ create()

static Ptr<RgbdOdometry> cv::rgbd::RgbdOdometry::create ( const Mat cameraMatrix = Mat(),
float  minDepth = Odometry::DEFAULT_MIN_DEPTH(),
float  maxDepth = Odometry::DEFAULT_MAX_DEPTH(),
float  maxDepthDiff = Odometry::DEFAULT_MAX_DEPTH_DIFF(),
const std::vector< int > &  iterCounts = std::vector< int >(),
const std::vector< float > &  minGradientMagnitudes = std::vector< float >(),
float  maxPointsPart = Odometry::DEFAULT_MAX_POINTS_PART(),
int  transformType = Odometry::RIGID_BODY_MOTION 
)
static
Python:
retval=cv.rgbd.RgbdOdometry_create([, cameraMatrix[, minDepth[, maxDepth[, maxDepthDiff[, iterCounts[, minGradientMagnitudes[, maxPointsPart[, transformType]]]]]]]])

◆ getCameraMatrix()

cv::Mat cv::rgbd::RgbdOdometry::getCameraMatrix ( ) const
inlinevirtual
Python:
retval=cv.rgbd_RgbdOdometry.getCameraMatrix()
See also
setCameraMatrix

Implements cv::rgbd::Odometry.

◆ getIterationCounts()

cv::Mat cv::rgbd::RgbdOdometry::getIterationCounts ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getIterationCounts()

◆ getMaxDepth()

double cv::rgbd::RgbdOdometry::getMaxDepth ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMaxDepth()

◆ getMaxDepthDiff()

double cv::rgbd::RgbdOdometry::getMaxDepthDiff ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMaxDepthDiff()

◆ getMaxPointsPart()

double cv::rgbd::RgbdOdometry::getMaxPointsPart ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMaxPointsPart()

◆ getMaxRotation()

double cv::rgbd::RgbdOdometry::getMaxRotation ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMaxRotation()

◆ getMaxTranslation()

double cv::rgbd::RgbdOdometry::getMaxTranslation ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMaxTranslation()

◆ getMinDepth()

double cv::rgbd::RgbdOdometry::getMinDepth ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMinDepth()

◆ getMinGradientMagnitudes()

cv::Mat cv::rgbd::RgbdOdometry::getMinGradientMagnitudes ( ) const
inline
Python:
retval=cv.rgbd_RgbdOdometry.getMinGradientMagnitudes()

◆ getTransformType()

int cv::rgbd::RgbdOdometry::getTransformType ( ) const
inlinevirtual
Python:
retval=cv.rgbd_RgbdOdometry.getTransformType()
See also
setTransformType

Implements cv::rgbd::Odometry.

◆ prepareFrameCache()

virtual Size cv::rgbd::RgbdOdometry::prepareFrameCache ( Ptr< OdometryFrame > &  frame,
int  cacheType 
) const
virtual
Python:
retval=cv.rgbd_RgbdOdometry.prepareFrameCache(frame, cacheType)

Prepare a cache for the frame. The function checks the precomputed/passed data (throws the error if this data does not satisfy) and computes all remaining cache data needed for the frame. Returned size is a resolution of the prepared frame.

Parameters
frameThe odometry which will process the frame.
cacheTypeThe cache type: CACHE_SRC, CACHE_DST or CACHE_ALL.

Reimplemented from cv::rgbd::Odometry.

◆ setCameraMatrix()

void cv::rgbd::RgbdOdometry::setCameraMatrix ( const cv::Mat val)
inlinevirtual
Python:
None=cv.rgbd_RgbdOdometry.setCameraMatrix(val)

See also
getCameraMatrix

Implements cv::rgbd::Odometry.

◆ setIterationCounts()

void cv::rgbd::RgbdOdometry::setIterationCounts ( const cv::Mat val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setIterationCounts(val)

◆ setMaxDepth()

void cv::rgbd::RgbdOdometry::setMaxDepth ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMaxDepth(val)

◆ setMaxDepthDiff()

void cv::rgbd::RgbdOdometry::setMaxDepthDiff ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMaxDepthDiff(val)

◆ setMaxPointsPart()

void cv::rgbd::RgbdOdometry::setMaxPointsPart ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMaxPointsPart(val)

◆ setMaxRotation()

void cv::rgbd::RgbdOdometry::setMaxRotation ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMaxRotation(val)

◆ setMaxTranslation()

void cv::rgbd::RgbdOdometry::setMaxTranslation ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMaxTranslation(val)

◆ setMinDepth()

void cv::rgbd::RgbdOdometry::setMinDepth ( double  val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMinDepth(val)

◆ setMinGradientMagnitudes()

void cv::rgbd::RgbdOdometry::setMinGradientMagnitudes ( const cv::Mat val)
inline
Python:
None=cv.rgbd_RgbdOdometry.setMinGradientMagnitudes(val)

◆ setTransformType()

void cv::rgbd::RgbdOdometry::setTransformType ( int  val)
inlinevirtual
Python:
None=cv.rgbd_RgbdOdometry.setTransformType(val)

See also
getTransformType

Implements cv::rgbd::Odometry.

Member Data Documentation

◆ cameraMatrix

Mat cv::rgbd::RgbdOdometry::cameraMatrix
protected

◆ iterCounts

Mat cv::rgbd::RgbdOdometry::iterCounts
protected

◆ maxDepth

double cv::rgbd::RgbdOdometry::maxDepth
protected

◆ maxDepthDiff

double cv::rgbd::RgbdOdometry::maxDepthDiff
protected

◆ maxPointsPart

double cv::rgbd::RgbdOdometry::maxPointsPart
protected

◆ maxRotation

double cv::rgbd::RgbdOdometry::maxRotation
protected

◆ maxTranslation

double cv::rgbd::RgbdOdometry::maxTranslation
protected

◆ minDepth

double cv::rgbd::RgbdOdometry::minDepth
protected

◆ minGradientMagnitudes

Mat cv::rgbd::RgbdOdometry::minGradientMagnitudes
protected

◆ transformType

int cv::rgbd::RgbdOdometry::transformType
protected

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