How do I detect if desktop is 256 color?

BlitzMax Forums/BlitzMax Programming/How do I detect if desktop is 256 color?

Yes I thought about that too. If you could find out how much memory the desktop consumes, you could divide it by (Width*Height) to find out how many bytes per pixel. That would be great. But I don't know of any cross-platform single reliable way (or any way!) to get that information. Even if I were to open my own window with, say, a canvas on it, I don't know how to find out how much memory that graphics space takes up. If there were any way to know how much memory a given area of the screen consumes, we could know with quite good certainty what the actual desktop color depth is.