![]() |
ImFusion SDK 4.3
|
#include <RGBD/Include/ImFusion/RGBD/SurfaceReconstruction.h>
Abstract interface for surface reconstruction from RGB-D data. More...
Inheritance diagram for SurfaceReconstruction:Abstract interface for surface reconstruction from RGB-D data.
This class defines the interface for surface reconstruction algorithms. Implementations are responsible for integrating RGB-D frames into a 3D representation, tracking camera pose, and extracting a mesh representation of the reconstructed surface.
Usage:
init() with reconstruction parameters to initialize the algorithm.addFrame() to update the reconstruction representation.currentPose() and setCurrentPose() to manage camera pose.getMesh() to extract the reconstructed surface as a mesh.resetReconstruction() to clear the volume while keeping settings.cleanup() to release resources.stopReconstruction() to terminate all reconstruction threads. Public Member Functions | |
| virtual | ~SurfaceReconstruction () |
| Virtual destructor. | |
| virtual bool | init (SurfaceReconstructionData &data)=0 |
| Initializes the reconstruction algorithm with the given parameters. | |
| virtual void | cleanup ()=0 |
| Cleans up all reconstruction data and resources. | |
| virtual int | addFrame (const TypedImage< float > *imgDepth, const TypedImage< unsigned char > *imgColor, int sensor, const TypedImage< float > *imgDepthToColorMap=nullptr, mat4 *T=nullptr, bool poseHint=false, TypedImage< unsigned char > *imgScene=nullptr, bool updateVolume=true, mat4 *sensorT=nullptr, bool forceFirstFrame=false, bool ortho=false, int *icpMatches=nullptr, bool *isKeyframe=nullptr, double *timestamp=nullptr, const TypedImage< unsigned char > *mask=nullptr)=0 |
| Adds a frame to the reconstruction. | |
| virtual mat4f | currentPose () const =0 |
| Returns the current transformation from camera to world coordinate system. | |
| virtual void | setCurrentPose (const mat4f &T)=0 |
| Sets the current transformation from camera to world coordinate system. | |
| virtual void | resetReconstruction ()=0 |
| Resets the reconstruction volume. All other settings are left unchanged. | |
| virtual std::unique_ptr< Mesh > | getMesh () const =0 |
| Retrieves the reconstructed mesh. Ownership is transferred to the caller. | |
| virtual void | stopReconstruction ()=0 |
| Stops all reconstruction threads. The controller will wait until this function finishes execution when the stop button is triggered. | |
|
pure virtual |
Initializes the reconstruction algorithm with the given parameters.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Cleans up all reconstruction data and resources.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Adds a frame to the reconstruction.
| imgDepth | Depth map. | |
| imgColor | RGB color image. | |
| sensor | Sensor index. | |
| imgDepthToColorMap | Depth-to-color mapping. | |
| T | Pose hint. | |
| poseHint | True if pose hint is provided. | |
| [out] | imgScene | Rendered reconstruction volume from current viewpoint. |
| updateVolume | If true, volume is updated. | |
| sensorT | Sensor transformation. | |
| forceFirstFrame | If true, forces integration of first frame. | |
| ortho | If true, uses orthographic projection. | |
| [out] | icpMatches | Number of ICP matches. |
| [out] | isKeyframe | True if frame is a keyframe. |
| [out] | timestamp | Frame timestamp. |
| [out] | mask | mask image. |
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Returns the current transformation from camera to world coordinate system.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Sets the current transformation from camera to world coordinate system.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Resets the reconstruction volume. All other settings are left unchanged.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Retrieves the reconstructed mesh. Ownership is transferred to the caller.
Implemented in SurfaceReconstructionGPU.
|
pure virtual |
Stops all reconstruction threads. The controller will wait until this function finishes execution when the stop button is triggered.
Implemented in SurfaceReconstructionGPU.