14#ifndef RECOGNIZERIMAGE_HPP
15#define RECOGNIZERIMAGE_HPP
MBRecognizerErrorStatus
Enumeration of all possible error statuses.
Definition: RecognizerError.h:28
MBRawImageType
Enumeration of all possible raw image types.
Definition: RecognizerImage.h:44
@ MB_RAW_IMAGE_TYPE_GRAY
Definition: RecognizerImage.h:59
@ MB_RAW_IMAGE_TYPE_RGB
Definition: RecognizerImage.h:56
@ MB_RAW_IMAGE_TYPE_BGR
Definition: RecognizerImage.h:53
@ MB_RAW_IMAGE_TYPE_NV21
Definition: RecognizerImage.h:66
@ MB_RAW_IMAGE_TYPE_RGBA
Definition: RecognizerImage.h:50
@ MB_RAW_IMAGE_TYPE_BGRA
Definition: RecognizerImage.h:47
MBImageOrientation
Specifies the orientation of the contents of the image. This is important for some recognizers,...
Definition: RecognizerImage.h:82
@ MB_IMAGE_ORIENTATION_NO_ROTATION
Definition: RecognizerImage.h:97
@ MB_IMAGE_ORIENTATION_ROTATED_LEFT_90
Definition: RecognizerImage.h:89
@ MB_IMAGE_ORIENTATION_ROTATED_RIGHT_90
Definition: RecognizerImage.h:105
@ MB_IMAGE_ORIENTATION_ROTATED_180
Definition: RecognizerImage.h:113
unsigned char MBByte
Byte type for C SDK.
Definition: Types.h:29
MBRecognizerImage data structure. Holds image on which recognition will bw performed.
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageSetNewRawBuffer(MBRecognizerImage *image, MBByte const *input, uint16_t width, uint16_t height, uint16_t bytesPerRow, MBRawImageType rawType)
Sets a new buffer to the given MBRecognizerImage. NOTE: This function will not make copy of the given...
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageSetImageOrientation(MBRecognizerImage *image, MBImageOrientation orientation)
Sets the orientation of the image. When created, each image has default orientation IMAGE_ORIENTATION...
MB_API uint16_t MB_CALL recognizerImageGetHeight(MBRecognizerImage const *image)
Gets height of image in number of pixels.
MB_API MBImageOrientation MB_CALL recognizerImageGetImageOrientation(MBRecognizerImage const *image)
Gets the orientation of the image.
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageCreateCopyFromImage(MBRecognizerImage **image, MBRecognizerImage const *original)
Allocates and creates MBRecognizerImage by copying another MBRecognizerImage. This method will copy p...
MB_API MBByte *MB_CALL recognizerImageGetMutableRawBytes(MBRecognizerImage *image)
Gets modifiable buffer containing raw image bytes.
MB_API uint16_t MB_CALL recognizerImageGetBytesPerRow(MBRecognizerImage const *image)
Gets bytes per row for given image.
MB_API uint16_t MB_CALL recognizerImageGetWidth(MBRecognizerImage const *image)
Gets width of image in number of pixels.
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageCreateFromRawImage(MBRecognizerImage **image, MBByte const *input, uint16_t width, uint16_t height, uint16_t bytesPerRow, MBRawImageType rawType)
Allocates and creates MBRecognizerImage object from raw image. NOTE: This function will not make copy...
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageDelete(MBRecognizerImage **image)
Deletes the image object and sets pointer to NULL.
MB_API MBByte const *MB_CALL recognizerImageGetRawBytes(MBRecognizerImage const *image)
Gets buffer containing raw image bytes.
MB_API MBRecognizerErrorStatus MB_CALL recognizerImageLoadFromFile(MBRecognizerImage **image, char const *path)
Allocates and creates MBRecognizerImage object from given file. NOTE: Only JPG and PNG file types are...
MB_API MBRawImageType MB_CALL recognizerImageGetRawImageType(MBRecognizerImage const *image)
Gets raw image type for given image.