Author Topic: remove surface mesh  (Read 217 times)

abaktor

  • Newbie
  • *
  • Posts: 1
remove surface mesh
« on: March 13, 2019, 04:19:37 PM »
Dear users,

I would like to use ovitos to perform DXA analysis without activating the surface mesh.
This is the Python script successfully used in the version 2.9:
Code: [Select]
pipeline = import_file("../moving-avg.*.cstm.gz")
modifier = DislocationAnalysisModifier()
modifier.input_crystal_structure = DislocationAnalysisModifier.Lattice.BCC
pipeline.modifiers.append(modifier)
pipeline.get_vis(SurfaceMeshVis).enabled=False
In the dev version 3.0 the latest line does not work:
Code: [Select]
pipeline.get_vis(SurfaceMeshVis).enabled=False
Could you let me know please how to disable SurfaceMeshVis in ver 3.0 dev?

Thank you in advance.

Alexander Stukowski

  • Administrator
  • Hero Member
  • *****
  • Posts: 638
Re: remove surface mesh
« Reply #1 on: March 14, 2019, 08:40:18 AM »
Hi,

The DislocationAnalysisModifier is currently not providing direct access to the visual element of the defect mesh. This is a mistake, which I am going to fix in the next development build of Ovito 3.0.

In the meantime, you can use the following workaround:
Code: [Select]
defect_mesh = pipeline.compute().surfaces['dxa-defect-mesh']
defect_mesh.vis.enabled = False

-Alex