Aren’t you guys overthinking this? If you load a 256 color image onto a 32-bit screen (which is what _LOADIMAGE current does), then all you need to do is a simple read-and-convert loop to put it on a 256 color screen. No need for dithering, or anything fancy... Just (pseudocode follows as I’m not at my PC currently)
Aren’t you guys overthinking this? If you load a 256 color image onto a 32-bit screen (which is what _LOADIMAGE current does), then all you need to do is a simple read-and-convert loop to put it on a 256 color screen. No need for dithering, or anything fancy... Just (pseudocode follows as I’m not at my PC currently)
It would be nice if QB64 supported loading 8bit images to an 8bit screen. The two simplest ways to do this are adopting the palette of the image, or when loading the image rematching the palette to the closest colour that already exists in the screen palette. These require minimal coding.
There's also 7, 6, 5, 4, 3, 2, 1bit images, which could leave part of the screen palette alone.
That said, I can't imagine why a new programmer like ironwolfe is wanting to use a 256 colour palette screen on a modern PC. ironwolfe, just use a 32bit screen and be done with it! :-)