Filters
Filter values by
3D image processing result type
  • Profile result
  • Statistics result
    • Common to all
    • Bounding box statistics result
    • Centroid statistics result
    • Distance-to-nearest-neighbor statistics result
    • Number-of-points statistics result
| Customize Help
| Save Settings

M3dimGetResult



Function Map
Synopsis
Get the specified type of result from a 3D image processing result buffer.
Syntax
MIL_DOUBLE M3dimGetResult(
MIL_ID Result3dimId, //in
MIL_INT64 ResultType, //in
void *ResultArrayPtr //out
)
Description

This function retrieves the result(s) of the specified type from a result 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
Result3dimId

Specifies the identifier of the 3D image processing result buffer from which to retrieve results. The result buffer must have been previously allocated on the system using M3dimAllocResult() with M_PROFILE_RESULT or M_STATISTICS_RESULT.

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

ResultType

Specifies the type of result to retrieve.

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

ResultArrayPtr
Accepts the address of one of the following (see the Parameter associations section for specifics on which is expected):
  • array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ]
  • array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ]
  • array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]
  • array of type MIL_INT32 [optionally, in C++: a reference to a std::vector<MIL_INT32> ]
  • array of type MIL_INT64 [optionally, in C++: a reference to a std::vector<MIL_INT64> ]
  • MIL_DOUBLE
  • MIL_FLOAT
  • MIL_INT
  • MIL_INT32
  • MIL_INT64

Specifies the address of the array in which to write the requested information.

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

The table below lists possible values for the Result3dimId and ResultType parameters and possible values returned to the ResultArrayPtr parameter.

The following Result3dimId, ResultType, and ResultArrayPtr parameter settings can be specified for different types of 3D image processing result buffers.

function map For specifying the type of result to retrieve from a profile or statistics 3D image processing result buffer
Click to summarize
Result3dimId
Description
ResultType
ResultArrayPtr
- Possible values returned
Click to summarize Profile 3D image processing result ID

Specifies the identifier of a profile 3D image processing result buffer.

For a M_PROFILE_RESULT result buffer, results are available after using M3dimProfile() to fill the result buffer with a point cloud profile or depth map profile.

Note that you can transform coordinates from M_PROFILE_PLANE_... to M_WORLD_... (and vice versa). To do so, copy profile results into a transformation matrix, using M3dimCopyResult() with M_MATRIX_PROFILE_PLANE_TO_WORLD or M_MATRIX_WORLD_TO_PROFILE_PLANE, and then pass the resulting transformation matrix to M3dimMatrixTransformList().

For depth maps, transforming M_WORLD_... point coordinate values using McalTransformCoordinate3dList() will yield values close to those obtained with M_PROFILE_PLANE_..., but exactly on the profile line.

(summarize)
Click to summarize M_NUMBER_OF_POINTS_MISSING_DATA +

Retrieves the number of missing data points (gap pixels) encountered when creating the depth map profile; for a point cloud profile, this result type always returns 0.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_NUMBER_OF_POINTS_VALID +

Retrieves the number of valid points along the depth map or point cloud profile. Note that all extracted profile points are valid; therefore, this number equals the total number of points in the profile.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_PIXEL_X +

Retrieves the pixel X-coordinates for valid points included in the profile.

Each 3D point has a corresponding pixel in the depth map image buffer or point cloud range component. M_PIXEL_X returns an integer value, for each profile point, which corresponds to the pixel's position along X in the depth map or range component.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Click to summarize M_PIXEL_Y +

Retrieves the pixel Y-coordinates for valid points included in the profile.

Each 3D point has a corresponding pixel in the depth map image buffer or point cloud range component. M_PIXEL_Y returns an integer value, for each profile point, which corresponds to the pixel's position along Y in the depth map or range component.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Click to summarize M_PROFILE_PLANE_X +

Retrieves the X-coordinates from the resulting profile, expressed in the coordinate system of the slicing plane itself, in world units.

For a depth map profile, points are extracted from pixels along the specified line. M_PROFILE_PLANE_X returns the real world distance along that line, for each extracted point. Note that the line's start point (set using M3dimProfile() with M_PROFILE_DEPTH_MAP and Param2 and Param3) represents a distance of 0. The line is effectively the X-axis for a plot of M_PROFILE_PLANE_X and M_PROFILE_PLANE_Y values, which sit on the slicing plane.

