| Customize Help
| Save Settings

M3dmapCopyResult



Function Map
Synopsis
Copy a group of results from a 3D reconstruction result buffer into a container or an image buffer.
Syntax
void M3dmapCopyResult(
MIL_ID SrcResult3dmapId, //in
MIL_INT SrcLabelOrIndex, //in
MIL_ID DstContainerOrImageBufId, //in
MIL_INT64 CopyType, //in
MIL_INT64 ControlFlag //in
)
Description

This function copies a group of results (for example, a point cloud) from a 3D reconstruction result buffer into a container or an image buffer.

Note that this function reference has not been updated for a MIL system added during a MIL update. Refer to the MIL system's release note to see which MIL system’s documentation you should use in its place and any possible differences.
Parameters
This function is not supported on the selected boards.
This function reference has not been updated for the selected MIL system. To show the content of this page, choose a second MIL system; refer to the MIL system's release note to see which MIL system’s documentation to choose and any possible differences.
Parameters
SrcResult3dmapId

Specifies the identifier of the 3D reconstruction result buffer containing point cloud or laser line data. The 3D reconstruction result buffer must have been previously allocated using M3dmapAllocResult() with M_DEPTH_CORRECTED_DATA, M_LASER_CALIBRATION_DATA, or M_POINT_CLOUD_RESULT.

See the Parameter associations section for possible values that can be specified.

SrcLabelOrIndex

Specifies the point cloud(s) in the specified 3D reconstruction result buffer to copy. Only 3D reconstruction result buffers allocated using M_POINT_CLOUD_RESULT have point clouds. For all other 3D reconstruction result buffer types, set this parameter to M_DEFAULT.

function map For specifying the point cloud(s)
Click to summarizeValue Description
Click to summarize

Specifies an existing point cloud with the given index.

(summarize)
Parameters

Specifies the index of an existing point cloud.

Click to summarize

Specifies an existing point cloud with the given label.

(summarize)
Parameters

Specifies the label of an existing point cloud.

Click to summarize M_ALL

Specifies all point clouds in the specified 3D reconstruction result buffer.

M_ALL is supported only when CopyType is set to M_POINT_CLOUD_UNORGANIZED.

Note that the destination container can hold only 1 point cloud. If M_ALL is specified, the point clouds are merged into one.

(summarize)
DstContainerOrImageBufId

Specifies the identifier of the destination container or image buffer in which to save the copied information.

See the Parameter associations section for possible values that can be specified.

CopyType

Specifies the type of copy operation to perform.

See the Parameter associations section for possible values that can be specified.

ControlFlag

Specifies whether to copy reflectance values, when the SrcResult3dmapId parameter is set to an M_POINT_CLOUD_RESULT result buffer. If the source is not an M_POINT_CLOUD_RESULT result buffer, set this parameter to M_DEFAULT.

function map For specifying the control flag
Click to summarizeValue Description
Click to summarize M_DEFAULT

Specifies to copy intensity values to the destination container's M_COMPONENT_REFLECTANCE component, which is created if not previously existing in the destination container. Note that, if no intensity values are available in the source point cloud, then no reflectance component is created.

(summarize)
Click to summarize M_NO_REFLECTANCE

Specifies not to copy intensity values.

The table below lists possible values for the SrcResult3dmapId, DstContainerOrImageBufId, and CopyType parameters.

function map For specifying the copy type and destination container or image buffer for a source 3D reconstruction result buffer
Click to summarizeSrcResult3dmapId Description
CopyType
DstContainerOrImageBufId
Click to summarize MIL 3D reconstruction depth corrected data
result buffer identifier

Specifies the identifier of a 3D reconstruction result buffer that stores results generated in M_DEPTH_CORRECTION mode.

(summarize)
Click to summarize M_INTENSITY_MAP

Copies the intensity map generated using acquired laser line data. In an intensity map, the gray value of each pixel represents the luminous intensity of the laser line at this point. The size of the intensity map corresponds to the size of the uncorrected depth map obtained with M_UNCORRECTED_DEPTH_MAP.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_INTENSITY_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth.

(summarize)
Click to summarize M_PARTIALLY_CORRECTED_DEPTH_MAP

