Share via


KinectSensor.MapDepthFrameToColorFrame Method

Kinect for Windows 1.5, 1.6, 1.7, 1.8

Obsolete starting with version 1.6; replaced by the CoordinateMapper.MapDepthFrameToColorFrame method. In versions prior to 1.6, this method maps a depth frame to a color frame.

Syntax

public void MapDepthFrameToColorFrame (
         DepthImageFormat depthImageFormat,
         short[] depthPixelData,
         ColorImageFormat colorImageFormat,
         ColorImagePoint[] colorCoordinates
)
'Declaration
Public Sub MapDepthFrameToColorFrame ( _
         depthImageFormat As DepthImageFormat, _
         depthPixelData As Short(), _
         colorImageFormat As ColorImageFormat, _
         colorCoordinates As ColorImagePoint() _
)

Parameters

  • depthImageFormat
    Type: DepthImageFormat
    The depth format of the source.
  • depthPixelData
    Type: Int16
    The depth frame pixel data, as retrieved from the CopyPixelDataTo method. Must be equal in length to Width*Height of the depth format specified by depthImageFormat.
  • colorImageFormat
    Type: ColorImageFormat
    The desired target image format.
  • colorCoordinates
    Type: ColorImagePoint
    The ColorImagePoint array to receive the data. Each element will be the result of mapping the corresponding depthPixelData element to the specified ColorImageFormat coordinate space. Must be equal in length to depthPixelData.

Remarks

There is a known issue with calling this method when the sensor is stopped or disconnected.

Requirements

Namespace: Microsoft.Kinect

Assembly: Microsoft.Kinect (in microsoft.kinect.dll)

See Also

Reference

KinectSensor Class
KinectSensor Members
Microsoft.Kinect Namespace