Apply color palette to raw image

Asked

Viewed 270 times

1

I have an image at gray levels and I want an algorithm to apply a color palette to it. Does anyone have a reference of an algorithm technique used or anything like that? I’m not experienced with digital image processing. If there is any C or python library that can help me make such an application or learn new things in the field, it is also quite useful.

Thanks

1 answer

1

You can use the GIMP. It has options for this right in the color menus - but if interactive use isn’t enough for you, the program exposes hundreds of calls to your internal API (called "PDB" - "Procedural Data Base"), the built-in Python and Scheme links - so you can easily script within the GIMP to open an image, compute a color map, and call pdb.gimp_image_set_colormap.

This is one of the options. Another is to use the pillow Python - and direct pixel access to color each pixel - ,as there are other various image templates that allow you to create this directly as well.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.