I need help, I've read lots of threads but I'm not getting it. Maybe someone have some clues.
I want remove from image "A" all colors that dont exist in pallete "P", so the final image "B" will be transparent excluding the colors that exist on pallette P
Can I do this with IM?
Image "A"

Palette "P"

Image "B" (output)

Sorry for my bad english.
Thank you in advance for any help or directions to explore, and Merry Christmas to all