lv_image_decoder_open

Function lv_image_decoder_open 

Source
pub unsafe extern "C" fn lv_image_decoder_open(
    dsc: *mut lv_image_decoder_dsc_t,
    src: *const c_void,
    args: *const lv_image_decoder_args_t,
) -> lv_result_t
Expand description

Open an image. Try the created image decoders one by one. Once one is able to open the image that decoder is saved in dsc @param dsc describes a decoding session. Simply a pointer to an lv_image_decoder_dsc_t variable. @param src the image source. Can be 1) File name: E.g. “S:folder/img1.png” (The drivers needs to registered via lv_fs_drv_register())) 2) Variable: Pointer to an lv_image_dsc_t variable 3) Symbol: E.g. LV_SYMBOL_OK @param args args about how the image should be opened. @return LV_RESULT_OK: opened the image. dsc->decoded and dsc->header are set. LV_RESULT_INVALID: none of the registered image decoders were able to open the image.