-
Notifications
You must be signed in to change notification settings - Fork 23
Closed
Description
2 functions mention off_screen
argument to be easier for doing a screenshot:
- https://dpfdocs.pyansys.com/api/ansys.dpf.core.plotter.html?highlight=screenshot#ansys.dpf.core.plotter.Plotter.plot_chart
- https://dpfdocs.pyansys.com/api/ansys.dpf.core.meshed_region.html?highlight=screenshot#ansys.dpf.core.meshed_region.MeshedRegion.plot
But the question remains: how to perform a screenshot (i.e. save to a file) a given plot?
I tried using off_screen=True
and it does not seem to do anything.
With pymapdl
, you could do something like:
result = pymapdl_reader.read_binary("knight data/Kight_vv.rst")
result.plot_nodal_displacement(0, screenshot='knight.png')
But using the argument screenshot
does not seem to work in pydpf
: so how to do?
Ideally, it would be nice to have features like the function show
of pyvista
:
https://docs.pyvista.org/examples/02-plot/screenshot.html
... which also gives the possibility to do plotter.image
to be able to load the picture in matplotlib.
Metadata
Metadata
Assignees
Labels
No labels