Specify screenshot boundaries in ParaView

General discussion about Elmer
Post Reply
panosvar
Posts: 74
Joined: 29 Oct 2019, 16:02
Antispam: Yes

Specify screenshot boundaries in ParaView

Post by panosvar »

Hi,

I've created a simple pipeline where I create geometry and mesh in Salome, then use Elmer to simulate the pressure field, and finally visualize the field in ParaView. Then, I can take a screenshot of this field, however ParaView doesn't let you specify the exact boundaries of the area that the screenshot is taken. In fact, I only want the pressure field on the mesh and get rid of the rest. Check picture below (sorry for the .rar, file was too large).
Attachments
pressure_field.rar
(496.72 KiB) Downloaded 247 times
kevinarden
Posts: 2237
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: Specify screenshot boundaries in ParaView

Post by kevinarden »

Most system's OS have a screen capture tool included, W10 it is call "Snipping Tool" most Linux systems it is called "screenshot" either will let you select an area of the screen to save to a picture.
panosvar
Posts: 74
Joined: 29 Oct 2019, 16:02
Antispam: Yes

Re: Specify screenshot boundaries in ParaView

Post by panosvar »

I'm aware of that. However, I want this to be fully automated with python scripts, as I did with the other steps in my pipeline: geometry and mesh is created in SALOME with a py script, and in the same way the sif file is created and is executed with a py script that opens the terminal and calls for the elmer solver. Then I can call ParaView visualize and capture the desired field, all in Python. Unfortunately, as it seems ParaView doesn't provide an option to capture a specific part of the whole Layout window and the only thing I get is the picture I showed you above.
raback
Site Admin
Posts: 4812
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: Specify screenshot boundaries in ParaView

Post by raback »

Hi

How about resizing the visualization window such that it has the same aspect ratio as the object under study. Then there will be less empty space at least.

Not taking a screenshot has the advantage that in Paraview the resolution is not bound to the screen resolution.

Generally, this is perhaps better answered on Paraview (or VTK) forums.

-Peter
kevinarden
Posts: 2237
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: Specify screenshot boundaries in ParaView

Post by kevinarden »

screenshot is executable from the command line, which means it could be executed from python, however i don't know if the parameters can be set for the area of the screen to grab.
Post Reply