![]() |
OpenCV
4.5.0
Open Source Computer Vision
|
DynamicFusion implementation. More...
#include <opencv2/rgbd/dynafu.hpp>
Public Member Functions | |
| virtual | ~DynaFu () |
| virtual void | getCloud (OutputArray points, OutputArray normals) const =0 |
| Gets points and normals of current 3d mesh. More... | |
| virtual std::vector< Point3f > | getNodesPos () const =0 |
| virtual void | getNormals (InputArray points, OutputArray normals) const =0 |
| Calculates normals for given points. More... | |
| virtual const Params & | getParams () const =0 |
| Get current parameters. More... | |
| virtual void | getPoints (OutputArray points) const =0 |
| Gets points of current 3d mesh. More... | |
| virtual const Affine3f | getPose () const =0 |
| Get current pose in voxel space. More... | |
| virtual void | marchCubes (OutputArray vertices, OutputArray edges) const =0 |
| virtual void | render (OutputArray image, const Matx44f &cameraPose=Matx44f::eye()) const =0 |
| Renders a volume into an image. More... | |
| virtual void | renderSurface (OutputArray depthImage, OutputArray vertImage, OutputArray normImage, bool warp=true)=0 |
| virtual void | reset ()=0 |
| Resets the algorithm. More... | |
| virtual bool | update (InputArray depth)=0 |
| Process next depth frame. More... | |
Static Public Member Functions | |
| static Ptr< DynaFu > | create (const Ptr< Params > &_params) |
DynamicFusion implementation.
This class implements a 3d reconstruction algorithm as described in [dynamicfusion].
It takes a sequence of depth images taken from depth sensor (or any depth images source such as stereo camera matching algorithm or even raymarching renderer). The output can be obtained as a vector of points and their normals or can be Phong-rendered from given camera pose.
It extends the KinectFusion algorithm to handle non-rigidly deforming scenes by maintaining a sparse set of nodes covering the geometry such that each node contains a warp to transform it from a canonical space to the live frame.
An internal representation of a model is a voxel cuboid that keeps TSDF values which are a sort of distances to the surface (for details read the [kinectfusion] article about TSDF). There is no interface to that representation yet.
Note that DynamicFusion is based on the KinectFusion algorithm which is patented and its use may be restricted by the list of patents mentioned in README.md file in this module directory.
That's why you need to set the OPENCV_ENABLE_NONFREE option in CMake to use DynamicFusion.
|
virtual |
|
pure virtual |
Gets points and normals of current 3d mesh.
The order of normals corresponds to order of points. The order of points is undefined.
| points | vector of points which are 4-float vectors |
| normals | vector of normals which are 4-float vectors |
|
pure virtual |
|
pure virtual |
Calculates normals for given points.
| points | input vector of points which are 4-float vectors |
| normals | output vector of corresponding normals which are 4-float vectors |
|
pure virtual |
Get current parameters.
|
pure virtual |
Gets points of current 3d mesh.
The order of points is undefined.
| points | vector of points which are 4-float vectors |
|
pure virtual |
Get current pose in voxel space.
|
pure virtual |
|
pure virtual |
|
pure virtual |
|
pure virtual |
Resets the algorithm.
Clears current model and resets a pose.
|
pure virtual |
Process next depth frame.
Integrates depth into voxel space with respect to its ICP-calculated pose. Input image is converted to CV_32F internally if has another type.
| depth | one-channel image which size and depth scale is described in algorithm's parameters |
1.8.9.1