cv::ccalib::CustomPattern Class Reference 用于 3D 重建的自定义校准模式


#include <opencv2/ccalib.hpp>

Inheritance diagram for cv::ccalib::CustomPattern:
cv::Algorithm

Public Member Functions

  CustomPattern ()
 
virtual  ~CustomPattern ()
 
double  calibrate ( InputArrayOfArrays objectPoints, InputArrayOfArrays imagePoints, Size imageSize, InputOutputArray cameraMatrix, InputOutputArray distCoeffs, OutputArrayOfArrays rvecs, OutputArrayOfArrays tvecs, int flags=0, TermCriteria criteria= TermCriteria ( TermCriteria::COUNT + TermCriteria::EPS , 30, DBL_EPSILON))
 
bool  create ( InputArray pattern, const Size2f boardSize, OutputArray output= noArray ())
 
void  drawOrientation ( InputOutputArray image, InputArray tvec, InputArray rvec, InputArray cameraMatrix, InputArray distCoeffs, double axis_length=3, int axis_width=2)
 
bool  findPattern ( InputArray image, OutputArray matched_features, OutputArray pattern_points, const double ratio=0.7, const double proj_error=8.0, const bool refine_position=false, OutputArray out= noArray (), OutputArray H= noArray (), OutputArray pattern_corners= noArray ())
 
bool  findRt ( InputArray objectPoints, InputArray imagePoints, InputArray cameraMatrix, InputArray distCoeffs, InputOutputArray rvec, InputOutputArray tvec, bool useExtrinsicGuess=false, int flags= SOLVEPNP_ITERATIVE )
 
bool  findRt ( InputArray image, InputArray cameraMatrix, InputArray distCoeffs, InputOutputArray rvec, InputOutputArray tvec, bool useExtrinsicGuess=false, int flags= SOLVEPNP_ITERATIVE )
 
bool  findRtRANSAC ( InputArray objectPoints, InputArray imagePoints, InputArray cameraMatrix, InputArray distCoeffs, InputOutputArray rvec, InputOutputArray tvec, bool useExtrinsicGuess=false, int iterationsCount=100, float reprojectionError=8.0, int minInliersCount=100, OutputArray inliers= noArray (), int flags= SOLVEPNP_ITERATIVE )
 
bool  findRtRANSAC ( InputArray image, InputArray cameraMatrix, InputArray distCoeffs, InputOutputArray rvec, InputOutputArray tvec, bool useExtrinsicGuess=false, int iterationsCount=100, float reprojectionError=8.0, int minInliersCount=100, OutputArray inliers= noArray (), int flags= SOLVEPNP_ITERATIVE )
 
Ptr < DescriptorExtractor getDescriptorExtractor ()
 
Ptr < DescriptorMatcher getDescriptorMatcher ()
 
Ptr < FeatureDetector getFeatureDetector ()
 
void  getPatternPoints (std::vector< KeyPoint > &original_points)
 
double  getPixelSize ()
 
bool  isInitialized ()
 
bool  setDescriptorExtractor ( Ptr < DescriptorExtractor > extractor)
 
bool  setDescriptorMatcher ( Ptr < DescriptorMatcher > matcher)
 
bool  setFeatureDetector ( Ptr < FeatureDetector > featureDetector)
 
-  Public Member Functions inherited from cv::Algorithm
  Algorithm ()
 
virtual  ~Algorithm ()
 
virtual void  clear ()
  Clears the algorithm state. 更多...
 
