Table of contents

ImageManager

The ImageManager class is a utility class for managing and manipulating images. It provides functionality for saving images to files and drawing various shapes on images.

Definition

Module: dynamsoft_utility

class ImageManager

Methods

Method Description
__init__ Initializes a new instance of the ImageManager class.
save_to_file Saves an image to a file.

__init__

Initializes a new instance of the ImageManager class.

def __init__(self):

save_to_file

Saves an image to a file.

def save_to_file(self, image_data: ImageData, path: str, overwrite: bool = True) -> Tuple[int, str]:

Parameters

image_data The image data to be saved.

path The targeting file path with the file name and extension name.

overwrite A flag indicating whether to overwrite the file if it already exists. Defaults to true.

Return Value

Returns a tuple containing following elements:

  • error_code <int>: The error code indicating the status of the operation.
  • error_message <str>: A descriptive message explaining the error.

See Also

ImageData

This page is compatible for:

Is this page helpful?

YesYes NoNo

In this article: