CaptureImage.fromFile Method¶
Module: CaptureImage
Definition¶
Creates an Image from the specified file.
@staticmethod
from_file(filepath: str, pixel_format: PixelFormat) -> CaptureImage
Parameters
filepath
strin A string that contains the name of the file from which to create the Image.pixel_format
PixelFormatin The pixel format into which to convert the input image.
Returns
The newly created capture image.
Exceptions
An error has occurred during Devices Library execution.
static CaptureImage fromFile(String? filepath, PixelFormat pixelFormat)
Parameters
filepath
Stringin A string that contains the name of the file from which to create the Image.pixelFormat
PixelFormatin The pixel format into which to convert the input image.
Returns
The newly created capture image.
Exceptions
An error has occurred during Devices Library execution.
public static CaptureImage FromFile(string filepath, PixelFormat pixelFormat)
Parameters
filepath
stringin A string that contains the name of the file from which to create the Image.pixelFormat
PixelFormatin The pixel format into which to convert the input image.
Returns
The newly created capture image.
Exceptions
An error has occurred during Devices Library execution.
public static CaptureImage fromFile(String filepath, PixelFormat pixelFormat) throws DevicesException
Parameters
filepath
Stringin A string that contains the name of the file from which to create the Image.pixelFormat
PixelFormatin The pixel format into which to convert the input image.
Returns
The newly created capture image.
Exceptions
An error has occurred during Devices Library execution.
int id3DevicesCaptureImage_FromFile (
ID3_DEVICES_CAPTURE_IMAGE hCaptureImage,
const char * filepath,
id3DevicesPixelFormat ePixelFormat)
Parameters
hCaptureImage
ID3_DEVICES_CAPTURE_IMAGEin Handle to the CaptureImage object.filepath
const char *in A string that contains the name of the file from which to create the Image.ePixelFormat
id3DevicesPixelFormatin The pixel format into which to convert the input image.
Returns