Generates a partially corrected depth map. In a partially corrected depth map, the gray value of a pixel accurately represents real world depth, but any shape distortion (due to the camera's angle) is not corrected.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_PARTIALLY_CORRECTED_DEPTH_MAP_SIZE_X, M_PARTIALLY_CORRECTED_DEPTH_MAP_SIZE_Y, and M_PARTIALLY_CORRECTED_DEPTH_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth.

(summarize)
Click to summarize M_UNCORRECTED_DEPTH_MAP

Copies the uncorrected depth map generated using acquired laser line data. In uncorrected depth maps, the gray value of a pixel is not scaled to the real depth in the world, and any shape distortion (due to the camera's angle) is not corrected.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_UNCORRECTED_DEPTH_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth. Use M_UNCORRECTED_DEPTH_MAP_FIXED_POINT to obtain the fixed point used to encode the laser line Y position.

(summarize)
Click to summarize MIL 3D reconstruction laser calibration
result buffer identifier

Specifies the identifier of a 3D reconstruction result buffer that stores images of laser line displacement at specified heights during the 3D reconstruction calibration process.

(summarize)
Click to summarize M_INTENSITY_MAP

Copies the intensity map generated using acquired laser line data. In an intensity map, the gray value of each pixel represents the luminous intensity of the laser line at this point. The size of the intensity map corresponds to the size of the uncorrected depth map obtained with M_UNCORRECTED_DEPTH_MAP.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_INTENSITY_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth.

(summarize)
Click to summarize M_UNCORRECTED_DEPTH_MAP

Copies the uncorrected depth map generated using acquired laser line data. In uncorrected depth maps, the gray value of a pixel is not scaled to the real depth in the world, and any shape distortion (due to the camera's angle) is not corrected.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_UNCORRECTED_DEPTH_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth. Use M_UNCORRECTED_DEPTH_MAP_FIXED_POINT to obtain the fixed point used to encode the laser line Y position.

(summarize)
Click to summarize MIL 3D reconstruction point cloud result
buffer identifier

Specifies the identifier of a 3D reconstruction result buffer that stores results generated in M_CALIBRATED_CAMERA_LINEAR_MOTION mode.

(summarize)
Click to summarize M_INTENSITY_MAP

Copies the intensity map generated using acquired laser line data. In an intensity map, the gray value of each pixel represents the luminous intensity of the laser line at this point. The size of the intensity map corresponds to the size of the uncorrected depth map obtained with M_UNCORRECTED_DEPTH_MAP.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_INTENSITY_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth.

(summarize)
Click to summarize M_POINT_CLOUD +

Copies all points, preserving the point cloud's organizational type.

All copied point coordinate values are respective to the relative coordinate system, unless the M_ABSOLUTE_COORDINATE_SYSTEM combination value is specified.

(summarize)
Click to summarize MIL container identifier

Specifies the destination container identifier.

The destination container must have been previously allocated using MbufAllocContainer() with M_PROC. If a range component and a confidence component already exist in the container, they will be overwritten. If the container is empty, range and confidence components are created to hold the copied information.

(summarize)
Click to summarize M_POINT_CLOUD_UNORGANIZED +

Copies only valid points, excluding points in the specified M_POINT_CLOUD_RESULT result buffer that are set to M_INVALID_POINT. The point cloud's organizational type is not preserved.

Note that, when you use M_ALL to specify all point clouds in the M_POINT_CLOUD_RESULT result buffer, the point clouds are merged into a single point cloud, and then placed into the destination container.

All copied point coordinate values are respective to the relative coordinate system, unless the M_ABSOLUTE_COORDINATE_SYSTEM combination value is specified.

(summarize)
Click to summarize MIL container identifier

Specifies the destination container identifier.

The destination container must have been previously allocated using MbufAllocContainer() with M_PROC. If a range component and a confidence component already exist in the container, they will be overwritten. If the container is empty, range and confidence components are created to hold the copied information.

(summarize)
Click to summarize M_UNCORRECTED_DEPTH_MAP

Copies the uncorrected depth map generated using acquired laser line data. In uncorrected depth maps, the gray value of a pixel is not scaled to the real depth in the world, and any shape distortion (due to the camera's angle) is not corrected.

(summarize)
Click to summarize MIL image buffer identifier

Specifies the destination image buffer identifier.

The destination image buffer must be a 1-band, 8-bit or 16-bit unsigned buffer. This image buffer must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.

The X-size of the destination image buffer should be at least either the X-size or Y-size of the laser line images used to generate the data, depending on whether MimControl() with M_SCAN_LANE_DIRECTION is set to M_VERTICAL or M_HORIZONTAL, respectively. The Y-size of the destination image buffer must be at least as large as the number of scanned laser lines to accumulate in the buffer; this number's maximum possible value is set using M3dmapControl() with M_MAX_FRAMES. Note that the number of scanned laser lines actually accumulated can be lower than this maximum.

Use M3dmapGetResult() with M_UNCORRECTED_DEPTH_MAP_SIZE_X, M_UNCORRECTED_DEPTH_MAP_SIZE_Y, and M_UNCORRECTED_DEPTH_MAP_BUFFER_TYPE to obtain the necessary buffer dimensions, data type, and depth. Use M_UNCORRECTED_DEPTH_MAP_FIXED_POINT to obtain the fixed point used to encode the laser line Y position.

(summarize)
Combination value for M_POINT_CLOUD (when SrcResult3dmapId=MIL 3D reconstruction point cloud result buffer identifier); M_POINT_CLOUD_UNORGANIZED (when SrcResult3dmapId=MIL 3D reconstruction point cloud result buffer identifier).

You can add the following value to the above-mentioned values to specify to copy points with respect to the absolute coordinate system.

function map For copying points with respect to the absolute coordinate system
Click to summarizeCombination value Description
Click to summarize M_ABSOLUTE_COORDINATE_SYSTEM

Specifies to copy points with respect to the absolute coordinate system.

Compilation information
Header Include mil.h.
Library Use mil.lib; mil3dmap.lib.
DLL Requires mil.dll; mil3dmap.dll.
ALL UNSIGNED NONE PROC DEFAULT NO REFLECTANCE INTENSITY MAP PARTIALLY CORRECTED DEPTH MAP UNCORRECTED DEPTH MAP INTENSITY MAP UNCORRECTED DEPTH MAP INTENSITY MAP POINT CLOUD POINT CLOUD UNORGANIZED UNCORRECTED DEPTH MAP ABSOLUTE COORDINATE SYSTEM POINT CLOUD UNORGANIZED