Generates C and Header files from an image for displaying it on DM-LCD35RT module using standar library. This is an alternative for Embedded Resource Editor GUI by ST, that doesn't have support for Linux.
- ImageMagick sometimes doesn't conver the RGB888 to RGB565, so, I suggest to use this web page https://online-converting.com/image/convert2bmp to conver any image into RGB565, then use stm32f4_img2c to generate the c code
- Getting Started
- Compilation
- Requirements
- References
Given the fact it uses ImageMagick, the input image can be in any format that ImageMagick can handle, such as: PNG, JPG, BMP, etc. Be aware that the image size for this LCD is 320x240 max. stm32f4_img2c won't verify the size, because it might be helpful to generate BMP code for all image sizes.
- Compile the sources
- Give executable attributes:
chmod +x stm32f4_img2c
- Generate the code from any image
stm32f4_img2c input_image.JPG output/directory
- if you already have and image on BMP RGB565, call the bmp2c:
bin/stm32f4_bmp2c input_image.bmp input_image.bmp output/directory
Yes, the input image is twice
- Create a new folder
mkdir bin
- Compile
make
- Make
- GCC
- ImageMagick