This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Best way to compile large image data into a program for use during run time

Hello, we'd like to compile some large image files into our project, have the data available to stream to a display peripheral via LTDC+DSI peripherals. I tried to get cute and created a desktop program that imports pictures and generates C functions to set memory locations, like:

void InitImageData_Untitled_400x400_To(uint32_t img_address)
{
    *(uint32_t*) (img_address + 0x00000000) = 0xFF00A400;
    //...
}

except for larger images this function gets impossibly large and crashes my compiler. :)

So I'm done being clever, and I'm asking the experts about the Right way to do this. What is the easiest way to compile bulk image data into a program for access during runtime?

Thanks very much!