Go to the source code of this file.
|
| void * | rf_load_image_from_rgb_buffer (uint8_t *buffer, size_t height, size_t width, int rotation, rf_error_type *error) |
| |
| void * | rf_load_image_from_rgba_buffer (uint8_t *buffer, size_t height, size_t width, int rotation, rf_error_type *error) |
| |
| void * | rf_load_image_from_jpeg_buffer (uint8_t *buffer, size_t size, int rotation, rf_error_type *error) |
| |
| void * | rf_load_image_from_file (const char *image_path, int rotation, rf_error_type *error) |
| |
| void | rf_get_image_size (void *image_handle, int *out_height, int *out_width, rf_error_type *error) |
| |
| void | rf_free_image (void *image_handle, rf_error_type *error) |
| |
| void | rf_save_image (void *image_handle, const char *path, rf_error_type *error) |
| |
◆ rf_free_image()
| void rf_free_image |
( |
void * |
image_handle, |
|
|
rf_error_type * |
error |
|
) |
| |
◆ rf_get_image_size()
| void rf_get_image_size |
( |
void * |
image_handle, |
|
|
int * |
out_height, |
|
|
int * |
out_width, |
|
|
rf_error_type * |
error |
|
) |
| |
Get image's height and width in pixels
- Parameters
-
| image_handle | image handle. |
- See also
- rf_load_image_from_rgba_buffer
- Parameters
-
| out_height | output parameter to get the image's height |
| out_width | output parameter to get the image's width |
| error | output parameter for error |
◆ rf_load_image_from_file()
| void* rf_load_image_from_file |
( |
const char * |
image_path, |
|
|
int |
rotation, |
|
|
rf_error_type * |
error |
|
) |
| |
Load image from a file such as *.jpg or *.png
- Parameters
-
| image_path | path to the image file (e.g. image.jpg) |
| rotation | rotate image. 0 - don't rotate. Supported values are 90 and 270 degrees |
| error | output parameter for error |
- Returns
- image_handle
◆ rf_load_image_from_jpeg_buffer()
| void* rf_load_image_from_jpeg_buffer |
( |
uint8_t * |
buffer, |
|
|
size_t |
size, |
|
|
int |
rotation, |
|
|
rf_error_type * |
error |
|
) |
| |
Load image from RGBA buffer
- Parameters
-
| buffer | byte buffer |
| size | buffer size in bytes |
| rotation | rotate image. 0 - don't rotate. Supported values are 90 and 270 degrees |
| error | output parameter for error |
- Returns
- image_handle
◆ rf_load_image_from_rgb_buffer()
| void* rf_load_image_from_rgb_buffer |
( |
uint8_t * |
buffer, |
|
|
size_t |
height, |
|
|
size_t |
width, |
|
|
int |
rotation, |
|
|
rf_error_type * |
error |
|
) |
| |
Load image from RGB buffer
- Parameters
-
| buffer | byte buffer |
| height | height in pixels |
| width | width in pixels |
| rotation | rotate image. 0 - don't rotate. Supported values 90 and 270 degrees |
| error | output parameter for error |
- Returns
- image_handle
◆ rf_load_image_from_rgba_buffer()
| void* rf_load_image_from_rgba_buffer |
( |
uint8_t * |
buffer, |
|
|
size_t |
height, |
|
|
size_t |
width, |
|
|
int |
rotation, |
|
|
rf_error_type * |
error |
|
) |
| |
Load image from RGBA buffer
- Parameters
-
| buffer | byte buffer |
| height | height in pixels |
| width | width in pixels |
| rotation | rotate image. 0 - don't rotate. Supported values are 90 and 270 degrees |
| error | output parameter for error |
- Returns
- image_handle
◆ rf_save_image()
| void rf_save_image |
( |
void * |
image_handle, |
|
|
const char * |
path, |
|
|
rf_error_type * |
error |
|
) |
| |
Save image in png format.
- Parameters
-
| image_handle | image handle. |
- See also
- rf_load_image_from_rgba_buffer
- Parameters
-
| path | path and file name of output image including .png. Example "debug/image.png" |
| error | output parameter for error |