MIL_ID SrcContainerOrImageBufId, | //in |
MIL_ID ProfileResult3dimId, | //in |
MIL_INT64 ProfileType, | //in |
MIL_INT64 Param1, | //in |
MIL_DOUBLE Param2, | //in |
MIL_DOUBLE Param3, | //in |
MIL_DOUBLE Param4, | //in |
MIL_DOUBLE Param5, | //in |
MIL_INT64 ControlFlag | //in |
This function takes the profile of a depth map or point cloud, along a specified slicing plane. The specified result buffer is filled with coordinates that make up the profile.
For a depth map profile, pixels are sampled along a specified line and corresponding points are extracted. The specified line effectively defines a slicing plane for the depth map, since the pixels' intensity values indicate depth (Z-values).
For a point cloud profile, 3D points are sampled and extracted along a specified slicing plane, which is divided into a grid of cells. For each cell, if points exist within the specified cutoff distance (perpendicular to the plane), the point closest to the plane is selected for the profile.
Note that the profile contains valid points only. No profile points are extracted from gaps in the depth map or invalid points in the point cloud.
You can retrieve results using M3dimGetResult(). To draw the profile, use MgraDots() or M3dgraDots().
Specifies the identifier of the source point cloud container or depth map image buffer.
The container must be 3D-processable (that is, if you call MbufInquireContainer() with M_3D_PROCESSABLE, the function returns M_PROCESSABLE). The container must have been previously allocated using MbufAllocContainer() with M_PROC.
The image buffer must be an 8-bit, 16-bit, or 32-bit unsigned, 1-band buffer, and must contain a fully corrected depth map (that is, if you call McalInquire() with M_DEPTH_MAP, the function returns M_TRUE). 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.
Specifies the identifier of the profile 3D image processing result buffer. The result buffer must have been allocated using M3dimAllocResult() with M_PROFILE_RESULT.
Specifies the type of profile to generate.
See the Parameter associations section for possible values that can be specified.
Specifies the first parameter. Depends on ProfileType.
See the Parameter associations section for possible values that can be specified.
Specifies the second parameter. Depends on ProfileType.
See the Parameter associations section for possible values that can be specified.
Specifies the third parameter. Depends on ProfileType.
See the Parameter associations section for possible values that can be specified.
Specifies the fourth parameter. Depends on ProfileType.
See the Parameter associations section for possible values that can be specified.
Specifies the fifth parameter. Depends on ProfileType.
See the Parameter associations section for possible values that can be specified.
The table below lists possible values for the ProfileType, Param1, Param2, Param3, Param4, and Param5 parameters.
Set unused parameters to M_DEFAULT.
For specifying the profile type
|
|||||||||||||||||||||||||||||||||||||||
ProfileType | Description | ||||||||||||||||||||||||||||||||||||||
Param1 | |||||||||||||||||||||||||||||||||||||||
Param2 | |||||||||||||||||||||||||||||||||||||||
Param3 | |||||||||||||||||||||||||||||||||||||||
Param4 | |||||||||||||||||||||||||||||||||||||||
Param5 | |||||||||||||||||||||||||||||||||||||||
M_PROFILE_DEPTH_MAP |
Specifies to take the profile of a depth map. Points are extracted along the specified line. If the line crosses a valid depth map pixel, the corresponding point is included in the profile. Note that invalid pixels (gaps) are ignored. The source object (SrcContainerOrImageBufId) must be a depth map image buffer. (summarize)Specifies to take the profile of a depth map. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param1 | |||||||||||||||||||||||||||||||||||||||
M_PIXEL |
Specifies to interpret the values in pixel units. |
||||||||||||||||||||||||||||||||||||||
M_WORLD |
Specifies to interpret the values in world units. |
||||||||||||||||||||||||||||||||||||||
Param2 |
Specifies the X-coordinate of the first point that defines the line. |
||||||||||||||||||||||||||||||||||||||
Param3 |
Specifies the Y-coordinate of the first point that defines the line. |
||||||||||||||||||||||||||||||||||||||
Param4 |
Specifies the X-coordinate of the second point that defines the line. |
||||||||||||||||||||||||||||||||||||||
Param5 |
Specifies the Y-coordinate of the second point that defines the line. |
||||||||||||||||||||||||||||||||||||||
M_PROFILE_POINT_CLOUD |
Specifies to take the profile of a point cloud. 3D points are extracted along the specified slicing plane, and within a specified distance from the plane. Invalid points in the point cloud are ignored. The source object (SrcContainerOrImageBufId) must be a container. (summarize)Specifies to take the profile of a point cloud. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param1 |
Specifies the identifier of a transformation matrix object that defines the slicing plane along which to sample points for the profile. The transformation matrix object must have been previously allocated using M3dgeoAlloc() with M_TRANSFORMATION_MATRIX. (summarize)Specifies the identifier of a transformation matrix object that defines the slicing plane along which to sample points for the profile. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param2 |
Specifies the sampling distance, in world units, along the specified slicing plane, in the X-direction of the plane coordinate system. Param2 and Param3 define a grid of cells along the slicing plane. For each cell, if points exist within the cutoff distance (Param4), the point closest to the slicing plane is selected for the profile. (summarize)Specifies the sampling distance, in world units, along the specified slicing plane, in the X-direction of the plane coordinate system. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param3 |
Specifies the sampling distance, in world units, along the specified slicing plane, in the Y-direction of the plane coordinate system. Param2 and Param3 define a grid of cells along the slicing plane. For each cell, if points exist within the cutoff distance (Param4), the point closest to the slicing plane is selected for the profile. (summarize)Specifies the sampling distance, in world units, along the specified slicing plane, in the Y-direction of the plane coordinate system. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param4 |
Specifies the cutoff distance (perpendicular to, and on either side of the specified slicing plane), in world units, beyond which points will not be considered for the profile. For example, if 5 is specified, only points within 5 units above and 5 units below the slicing plane are considered. (summarize)Specifies the cutoff distance (perpendicular to, and on either side of the specified slicing plane), in world units, beyond which points will not be considered for the profile. (more details...) |
||||||||||||||||||||||||||||||||||||||
Param5 |
Specifies a limit along the profile's X-dimension. (summarize)Specifies a limit along the profile's X-dimension. (more details...) |
||||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Specifies no limit along X. Note that, when M_DEFAULT is specified, an included point's X-coordinate can have any value, positive or negative. (summarize)Specifies no limit along X. (more details...) |
||||||||||||||||||||||||||||||||||||||
Value > 0 |
Specifies the length along the X-axis beyond which points are not included for the profile. This means that included points are those whose X-coordinate is between 0 and the specified Param5 value. (summarize)Specifies the length along the X-axis beyond which points are not included for the profile. (more details...) |
Header | Include mil.h. |
Library | Use mil.lib; mil3dim.lib. |
DLL | Requires mil.dll; mil3dim.dll. |