For a point cloud profile, the returned values correspond to the X-coordinates of the profile's points, expressed in the specified slicing plane's coordinate system.

You can draw the M_PROFILE_PLANE_X and M_PROFILE_PLANE_Y values in a 2D display using MgraDots().

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize M_PROFILE_PLANE_Y +

Retrieves the Y-coordinates from the resulting profile, expressed in the coordinate system of the slicing plane itself, in world units.

For a depth map profile, the returned values correspond to the depth at each pixel underneath the specified line.

For a point cloud profile, the returned values correspond to the Y-coordinates of the profile's points, expressed in the specified slicing plane's coordinate system.

You can draw the M_PROFILE_PLANE_X and M_PROFILE_PLANE_Y values in a 2D display using MgraDots().

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize M_PROFILE_TYPE +

Retrieves the profile type.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_NOT_INITIALIZED

Specifies that a profile type has not been defined for the profile result.

Click to summarize M_PROFILE_DEPTH_MAP

Specifies a depth map profile.

Click to summarize M_PROFILE_POINT_CLOUD

Specifies a point cloud profile.

Click to summarize M_WORLD_X +

Retrieves the world X-coordinates for the extracted points.

For a depth map, the returned values correspond to each extracted point's pixel position along X, in world units.

For a point cloud, the returned values correspond to each extracted point's position in the point cloud along X, in world units.

You can draw the M_WORLD_X, M_WORLD_Y, and M_WORLD_Z values in a 3D display using M3dgraDots().

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize M_WORLD_Y +

Retrieves the world Y-coordinates for the extracted points.

For a depth map, the returned values correspond to each extracted point's pixel position along Y, in world units.

For a point cloud, the returned values correspond to each extracted point's position in the point cloud along Y, in world units.

You can draw the M_WORLD_X, M_WORLD_Y, and M_WORLD_Z values in a 3D display using M3dgraDots().

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize M_WORLD_Z +

Retrieves the world Z-coordinates for the extracted points.

For a depth map, the returned values correspond to each extracted point's depth value (distance along Z), in world units.

For a point cloud, the returned values correspond to each extracted point's position in the point cloud along Z, in world units.

You can draw the M_WORLD_X, M_WORLD_Y, and M_WORLD_Z values in a 3D display using M3dgraDots().

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize Statistics 3D image processing result ID

Specifies the identifier of a statistics 3D image processing result buffer.

For a M_STATISTICS_RESULT result buffer, results are available after using M3dimStat() to fill the result buffer with statistics on a container's point cloud or on a depth map.

(summarize)
Click to summarize M_AVG_DISTANCE_TO_NEAREST_NEIGHBOR +

Retrieves the average distance to the nearest neighbor.

This result type is available for distance-to-nearest-neighbor statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_BOX_CENTER_X +

Retrieves the X-coordinate of the center of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_BOX_CENTER_Y +

Retrieves the Y-coordinate of the center of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_BOX_CENTER_Z +

Retrieves the Z-coordinate of the center of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_CENTROID_X +

Retrieves the X-coordinate of the centroid.

This result type is available for centroid statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_CENTROID_Y +

Retrieves the Y-coordinate of the centroid.

This result type is available for centroid statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_CENTROID_Z +

Retrieves the Z-coordinate of the centroid.

This result type is available for centroid statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MAX_DISTANCE_TO_NEAREST_NEIGHBOR +

Retrieves the maximum distance to the nearest neighbor.

This result type is available for distance-to-nearest-neighbor statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MAX_X +

Retrieves the maximum X-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MAX_Y +

Retrieves the maximum Y-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MAX_Z +

Retrieves the maximum Z-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MIN_DISTANCE_TO_NEAREST_NEIGHBOR +

Retrieves the minimum distance to the nearest neighbor.

This result type is available for distance-to-nearest-neighbor statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MIN_X +

Retrieves the minimum X-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MIN_Y +

Retrieves the minimum Y-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_MIN_Z +

Retrieves the minimum Z-coordinate of the bounding box.

