enesim  0.0.23.1
Drawinglibrary
Functions
File based loading and saving
Image

Generic file loading and saving using the main context. More...

Functions

EAPI Eina_Bool enesim_image_file_info_get (const char *file, int *w, int *h, Enesim_Buffer_Format *sfmt, const char *options, Eina_Error *err)
EAPI Eina_Bool enesim_image_file_load (const char *file, Enesim_Buffer **b, Enesim_Pool *mpool, const char *options, Eina_Error *err)
EAPI void enesim_image_file_load_async (const char *file, Enesim_Buffer *b, Enesim_Pool *mpool, Enesim_Image_Callback cb, void *user_data, const char *options)
EAPI Eina_Bool enesim_image_file_save (const char *file, Enesim_Buffer *b, const char *options, Eina_Error *err)
EAPI void enesim_image_file_save_async (const char *file, Enesim_Buffer *b, Enesim_Image_Callback cb, void *user_data, const char *options)

Detailed Description

Generic file loading and saving using the main context.


Function Documentation

EAPI Eina_Bool enesim_image_file_info_get ( const char *  file,
int *  w,
int *  h,
Enesim_Buffer_Format sfmt,
const char *  options,
Eina_Error *  err 
)

Gets the information about an image file

Parameters:
[in]fileThe image file to load
[out]wThe image width
[out]hThe image height
[out]sfmtThe image original format
[in]optionsAny option the provider might require
[out]errThe error in case the file info load fails
EAPI Eina_Bool enesim_image_file_load ( const char *  file,
Enesim_Buffer **  b,
Enesim_Pool mpool,
const char *  options,
Eina_Error *  err 
)

Load an image synchronously

Parameters:
[in]fileThe image file to load
[out]bThe buffer to write the image pixels to. It must not be NULL.
mpoolThe mempool that will create the surface in case the surface reference is NULL
[in]optionsAny option the emage provider might require
[out]errThe error in case the file load fails
Returns:
EINA_TRUE in case the image was loaded correctly. EINA_FALSE if not
EAPI void enesim_image_file_load_async ( const char *  file,
Enesim_Buffer b,
Enesim_Pool mpool,
Enesim_Image_Callback  cb,
void *  data,
const char *  options 
)

Load an image file asynchronously

Parameters:
[in]fileThe image file to load
[in]bThe buffer to write the image pixels to. It must not be NULL.
[in]mpoolThe mempool that will create the surface in case the surface reference is NULL
[in]cbThe function that will get called once the load is done
[in]dataUser provided data
[in]optionsAny option the emage provider might require
EAPI Eina_Bool enesim_image_file_save ( const char *  file,
Enesim_Buffer b,
const char *  options,
Eina_Error *  err 
)

Save an image file synchronously

Parameters:
[in]fileThe image file to save
[in]bThe surface to read the image pixels from. It must not be NULL.
[in]optionsAny option the emage provider might require
[out]errThe error in case the file save fails
Returns:
EINA_TRUE in case the image was saved correctly. EINA_FALSE if not
EAPI void enesim_image_file_save_async ( const char *  file,
Enesim_Buffer b,
Enesim_Image_Callback  cb,
void *  data,
const char *  options 
)

Save an image file asynchronously

Parameters:
[in]fileThe image file to save
[in]bThe surface to read the image pixels from. It must not be NULL.
[in]cbThe function that will get called once the save is done
[in]dataUser provided data
[in]optionsAny option the emage provider might require
 All Data Structures Variables