If you put the fields in the exact order as they are defined in the structs it should also work in cpp:
const lv_img_dsc_t SoS_Skull = {
.header.cf = LV_IMG_CF_RAW_ALPHA,
.header.always_zero = 0,
.header.reserved = 0,
.header.w = 191,
.header.h = 237,
.data_size = 11505,
.data = SoS_Skull_map,
};
The font converter orders the fields sequentially for this same reason.
@embeddedt Maybe a simple re-order of the fields in the image converter could help with this issue.
The thing is that the field order is actually dependent on the endianness of the device. So that check would also be needed in the image .c
file to work cross-platform.