Image.fromBuffer Method¶
Module: Image
Definition¶
Creates an Image from the specified data buffer.
@staticmethod
from_buffer(data: bytearray, pixel_format: PixelFormat) -> Image
Parameters
databytearrayin A buffer that contains the image data.pixel_formatPixelFormatin The destination pixel format to convert the input to.
Returns
The newly created image.
Exceptions
An error has occurred during Face Library execution.
static Image fromBuffer(Uint8List? data, PixelFormat pixelFormat)
Parameters
dataUint8Listin A buffer that contains the image data.pixelFormatPixelFormatin The destination pixel format to convert the input to.
Returns
The newly created image.
Exceptions
An error has occurred during Face Library execution.
public static Image FromBuffer(byte[] data, PixelFormat pixelFormat)
Parameters
databyte[]in A buffer that contains the image data.pixelFormatPixelFormatin The destination pixel format to convert the input to.
Returns
The newly created image.
Exceptions
An error has occurred during Face Library execution.
public static Image fromBuffer(byte[] data, PixelFormat pixelFormat) throws FaceException
Parameters
databyte[]in A buffer that contains the image data.pixelFormatPixelFormatin The destination pixel format to convert the input to.
Returns
The newly created image.
Exceptions
An error has occurred during Face Library execution.
public static func fromBuffer(data: [UInt8], pixelFormat: PixelFormat) throws -> Image
Parameters
data[UInt8]in A buffer that contains the image data.pixelFormatPixelFormatin The destination pixel format to convert the input to.
Returns
The newly created image.
Exceptions
An error has occurred during Face Library execution.
int id3FaceImage_FromBuffer (
ID3_FACE_IMAGE hImage,
unsigned char * data,
int dataSize,
id3FacePixelFormat ePixelFormat)
Parameters
hImageID3_FACE_IMAGEin Handle to the Image object.dataunsigned char *in A buffer that contains the image data.dataSizeintin Size of the ‘data’ buffer.ePixelFormatid3FacePixelFormatin The destination pixel format to convert the input to.
Returns