![]() |
OpenCV 4.11.0
开源计算机视觉库
|
视频稳定模块包含一组用于点云之间或图像之间全局运动估计的函数和类。在后一种情况下,特征会在内部提取和匹配。为方便起见,运动估计函数被封装在类中。函数和类都可以使用。
类 | |
| 类 | cv::videostab::FromFileMotionReader |
| 类 | cv::videostab::GaussianMotionFilter |
| 类 | cv::videostab::ImageMotionEstimatorBase |
| 以帧为输入的全局二维运动估计方法的基类。 更多… | |
| 类 | cv::videostab::IMotionStabilizer |
| 类 | cv::videostab::KeypointBasedMotionEstimator |
| 描述一种使用关键点检测和光流进行匹配的全局二维运动估计方法。 更多… | |
| 类 | cv::videostab::LpMotionStabilizer |
| 类 | cv::videostab::MotionEstimatorBase |
| 所有全局运动估计方法的基类。 更多… | |
| 类 | cv::videostab::MotionEstimatorL1 |
| 描述一种最小化L1误差的全局二维运动估计方法。 更多… | |
| 类 | cv::videostab::MotionEstimatorRansacL2 |
| 描述一种基于RANSAC的鲁棒全局二维运动估计方法,最小化L2误差。 更多… | |
| 类 | cv::videostab::MotionFilterBase |
| 类 | cv::videostab::MotionStabilizationPipeline |
| 结构体 | cv::videostab::RansacParams |
| 描述RANSAC方法的参数。 更多… | |
| 类 | cv::videostab::ToFileMotionWriter |
枚举 | |
| 枚举 | cv::videostab::MotionModel { cv::videostab::MM_TRANSLATION = 0 , cv::videostab::MM_TRANSLATION_AND_SCALE = 1 , cv::videostab::MM_ROTATION = 2 , cv::videostab::MM_RIGID = 3 , cv::videostab::MM_SIMILARITY = 4 , cv::videostab::MM_AFFINE = 5 , cv::videostab::MM_HOMOGRAPHY = 6 , cv::videostab::MM_UNKNOWN = 7 } |
| 描述两个点云之间的运动模型。 更多… | |
函数 | |
| cv::videostab::GaussianMotionFilter::GaussianMotionFilter (int radius=15, float stdev=-1.f) | |
| cv::videostab::RansacParams::RansacParams (int size, float thresh, float eps, float prob) | |
| 构造函数。 | |
| Mat | cv::videostab::ensureInclusionConstraint (const Mat &M, Size size, float trimRatio) |
| Mat | cv::videostab::estimateGlobalMotionLeastSquares (InputOutputArray points0, InputOutputArray points1, int model=MM_AFFINE, float *rmse=0) |
| 以最小二乘法估计两个二维点云之间的最佳全局运动。 | |
| Mat | cv::videostab::estimateGlobalMotionRansac (InputArray points0, InputArray points1, int model=MM_AFFINE, const RansacParams ¶ms=RansacParams::default2dMotion(MM_AFFINE), float *rmse=0, int *ninliers=0) |
| 鲁棒地(使用RANSAC方法)估计两个二维点云之间的最佳全局运动。 | |
| 浮点数 | cv::videostab::estimateOptimalTrimRatio (const Mat &M, Size size) |
| Mat | cv::videostab::getMotion (int from, int to, const std::vector< Mat > &motions) |
| 假设所有中间运动已知,计算两帧之间的运动。 | |
#include <opencv2/videostab/motion_core.hpp>
描述两个点云之间的运动模型。
|
内联 |
|
内联 |
#include <opencv2/videostab/motion_core.hpp>
构造函数。
| size | 子集大小。 |
| thresh | 将点分类为内点的最大重投影误差值。 |
| eps | 错误对应关系的最大比例。 |
| prob | 所需的成功概率。 |
#include <opencv2/videostab/motion_stabilizing.hpp>
| Mat cv::videostab::estimateGlobalMotionLeastSquares | ( | 输入输出数组 | points0, |
| 输入输出数组 | points1, | ||
| 整数 | model = MM_AFFINE, | ||
| float * | rmse = 0 ) |
#include <opencv2/videostab/global_motion.hpp>
以最小二乘法估计两个二维点云之间的最佳全局运动。
| points0 | 2D 点的源集 (32F)。 |
| points1 | 2D 点的目标集 (32F)。 |
| model | 运动模型(最多 MM_AFFINE)。 |
| rmse | 最终均方根误差。 |
| Mat cv::videostab::estimateGlobalMotionRansac | ( | 输入数组 | points0, |
| 输入数组 | points1, | ||
| 整数 | model = MM_AFFINE, | ||
| const RansacParams & | params = RansacParams::default2dMotion(MM_AFFINE), | ||
| float * | rmse = 0, | ||
| int * | ninliers = 0 ) |
#include <opencv2/videostab/global_motion.hpp>
鲁棒地(使用RANSAC方法)估计两个二维点云之间的最佳全局运动。
| points0 | 2D 点的源集 (32F)。 |
| points1 | 2D 点的目标集 (32F)。 |
| model | 运动模型。参见 cv::videostab::MotionModel。 |
| params | RANSAC 方法参数。参见 videostab::RansacParams。 |
| rmse | 最终均方根误差。 |
| ninliers | 最终内点数。 |
#include <opencv2/videostab/motion_stabilizing.hpp>
#include <opencv2/videostab/global_motion.hpp>
假设所有中间运动已知,计算两帧之间的运动。
| 起始帧 | 源帧索引。 |
| 结束帧 | 目标帧索引。 |
| motions | 成对运动。motions[i] 表示从帧 i 到帧 i+1 的运动 |