| Table of Contents / 3D Matching / Shape-Based | Operators |
project_shape_model_3d — Project the edges of a 3D shape model into image coordinates.
project_shape_model_3d( : ModelContours : ShapeModel3DID, CamParam, Pose, HiddenSurfaceRemoval, MinFaceAngle : )
The operator project_shape_model_3d projects the edges of the 3D object model that was used to create the 3D shape model ShapeModel3DID into the image coordinate system and returns the projected edges in ModelContours. The coordinates of the 3D object model are given in the 3D world coordinate system. First, they are transformed into the camera coordinate system using the given Pose. Then, these coordinates are projected into the image coordinate system based on the internal camera parameters CamParam.
The internal camera parameters CamParam describe the projection characteristics of the camera (see write_cam_par). The Pose describes the position and orientation of the world coordinate system with respect to the camera coordinate system.
The parameter HiddenSurfaceRemoval can be used to switch on or to switch off the removal of hidden surfaces. If HiddenSurfaceRemoval is set to 'true', only those projected edges are returned that are not hidden by faces of the 3D object model. If HiddenSurfaceRemoval is set to 'false', all projected edges are returned. This is faster than a projection with HiddenSurfaceRemoval set to 'true'.
3D edges are only projected if the angle between the two 3D faces that are incident with the 3D edge is at least MinFaceAngle. If MinFaceAngle is set to 0.0, all edges are projected. If MinFaceAngle is set to PI (equivalent to 180 degrees), only the silhouette of the 3D object model is returned. This parameter can be used to suppress edges within curved surfaces, e.g., the surface of a cylinder.
project_shape_model_3d and project_object_model_3d return the same result if the 3D object model that was used to create the 3D shape model is passed to project_object_model_3d.
project_shape_model_3d is especially useful in order to visualize the matches that are returned by find_shape_model_3d in the case that the underlying 3D object model is no longer available.
Contour representation of the model view.
Handle of the 3D shape model.
Internal camera parameters.
Number of elements: (CamParam == 8) || (CamParam == 12)
3D pose of the 3D shape model in the world coordinate system.
Remove hidden surfaces?
Default value: 'true'
List of values: 'true', 'false'
Smallest face angle for which the edge is displayed
Default value: 0.523599
Suggested values: 0.17, 0.26, 0.35, 0.52
If the parameters are valid, the operator project_shape_model_3d returns the value 2 (H_MSG_TRUE). If necessary an exception is raised.
create_shape_model_3d, read_shape_model_3d, get_shape_model_3d_params, find_shape_model_3d
convert_point_3d_cart_to_spher, convert_point_3d_spher_to_cart, create_cam_pose_look_at_point, trans_pose_shape_model_3d
3D Metrology
| Table of Contents / 3D Matching / Shape-Based | Operators |
| HALCON Reference Manual 10.0.2 | Copyright © 1996-2011 MVTec Software GmbH |