This result type is available for bounding box statistics results. The bounding box is an axis-aligned box that contains either all points or most of the points in the 3D scene (see M3dimControl() with M_BOUNDING_BOX_ALGORITHM).

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_NUMBER_OF_POINTS_MISSING_DATA +

Retrieves the number of points that are missing data.

This result type is available for number-of-points statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_NUMBER_OF_POINTS_TOTAL +

Retrieves the total number of points.

This result type is available for number-of-points statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_NUMBER_OF_POINTS_VALID +

Retrieves the number of valid points.

This result type is available for number-of-points statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_SIZE_X +

Retrieves the length along X of the 3D scene, in world units.

This result type is available for bounding box statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_SIZE_Y +

Retrieves the length along Y of the 3D scene, in world units.

This result type is available for bounding box statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Click to summarize M_SIZE_Z +

Retrieves the length along Z of the 3D scene, in world units.

This result type is available for bounding box statistics results.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE
Combination value for the values of the ResultType parameter listed in For specifying the type of result to retrieve from a profile or statistics 3D image processing result buffer.

You can add the following value to the above-mentioned values to determine whether a result is available.

function map For determining whether results are available
Click to summarizeResultType Description
ResultArrayPtr
- Possible values returned
Click to summarize M_AVAILABLE

Retrieves whether a result is available to be returned.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_NULL

Specifies that the result is not available to be retrieved.

Click to summarize Value != 0

Specifies that the result is available to be retrieved.

Combination values for the values of the ResultType parameter listed in For specifying the type of result to retrieve from a profile or statistics 3D image processing result buffer.

You can add one of the following values to the above-mentioned values to cast the requested information to the required data type.

Note: In C++, when using a standard vector (std::vector) instead of an array, the values listed in this combination table must not be used. If you need to use a specific data type, instantiate the vector with the necessary data type.

function map For specifying the data type
Click to summarizeResultType Description
ResultArrayPtr
- Possible values returned
Click to summarize M_TYPE_MIL_DOUBLE

Casts the requested information to a MIL_DOUBLE.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_DOUBLE  |  array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ] MORE
Click to summarize M_TYPE_MIL_FLOAT

Casts the requested information to a MIL_FLOAT.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_FLOAT  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize M_TYPE_MIL_INT

Casts the requested information to a MIL_INT.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT  |  array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Click to summarize M_TYPE_MIL_INT32

Casts the requested information to a MIL_INT32.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT32  |  array of type MIL_INT32 [optionally, in C++: a reference to a std::vector<MIL_INT32> ] MORE
Click to summarize M_TYPE_MIL_INT64

Casts the requested information to a MIL_INT64.

(summarize)
Expand data type infoCollapse data type info ResultArrayPtr extra info
Data type info: Data type: address of a MIL_INT64  |  array of type MIL_INT64 [optionally, in C++: a reference to a std::vector<MIL_INT64> ] MORE
Return value
The returned value is the requested information, cast to a MIL_DOUBLE. If the requested information does not fit into a MIL_DOUBLE, this function will return M_NULL or truncate the information.
Compilation information
Header Include mil.h.
Library Use mil.lib; mil3dim.lib.
DLL Requires mil.dll; mil3dim.dll.
NUMBER OF POINTS MISSING DATA NUMBER OF POINTS VALID PIXEL X PIXEL Y PROFILE PLANE X PROFILE PLANE Y PROFILE TYPE NOT INITIALIZED PROFILE DEPTH MAP PROFILE POINT CLOUD WORLD X WORLD Y WORLD Z AVG DISTANCE TO NEAREST NEIGHBOR BOX CENTER X BOX CENTER Y BOX CENTER Z CENTROID X CENTROID Y CENTROID Z MAX DISTANCE TO NEAREST NEIGHBOR MAX X MAX Y MAX Z MIN DISTANCE TO NEAREST NEIGHBOR MIN X MIN Y MIN Z NUMBER OF POINTS MISSING DATA NUMBER OF POINTS TOTAL NUMBER OF POINTS VALID SIZE X SIZE Y SIZE Z AVAILABLE NULL TYPE MIL DOUBLE TYPE MIL FLOAT TYPE MIL INT TYPE MIL INT32 TYPE MIL INT64 ENABLE ENABLE ENABLE ENABLE