Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Exporting 16bit BMP
#4
(04-16-2022, 01:37 PM)bilbo Wrote: The BMP file is for a custom splash screen on a  car radio. It requires a 16 bit BMP R5G6B5. The file I generate using the advanced export option won't work. I am assuming it is in the wrong format. When I open the BMP file with GIMP, the header shows:
"[image3](imported)-1.0 (RGB color 8-bit gamma integer, GIMP built in sRGB, 1 layer) 800x480-GIMP".

The Gimp bmp rgb565 file will be correct but obviously not the correct format for the device.

Quote:The file is 770 KB. Maybe it is actually in the right format? Any help yopu can give me would be appreciated

As a very rough check, export as a 24 bit bmp and compare file size. The rgb 565 bmp will be smaller.

The problem is confirming that it is RGB 565. When you re-open in Gimp it is converted to RGB 888 ie. an 8 bit image. Other utilities I have also classify as 8 bit RGB.

As well as ffmpeg there is another command line utility ImageMagick (IM) http://www.imagemagick.org that will convert to a RGB 565 bmp

Code:
magick rgb.png -define bmp:format=bmp4 -define bmp:subtype=rgb565  im-565.bmp

The only confirmation I have is the filesize from IM is the exactly same as from GIMP.

A search found this on-line convertor: https://lvgl.io/tools/imageconverter but it outputs a raw file, no header, similar to ffmpeg (4 bytes difference) I can open that in Gimp as a raw (data) file. So the colour information is there, other parameters also come into play, big endian / little endian will swap colours. You could give that a try.

Sorry, not much else I can suggest, especially for a Mac.
Reply


Messages In This Thread
Exporting 16bit BMP - by bilbo - 04-15-2022, 09:15 PM
RE: Exporting 16bit BMP - by rich2005 - 04-16-2022, 09:31 AM
RE: Exporting 16bit BMP - by programmer_ceds - 04-16-2022, 04:05 PM
RE: Exporting 16bit BMP - by bilbo - 04-16-2022, 01:37 PM
RE: Exporting 16bit BMP - by rich2005 - 04-16-2022, 03:35 PM
RE: Exporting 16bit BMP - by bilbo - 04-16-2022, 06:44 PM
RE: Exporting 16bit BMP - by programmer_ceds - 04-16-2022, 07:28 PM

Forum Jump: