pouët.net

Any tool to dump VGA palette ?

category: general [glöplog]
 
Is there any existing MS-DOS tool (a TSR) that can dump the VGA palette used in mode 13h ?

For example you would press a key combination, and the 256 colors palette would be dumped to a binary file.

This would allow do study/check palette of many games, 256b intros etc...
I could write such a thing but maybe it already exists.
added on the 2016-06-08 09:40:52 by Tigrou Tigrou
Take a screenshot and get the palette from that
added on the 2016-06-08 10:06:09 by Harekiet Harekiet
@Harekiet : the colors won't be in the correct order. Also you need to get a screenshot which use ALL possible colors which is not always possible.
added on the 2016-06-08 10:09:03 by Tigrou Tigrou
I don't know of such a tool yet, but i'll write one out of pure interest if you don't beat me to it ;)
added on the 2016-06-08 10:13:08 by HellMood HellMood
If you take a screenshot internally with dosbox and you're in an 256 color mode you should get a 256 color png with the correct palette order.
You had similar tools for real dos like screenthief and I'd be fairly certain they also save the palette in the correct order.
added on the 2016-06-08 10:14:49 by Harekiet Harekiet
I just checked what Harekiet wrote, and it appears to be right. The palette is included in the PNG in the right order.
added on the 2016-06-08 10:20:41 by HellMood HellMood
@Harekiet : I didn't know that.
Btw, it perfectly make sense, why would it run a color quantizer on the pixel data while it could just grab the existing 256 colors VGA palette and wrote it to the PNG ?
added on the 2016-06-08 11:07:38 by Tigrou Tigrou
Note that the actual VGA palette is 6 bits per component, while PNG uses 8 bits.
added on the 2016-06-08 20:55:56 by absence absence

login