hm_proximityinitwithtarget
Checks the proximity between elements or components, allowing the user to specify the target, and stores the results internally.
Syntax
hm_proximityinitwithtarget source_entity_type source_mark_id target_entity_type target_mark_id max_proximity_distance ?check_side? ?proximity_scheme? ?proximity_by_edge? ?min_angle_limit? ?max_angle_limit?
Type
HyperMesh Tcl Query Command
Description
Checks the proximity between elements or components, allowing the user to specify the target, and stores the results internally. Other APIs can be used to query the results.
This must precede any calls to other hm_proximityget*/hm_proximitymark* APIs, and must be followed by a call to hm_proximityend.
Inputs
- source_entity_type
- The type of source entity to query. Valid values are elements and components.
- source_mark_id
- The ID of the mark containing the source input entities. Valid values are 1 and 2.
- target_entity_type
- The type of target entity to query. Valid values are elements and components.
- target_mark_id
- The ID of the mark containing the target input entities. Valid values are 1 and 2.
- max_proximity_distance
- The maximum distance beyond which proximity is not reported.
- check_side
- 1 - Check both sides of the elements
- proximity_scheme
- 0 - Checks basic proximity along a ray from the element center along the normal direction.
- proximity_by_edge
- 0 - Ignores proximity for nearby edges (default behavior if not specified).
- min_angle_limit
- If the angle between the proximate element pairs is less than this value, such pairs are not reported.
- max_angle_limit
- If the angle between the proximate element pairs is greater than this value, such pairs are not reported.
Examples
*createmark comps 1 "source"
*createmark comps 2 "target"
hm_proximityinitwithtarget comps 1 comps 2 2.5
hm_proximitymarksourceproximityelements 1
hm_proximitymarktargetproximityelements 2
hm_highlightmark elems 1 h
hm_highlightmark elems 2 l
hm_proximityend
Errors
if { [ catch {command_name...} ] } {
# Handle error
}
Version History
2019
2019.1 - Added new optional arguments min_angle_limit and max_angle_limit.