|
libfreenect2 0.4
Open source driver for the Kinect for Windows v2 (K4W2) sensor
|
Opt-in linear correction for decoded depth measurements in millimeters. More...
#include <libfreenect2/depth_calibration.h>
Public Types | |
| enum | Model { OffsetOnly , Linear } |
Public Member Functions | |
| DepthCorrectionProfile () | |
| bool | isValid () const |
| A profile is usable only when its coefficients are finite and scale is positive. | |
| float | correct (float measured_mm) const |
| Return scale * measured_mm + offset_mm, preserving invalid measurements. | |
| bool | apply (Frame &depth) const |
| Apply this profile to a decoded float depth frame. | |
| bool | save (const std::string &path, std::string *error=0) const |
| Atomically save a versioned JSON profile. | |
Static Public Member Functions | |
| static bool | load (const std::string &path, DepthCorrectionProfile &profile, std::string *error=0) |
| Load and validate a versioned JSON profile. | |
Public Attributes | |
| uint32_t | version |
| std::string | serial |
| std::string | firmware |
| Model | model |
| double | scale |
| double | offset_mm |
| double | rmse_mm |
| DepthCalibrationRoi | roi |
| std::vector< DepthCalibrationSample > | samples |
| std::vector< double > | residuals_mm |
Opt-in linear correction for decoded depth measurements in millimeters.
| enum Model |
| DepthCorrectionProfile | ( | ) |
Referenced by load().
| bool isValid | ( | ) | const |
A profile is usable only when its coefficients are finite and scale is positive.
| float correct | ( | float | measured_mm | ) | const |
| bool apply | ( | Frame & | depth | ) | const |
Apply this profile to a decoded float depth frame.
Invalid pixels are unchanged.
| bool save | ( | const std::string & | path, |
| std::string * | error = 0 ) const |
Atomically save a versioned JSON profile.
|
static |
Load and validate a versioned JSON profile.
References DepthCorrectionProfile().
| uint32_t version |
| std::string serial |
| std::string firmware |
| Model model |
| double scale |
| double offset_mm |
| double rmse_mm |
| std::vector<DepthCalibrationSample> samples |
| std::vector<double> residuals_mm |