Better naming for the palette setting functions, to disambiguate them from the existing ones
svn-id: r44662
This commit is contained in:
parent
f3d3596d54
commit
3e66ae85f6
3 changed files with 9 additions and 9 deletions
|
@ -251,7 +251,7 @@ void SciGui::drawPicture(GuiResourceId pictureId, uint16 style, uint16 flags, in
|
|||
|
||||
void SciGui::drawCel(GuiResourceId viewId, GuiViewLoopNo loopNo, GuiViewCelNo celNo, uint16 leftPos, uint16 topPos, int16 priority, uint16 paletteNo) {
|
||||
_gfx->drawCel(viewId, loopNo, celNo, leftPos, topPos, priority, paletteNo);
|
||||
_gfx->setPalette(&_gfx->_sysPalette);
|
||||
_gfx->setScreenPalette(&_gfx->_sysPalette);
|
||||
_screen->copyToScreen();
|
||||
}
|
||||
|
||||
|
@ -329,7 +329,7 @@ int16 SciGui::paletteFind(int r, int g, int b) {
|
|||
void SciGui::paletteSetIntensity(int fromColor, int toColor, int intensity, bool setPalette) {
|
||||
_gfx->PaletteSetIntensity(fromColor, toColor, intensity, &_gfx->_sysPalette);
|
||||
if (setPalette) {
|
||||
_gfx->setPalette(&_gfx->_sysPalette);
|
||||
_gfx->setScreenPalette(&_gfx->_sysPalette);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -147,7 +147,7 @@ void SciGuiGfx::SetEGApalette() {
|
|||
_sysPalette.colors[i].r = 200;
|
||||
_sysPalette.colors[i].used = 1;
|
||||
}
|
||||
setPalette(&_sysPalette);
|
||||
setScreenPalette(&_sysPalette);
|
||||
}
|
||||
|
||||
void SciGuiGfx::CreatePaletteFromData(byte *data, GuiPalette *paletteOut) {
|
||||
|
@ -212,7 +212,7 @@ void SciGuiGfx::SetPalette(GuiPalette *sciPal, int16 flag) {
|
|||
MergePalettes(sciPal, &_sysPalette, flag);
|
||||
sciPal->timestamp = _sysPalette.timestamp;
|
||||
if (_picNotValid == 0 && systime != _sysPalette.timestamp)
|
||||
setPalette(&_sysPalette);
|
||||
setScreenPalette(&_sysPalette);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -282,7 +282,7 @@ uint16 SciGuiGfx::MatchColor(GuiPalette*pPal, byte r, byte g, byte b) {
|
|||
return found;
|
||||
}
|
||||
|
||||
void SciGuiGfx::setPalette(GuiPalette*pal) {
|
||||
void SciGuiGfx::setScreenPalette(GuiPalette*pal) {
|
||||
if (pal != &_sysPalette)
|
||||
memcpy(&_sysPalette,pal,sizeof(GuiPalette));
|
||||
// just copy palette to system
|
||||
|
@ -300,7 +300,7 @@ void SciGuiGfx::setPalette(GuiPalette*pal) {
|
|||
_system->setPalette(bpal, 0, 256);
|
||||
}
|
||||
|
||||
void SciGuiGfx::getPalette(GuiPalette*pal) {
|
||||
void SciGuiGfx::getScreenPalette(GuiPalette*pal) {
|
||||
if (pal != &_sysPalette)
|
||||
memcpy(pal, &_sysPalette,sizeof(GuiPalette));
|
||||
}
|
||||
|
@ -1285,7 +1285,7 @@ void SciGuiGfx::PaletteAnimate(byte fromColor, byte toColor, int speed) {
|
|||
// removing schedule
|
||||
_palSchedules.remove_at(i);
|
||||
}
|
||||
setPalette(&_sysPalette);
|
||||
setScreenPalette(&_sysPalette);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -57,8 +57,8 @@ public:
|
|||
void SetPalette(GuiPalette *sciPal, int16 flag);
|
||||
void MergePalettes(GuiPalette *pFrom, GuiPalette *pTo, uint16 flag);
|
||||
uint16 MatchColor(GuiPalette *pPal, byte r, byte g, byte b);
|
||||
void setPalette(GuiPalette *pal);
|
||||
void getPalette(GuiPalette *pal);
|
||||
void setScreenPalette(GuiPalette *pal);
|
||||
void getScreenPalette(GuiPalette *pal);
|
||||
|
||||
GuiPort *SetPort(GuiPort *port);
|
||||
GuiPort *GetPort();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue