Model.hm_getattachedsolidelemfaces#
- Model.hm_getattachedsolidelemfaces(collection, normal_flag)#
Returns information about solid elements attached to shell element faces.
For a given shell element, this function is used to get the connected solid element and the corresponding face index of the solid element.
- Parameters:
collection (Collection) – The collection containing the entities to query. Valid entities are elements and components.
normal_flag (int) –
0 - Get connected solid element face with normal in the same direction as input shell element normals
1 - Get connected solid element face with normal in the opposite direction as input shell element normals
- Returns:
hwReturnStatus- Status objectHmQueryResultList- Result list object containingHmQueryResultobjects with the following output data:
Example#
Get the attached solid element faces for all displayed elements , use opposite normals#import hm import hm.entities as ent model = hm.Model() element_collection = hm.CollectionByDisplayed(model, ent.Element) _, resultlist = model.hm_getattachedsolidelemfaces( collection=element_collection, normal_flag=1 ) for result in resultlist: print("Input Shell Element:", result.inputShell.id) print("Connected Solid Element:", result.connectedSolid.id) print("Solid Element Face Index:", result.solidElementFaceIndex)