04-27-2025, 02:33 AM
I've tried loading a 32 bit image and saving it as an 8bit image, but it doesn't seem to work. Image editors like Graphics Gale can't seem to open it, and when I try to reload it that fails also.
checking the image:
Code: (Select All)
''Test loading a 32bit image and saving it to 8 bit
Option _Explicit
Screen _NewImage(320,240,256)
Dim img32& : img32& = _LoadImage("img32.png", 256)
Dim img8bit& : img8bit& = _NewImage(64, 64, 256)
_PutImage (0,0),img32&, img8bit&
_SaveImage "img8bit.bmp", img8bit&
_FreeImage(img32&)
_FreeImage(img8bit&)
Sleep
End
checking the image:
Code: (Select All)
''Load and check an image
Dim img8& : img8& = _LoadImage("img8bit&.bmp", 256)
Screen _NewImage(320, 240, 256)
_PutImage (0,0), img8&
_FreeImage(img8&)
sleep
end