Skip to content

Commit

Permalink
FEM: Update resulttools.py
Browse files Browse the repository at this point in the history
  • Loading branch information
FEA-eng authored Dec 6, 2024
1 parent 870e260 commit bbc00e6
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/Mod/Fem/femresult/resulttools.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def purge_results(analysis):
analysis group as a container for all objects needed for the analysis
"""

# if analysis typ check is used result mesh
# if analysis type check is used, result mesh
# without result obj is created in the analysis
# we could run into trouble in one loop because
# we will delete objects and try to access them later
Expand All @@ -68,6 +68,15 @@ def purge_results(analysis):
analysis.Document.removeObject(m.Name)
analysis.Document.recompute()

# result pipeline and filter
for m in analysis.Group:
if is_of_type(m, "Fem::FemPostPipeline"):
# delete associated filters
for filter_obj in m.Filter:
analysis.Document.removeObject(filter_obj.Name)
# delete the pipeline itself
analysis.Document.removeObject(m.Name)
analysis.Document.recompute()

def reset_mesh_deformation(resultobj):
"""Resets result mesh deformation.
Expand Down

0 comments on commit bbc00e6

Please sign in to comment.