virtual bool  empty () const
  返回 true 若 Algorithm is empty (e.g. in the very beginning or after unsuccessful read. 更多...
 
virtual 字符串   getDefaultName () const
 
virtual void  read (const FileNode &fn)
  Reads algorithm parameters from a file storage. 更多...
 
virtual void  save (const 字符串 &filename) const
 
virtual void  write ( FileStorage &fs) const
  Stores algorithm parameters in a file storage. 更多...
 
void  write (const Ptr < FileStorage > &fs, const 字符串 &name= 字符串 ()) 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. 更多...
 

额外继承成员

-  Static Public Member Functions inherited from cv::Algorithm
template<typename _Tp >
static Ptr < _Tp >  load (const 字符串 &filename, const 字符串 &objname= 字符串 ())
  Loads algorithm from the file. 更多...
 
template<typename _Tp >
static Ptr < _Tp >  loadFromString (const 字符串 &strModel, const 字符串 &objname= 字符串 ())
  Loads algorithm from a String. 更多...
 
template<typename _Tp >
static Ptr < _Tp >  read (const FileNode &fn)
  Reads algorithm from the file node. 更多...
 
-  Protected Member Functions inherited from cv::Algorithm
void  writeFormat ( FileStorage &fs) const
 

Constructor & Destructor Documentation

◆  CustomPattern()

cv::ccalib::CustomPattern::CustomPattern ( )

◆  ~CustomPattern()

virtual cv::ccalib::CustomPattern::~CustomPattern ( )
virtual

成员函数文档编制

◆  calibrate()

double cv::ccalib::CustomPattern::calibrate ( InputArrayOfArrays   objectPoints ,
InputArrayOfArrays   imagePoints ,
Size   imageSize ,
InputOutputArray   cameraMatrix ,
InputOutputArray   distCoeffs ,
OutputArrayOfArrays   rvecs ,
OutputArrayOfArrays   tvecs ,
int  flags = 0 ,
TermCriteria   criteria = TermCriteria ( TermCriteria::COUNT + TermCriteria::EPS , 30, DBL_EPSILON)  
)

Calls the calirateCamera function with the same inputs.

◆  create()

bool cv::ccalib::CustomPattern::create ( InputArray   pattern ,
const Size2f   boardSize ,
OutputArray   output = noArray ()  
)

◆  drawOrientation()

void cv::ccalib::CustomPattern::drawOrientation ( InputOutputArray   image ,
InputArray   tvec ,
InputArray   rvec ,
InputArray   cameraMatrix ,
InputArray   distCoeffs ,
double  axis_length = 3 ,
int  axis_width = 2  
)

pattern_corners -> projected over the image position of the edges of the pattern.

◆  findPattern()

bool cv::ccalib::CustomPattern::findPattern ( InputArray   image ,
OutputArray   matched_features ,
OutputArray   pattern_points ,
const double  ratio = 0.7 ,
const double  proj_error = 8.0 ,
const bool  refine_position = false ,
OutputArray   out = noArray () ,
OutputArray   H = noArray () ,
OutputArray   pattern_corners = noArray ()  
)

◆  findRt() [1/2]

bool cv::ccalib::CustomPattern::findRt ( InputArray   objectPoints ,
InputArray   imagePoints ,
InputArray   cameraMatrix ,
InputArray   distCoeffs ,
InputOutputArray   rvec ,
InputOutputArray   tvec ,
bool  useExtrinsicGuess = false ,
int  flags = SOLVEPNP_ITERATIVE  
)

◆  findRt() [2/2]

bool cv::ccalib::CustomPattern::findRt ( InputArray   image ,
InputArray   cameraMatrix ,
InputArray   distCoeffs ,
InputOutputArray   rvec ,
InputOutputArray   tvec ,
bool  useExtrinsicGuess = false ,
int  flags = SOLVEPNP_ITERATIVE  
)

Uses solvePnP to find the rotation and translation of the pattern with respect to the camera frame.

◆  findRtRANSAC() [1/2]

bool cv::ccalib::CustomPattern::findRtRANSAC ( InputArray   objectPoints ,
InputArray   imagePoints ,
InputArray   cameraMatrix ,
InputArray   distCoeffs ,
InputOutputArray   rvec ,
InputOutputArray   tvec ,
bool  useExtrinsicGuess = false ,
int  iterationsCount = 100 ,
float  reprojectionError = 8.0 ,
int  minInliersCount = 100 ,
OutputArray   inliers = noArray () ,
int  flags = SOLVEPNP_ITERATIVE  
)

◆  findRtRANSAC() [2/2]

bool cv::ccalib::CustomPattern::findRtRANSAC ( InputArray   image ,
InputArray   cameraMatrix ,
InputArray   distCoeffs ,
InputOutputArray   rvec ,
InputOutputArray   tvec ,
bool  useExtrinsicGuess = false ,
int  iterationsCount = 100 ,
float  reprojectionError = 8.0 ,
int  minInliersCount = 100 ,
OutputArray   inliers = noArray () ,
int  flags = SOLVEPNP_ITERATIVE  
)

◆  getDescriptorExtractor()

Ptr < DescriptorExtractor > cv::ccalib::CustomPattern::getDescriptorExtractor ( )

◆  getDescriptorMatcher()

Ptr < DescriptorMatcher > cv::ccalib::CustomPattern::getDescriptorMatcher ( )

◆  getFeatureDetector()

Ptr < FeatureDetector > cv::ccalib::CustomPattern::getFeatureDetector ( )

◆  getPatternPoints()

void cv::ccalib::CustomPattern::getPatternPoints ( std::vector< KeyPoint > &  original_points )

Returns a vector<Point> of the original points.

◆  getPixelSize()

double cv::ccalib::CustomPattern::getPixelSize ( )

Get the pixel size of the pattern

◆  isInitialized()

bool cv::ccalib::CustomPattern::isInitialized ( )

◆  setDescriptorExtractor()

bool cv::ccalib::CustomPattern::setDescriptorExtractor ( Ptr < DescriptorExtractor extractor )

◆  setDescriptorMatcher()

bool cv::ccalib::CustomPattern::setDescriptorMatcher ( Ptr < DescriptorMatcher matcher )

◆  setFeatureDetector()

bool cv::ccalib::CustomPattern::setFeatureDetector ( Ptr < FeatureDetector featureDetector )

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