On windows with VS2019 and simulator it works, now on esp always no data…
What I’m doing for testing on esp…
define my hex-byte array raw png…
const uint8_t myByteArray[] =
{
0x89, 0x50, 0x4E, 0x47, 0x0D, 0x0A, 0x1A, 0x0A, 0x00, 0x00, 0x00, 0x0D, 0x49, 0x48, 0x44, 0x52,
0x00, 0x00, 0x00, 0x5F, 0x00, 0x00, 0x00, 0x5F, 0x08, 0x06, 0x00, 0x00, 0x00, 0x8E, 0x4C, 0x1B,
the my init of decoder
lv_png_init();
then my drawing…
imgMaps = lv_img_create(screen, NULL);
nav_dest_png.header.always_zero = 0;
nav_dest_png.header.w = 95;
nav_dest_png.header.h = 95;
nav_dest_png.data_size = sizeof(myByteArray);
nav_dest_png.header.cf = LV_IMG_CF_RAW_ALPHA;
nav_dest_png.data = myByteArray;
lv_img_set_src(imgMaps, &nav_dest_png);
lv_img_cache_invalidate_src(&imgMaps);
lv_obj_align(imgMaps, NULL, LV_ALIGN_IN_TOP_LEFT, 20, 20);