In theory this gave you a lot of options, but in practice, switching palettes tended to cause "palette flash" where the previous image changed color in a distracting flash.
I was doing a multimedia project that had video in it, and each CODEC had its own built in palette -- one for Cinepak, one for Indeo, etc. Then there were other palettes for the images. If you wanted to display video in a window on a page that had other graphics, you could determine the palette of the CODEC (with some effort) and then use that to dither your graphics. Theoretically they should play nice together, and it worked on some cards, but you'd still get palette flash on other mainstream graphics cards.
I tried every trick I could think of but could not eliminate the flash on every single card until I came up with this hack:
Make a video consisting of a single frame with a 1x1 black pixel, compressed in the desired CODEC, display a black screen for a moment, play that video (which was as fast as could be because it was so tiny) over the screen, then load your image and real video.
The black screen couldn't flash, and when the next screen and video (the real one we wanted to play) came up, the palette was already set correctly. And it worked on every video card.