Class SaveImageOptions

Options for saving image to a path.

Constructors

Properties

Constructors

Properties

optimize: boolean = false

If true, the encoder will spend extra time when saving JPEG files to improve the compression rate. Enabling this option has no impact on quality.

Default is false

quality: number = -1

Quality parameter is for JPEG only and is in range 0 to 100. If -1, then the value from hibernation is used. In case the ImageRef was created in lazy load-mode and originally has the same format as the requested to save, then setting quality to -1 leads to simply copying from source to destination, which is time efficient and prevents quality loss caused by decoding the JPEG and then re-encoding it.

Default is -1