Public Types | |
enum | PalIndex { Pal_Game = 0, Pal_Movie = 1, Pal_Diff = 2, Pal_Misc = 3, Pal_Misc2 = 4, Pal_Star = 5, Pal_Cred = 6, Pal_JPFontStart = 16 } |
Public Member Functions | |
PaletteManager (const Graphics::PixelFormat &format) | |
void | load (PalIndex index, Common::ReadStream &rs, Common::ReadStream &xformrs) |
void | load (PalIndex index, Common::ReadStream &rs) |
Palette * | getPalette (PalIndex index) |
void | duplicate (PalIndex src, PalIndex dest) |
void | updatedPalette (PalIndex index, int maxindex=0) |
void | transformPalette (PalIndex index, const int16 matrix[12]) |
Apply a transform matrix to a palette (-4.11 fixed) | |
void | untransformPalette (PalIndex index) |
reset the transformation matrix of a palette | |
bool | getTransformMatrix (int16 matrix[12], PalIndex index) |
Get the current TransformMatrix for the given index. | |
void | PixelFormatChanged (const Graphics::PixelFormat &format) |
Change the pixel format used by the PaletteManager. | |
void | reset () |
Reset the Palette Manager. | |
void | resetTransforms () |
Reset all the transforms back to default. | |
bool | loadTransforms (Common::ReadStream &rs) |
void | saveTransforms (Common::WriteStream &ws) |
void | createNativePalette (Palette *palette, int maxindex, const Graphics::PixelFormat &format) |
Static Public Member Functions | |
static PaletteManager * | get_instance () |
static void | getTransformMatrix (int16 matrix[12], PalTransforms trans) |
static void | getTransformMatrix (int16 matrix[12], uint32 col32) |
void Ultima::Ultima8::PaletteManager::updatedPalette | ( | PalIndex | index, |
int | maxindex = 0 |
||
) |
Re-convert a palette to native format after modifying it. If maxindex is set, only recalculate color indexes up to that value.