Share via


ColorReconstruction.SetAlignDepthFloatToReconstructionReferenceFrame Method

Kinect for Windows 1.8

Sets a reference depth frame that is used internally to help with tracking when calling the AlignDepthFloatToReconstruction method to calculate a new camera pose.

Note

You should call this method only if you are not using the default tracking behavior of Kinect Fusion.

Syntax

public void SetAlignDepthFloatToReconstructionReferenceFrame (
         FusionFloatImageFrame referenceDepthFloatFrame
)

Parameters

  • referenceDepthFloatFrame
    Type: FusionFloatImageFrame
    A previously-created depth float frame that was successfully aligned, or a raycasted model depth.

Exceptions

Exception type Condition
ArgumentException The referenceDepthFloatFrame parameter is an incorrect image size.
ArgumentNullException The referenceDepthFloatFrame parameter is null.
InvalidOperationException The call failed for an unknown reason.

Remarks

Internally, the AlignDepthFloatToReconstruction method saves the last depth frame that was passed to it and uses this image to help with tracking the next time that is called. For example, this can be used if you are reconstructing and lose track, and then want to restart tracking from a different known location without resetting the volume. To enable the tracking to succeed, you could perform a raycast from the new location to get a depth image (by calling the CalculatePointCloudAndDepth method), and then call SetAlignDepthFloatToReconstructionReferenceFrame with the depth image before calling AlignDepthFloatToReconstruction.

Requirements

Namespace: Microsoft.Kinect.Toolkit.Fusion

Assembly: Microsoft.Kinect.Toolkit.Fusion (in microsoft.kinect.toolkit.fusion.dll)

See Also

Reference

ColorReconstruction Class
ColorReconstruction Members
Microsoft.Kinect.Toolkit.Fusion Namespace