save_picture#

class ansys.cfx.core.generated.post_processing.settings_261.save_picture.save_picture(name: str | None = None, parent=None)#

Bases: Command

Saves an image of the current view.

Parameters:
file_namestr

Name of the image file to save.

formatstr

The image format. Allowed values include:

  • ‘png’: Portable Network Graphics (PNG)

  • ‘avz’: Ansys Viewer Format

  • ‘jpg’: JPEG

  • ‘ppm’: Portable Pixel Map (PPM)

  • ‘ps’: PostScript

  • ‘eps’: Encapsulated PostScript.

use_white_backgroundbool

Save the image with a white background.

use_transparent_backgroundbool

Save the image with a transparent background (PNG images only). Needs GPU rendering to be available and enabled.

use_enhanced_outputbool

Process the image with antialiasing. Not available with GPU rendering.

use_screen_sizebool

When this is enabled, the saved image will have the same height and width (in pixels) as the current viewer size.

image_size_optionstr

Set the image size option. Only applicable if ‘Use Screen Size’ is disabled. Allowed values are ‘HD’, ‘FHD’, ‘QHD’, ‘4k’, ‘8k’ and ‘Custom’.

image_heightint

Set the image height in pixels. Only applicable if the image size option is set to ‘Custom’ and ‘Use Screen Size’ is disabled.

image_widthint

Set the image width in pixels. Only applicable if the image size option is set to ‘Custom’ and ‘Use Screen Size’ is disabled.

image_scaleint

Scale the size of bitmap images to a fraction (in percent) of the current viewer window size. Only applicable if ‘Use Screen Size’ is enabled.

image_qualityint

Specify the image quality (JPEG images only). A value of 100 specifies the highest quality; a value of 1 specifies the lowest quality.

tolerancereal

Increasing the tolerance should result in faster image generation, but may introduce defects in the output. The default is 1.0e-04, with a range from 0 to 1. Not available with GPU rendering.

Arguments

Argument

Summary

file_name

Name of the image file to save.

format

The image format. Allowed values include:

use_white_background

Save the image with a white background.

use_transparent_background

Save the image with a transparent background (PNG images

use_enhanced_output

Process the image with antialiasing. Not available with GPU

use_screen_size

When this is enabled, the saved image will have the same

image_size_option

Set the image size option. Only applicable if ‘Use Screen

image_height

Set the image height in pixels. Only applicable if the image

image_width

Set the image width in pixels. Only applicable if the image

image_scale

Scale the size of bitmap images to a fraction (in percent) of

image_quality

Specify the image quality (JPEG images only). A value of 100

tolerance

Increasing the tolerance should result in faster image

Included in:

Parent

Summary

file

File-related operations for a CFX post-processing session.

hardcopy

This object contains the settings used to control the creation of hardcopy output from the viewer. It is used by the “print” action.