Face SDK  1.13.0 Mozart release
Face Recognition Software Development Kit
image.h
1 
4 #pragma once
5 
6 #include <face_sdk_base/export.h>
7 
8 #include <c_interface/common/face_sdk_class.h>
9 #include <c_interface/common/face_sdk_set.h>
10 
11 FACE_SDK_EXTERN_C_BEGIN
12 
23 DECLARE_FACE_SDK_CLASS(image)
24 
25 
33 bool FACE_SDK_C_EXPORT face_sdk__load_image_from_file(const uint8_t *file_name, uint64_t file_name_size, face_sdk__image_t **image);
34 
43 bool FACE_SDK_C_EXPORT face_sdk__load_image_from_data(const uint8_t *data, uint64_t data_size, face_sdk__image_t **image);
44 
54 bool FACE_SDK_C_EXPORT face_sdk__make_image_from_data(const uint8_t *data, uint32_t width, uint32_t height,
55  face_sdk__image_t **image);
56 
67 bool FACE_SDK_C_EXPORT face_sdk__make_image_from_data_1(const uint8_t *data, uint32_t width, uint32_t height,
68  uint64_t stride, face_sdk__image_t **image);
69 
77 bool FACE_SDK_C_EXPORT face_sdk__image__get_width(const face_sdk__image_t *image, int32_t *value);
78 
86 bool FACE_SDK_C_EXPORT face_sdk__image__get_height(const face_sdk__image_t *image, int32_t *value);
87 
95 bool FACE_SDK_C_EXPORT face_sdk__image__get_stride(const face_sdk__image_t *image, uint64_t *value);
96 
105 bool FACE_SDK_C_EXPORT face_sdk__image__get_data(const face_sdk__image_t *image, void **data, uint64_t *data_size);
106 
111 void FACE_SDK_C_EXPORT face_sdk__image_free(face_sdk__image_t *image);
112 
115 FACE_SDK_EXTERN_C_END
bool face_sdk__make_image_from_data(const uint8_t *data, uint32_t width, uint32_t height, face_sdk__image_t **image)
Makes image object from bitmap. Bitmap must 24bpp RGB format.
bool face_sdk__load_image_from_file(const uint8_t *file_name, uint64_t file_name_size, face_sdk__image_t **image)
Load encoded image from file. Image must be in RBG or BRG channels order. Grayscale or images with al...
void face_sdk__image_free(face_sdk__image_t *image)
Destroys Image object.
bool face_sdk__make_image_from_data_1(const uint8_t *data, uint32_t width, uint32_t height, uint64_t stride, face_sdk__image_t **image)
Makes image object from bitmap. Bitmap must 24bpp RGB format.
bool face_sdk__image__get_height(const face_sdk__image_t *image, int32_t *value)
Retrieves image height.
An image keeps bitmap data in 24bpp RBG format.
Definition: image.h:23
bool face_sdk__image__get_width(const face_sdk__image_t *image, int32_t *value)
Retrieves image width.
bool face_sdk__load_image_from_data(const uint8_t *data, uint64_t data_size, face_sdk__image_t **image)
Load encoded image from memory.
bool face_sdk__image__get_data(const face_sdk__image_t *image, void **data, uint64_t *data_size)
Retrieves image data.
bool face_sdk__image__get_stride(const face_sdk__image_t *image, uint64_t *value)
Retrieves image stride.