Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Cire

Possible to convert PNG to Doom palette?

Recommended Posts

Is there a way to convert a PNG image that resembles a palette-like pictures with 256 fields of different colors to a Doom palette format file? I've tried different ways to do it with GIMP but can't get it to work correctly.

Share this post


Link to post

Sure. Assuming you can convert it to a PNG that looks like such: then in SLADE you can create a new palette and import the PNG, and it will convert it.

Share this post


Link to post

Yep, I understand. The problem is that the image is much bigger in resolution ie. each field is a square that's several pixel in size, and there's black borders a few pixels between each color field. I suspected that was the reason SLADE can't convert it right off the bat. I'll try to get it working.

Share this post


Link to post

The black borders between each color would probably present a problem, yes.

One of the first things I would try would be to crop the thing properly, make sure it's 8-bit, and flood-fill the black lines in between each color to the same as the color at index #0 (i.e. the top left corner). Then use whatever image editor you have to try and extract a 256-color palette. If you're lucky, it would scan the image left-to-right, top-to-bottom and hit each color and index it in the proper order.

Share this post


Link to post
Cire said:

Is there a way to convert a PNG image that resembles a palette-like pictures with ....


You could use BHS's Palette Generator, which generates a palette.act file from any png image.
Simply drag the resulting act file into your pwad (use Slade3) and rename the lump to PLAYPAL.

Share this post


Link to post

Note that SLADE 3 can import Gimp palettes directly.

Archive->New->PLAYPAL (any one will do)
Then select the new palette lump, and Palettes->Import from... and select your Gimp palette file.

Share this post


Link to post

Sorry, I haven't had time to work on it, I've put it on hold for now.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×