RecFusion SDK
 All Classes Functions Variables Enumerations Enumerator
RecFusion SDK Documentation

Introduction

The RecFusion SDK allows to perform GPU-based real-time 3D reconstruction from RGB-D data. Classes for accessing OpenNI2-based sensors are provided as well as classes for recording and loading RGB-D data from disk. The resulting meshes can be post-processed and exported to standard mesh formats. Both single-sensor and multi-sensor reconstruction are supported.

The SDK is made up of the following main classes:

  • Sensor for accessing OpenNI2-based RGB-D sensors
  • RFSPlayback for reading RFS-sequences including those created by the standalone RecFusion application
  • RFSRecorder for writing RFS-sequences. These sequences can also be loaded by the standalone RecFusion application
  • Reconstruction for performing the reconstruction and generating the mesh
  • Mesh for exporting and post-processing the mesh
  • MeshViewer for displaying the mesh on screen
  • Calibration for calibrating multi-sensor setups
  • RecFusionSDK for license management and global settings

In your application you will typically first generate a Sensor object by instantiating the Sensor class and calling open on it. You can acquire the next available frame by calling readImage. The obtained frame data is then passed to the addFrame method of a Reconstruction object which you instantiate with a ReconstructionParams structure. The addFrame method will optionally provide an image of the current reconstruction result rendered from the current camera viewpoint. You can use this image to visualize the state of the reconstruction. Once you've added the desired number of frames you can obtain the mesh by calling getMesh on the Reconstruction object. The returned Mesh object allows you to export and post-process the mesh. When done you have to delete the Mesh object and call close on the Sensor object.

Installation

During installation the environment variable RECFUSION_SDK is set to point to the RecFusion SDK root folder. You can use this variable to easily reference the SDK in your projects. To use the RecFusion SDK in your application, add "$(RECFUSION_SDK)\include" the include path and "$(RECFUSION_SDK)\lib" to the lib path of the project settings and include RecFusion.lib in the linker settings. You also need to install OpenNI2 (http://www.recfusion.net/downloads/openni/OpenNI-Windows-x64-2.2.msi) and if using the Microsoft Kinect also the Kinect SDK (http://go.microsoft.com/fwlink/?LinkID=323588). At runtime the applications need to be able to access the OpenNI2 runtime. You therefore have to copy the contents of the Redist folder from your OpenNI2 installation to the same directory where your executable is residing. Alternatively you can specify the OpenNI path in the debug settings during development. See the supplied sample programs for an example of how to accomplish this.

Licensing

In order to export the generated mesh you will need to obtain a RecFusion license. Licenses can be bought from http://www.recfusion.net and are node-locked to a single PC. After purchasing a license you will have to generate a license request file using the LicenseTool.exe found in the bin folder. Please run this tool from a folder in which you have write-permission since it will generate a file in the current working directory. Send the generated LicReq.dat to licen.nosp@m.se@r.nosp@m.ecfus.nosp@m.ion..nosp@m.net in order to obtain your license file.

Sample programs

There are two sample applications included with the SDK. They are located in the samples folder in the RecFusion installation directory. The ConsoleReconstruction sample is a basic console application which captures a fixed number of frames, reconstructs the scene and saves the result. The QtReconstruction sample is a graphical application using the Qt 5 framework (http://www.qt.io). It displays the captured images and the live reconstruction result. To start the reconstruction in the QtReconstruction application press F5, to stop press F6. To build the application you need to define the environment variable QTDIR to point to your Qt 5 directory. The 'MultiViewReconstruction' sample shows how to calibrate and reconstruct using multiple sensors.

Support

If you need support for the RecFusion SDK please send a mail to feedb.nosp@m.ack@.nosp@m.recfu.nosp@m.sion.nosp@m..net.