HOPKINS: Apply a couple of renamings suggested by wjp

This commit is contained in:
Strangerke 2013-04-13 23:24:13 +02:00
parent 7de4a7972e
commit cdefd6428f
6 changed files with 24 additions and 24 deletions

View File

@ -90,7 +90,7 @@ void AnimationManager::playAnim(const Common::String &filename, uint32 rate1, ui
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
} else {
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_graphicsMan->copy16BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->addRefreshRect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
_vm->_graphicsMan->updateScreen();
}
@ -240,7 +240,7 @@ void AnimationManager::playAnim2(const Common::String &filename, uint32 rate1, u
_vm->_graphicsMan->_maxX = SCREEN_WIDTH;
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_graphicsMan->copy16BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->addRefreshRect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
_vm->_graphicsMan->updateScreen();
@ -338,12 +338,12 @@ void AnimationManager::playAnim2(const Common::String &filename, uint32 rate1, u
if (_vm->_graphicsMan->_largeScreenFl) {
_vm->_graphicsMan->setScreenWidth(2 * SCREEN_WIDTH);
_vm->_graphicsMan->_maxX = 2 * SCREEN_WIDTH;
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_frontBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_frontBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
} else {
_vm->_graphicsMan->setScreenWidth(SCREEN_WIDTH);
_vm->_graphicsMan->_maxX = SCREEN_WIDTH;
_vm->_graphicsMan->clearScreen();
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_frontBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_frontBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
}
_vm->_graphicsMan->addRefreshRect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
@ -578,7 +578,7 @@ void AnimationManager::playSequence(const Common::String &file, uint32 rate1, ui
}
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
} else {
_vm->_graphicsMan->copy16BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->addRefreshRect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
_vm->_graphicsMan->updateScreen();
}
@ -696,7 +696,7 @@ void AnimationManager::playSequence2(const Common::String &file, uint32 rate1, u
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
} else {
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_graphicsMan->copy16BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(screenP, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->addRefreshRect(0, 0, SCREEN_WIDTH, SCREEN_HEIGHT);
_vm->_graphicsMan->updateScreen();

View File

@ -464,7 +464,7 @@ void EventsManager::refreshScreenAndEvents() {
_vm->_graphicsMan->displayDirtyRects();
} else {
_vm->_fontMan->hideText(9);
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_frontBuffer, _vm->_graphicsMan->_scrollPosX, 20, SCREEN_WIDTH, 440, 0, 20);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_frontBuffer, _vm->_graphicsMan->_scrollPosX, 20, SCREEN_WIDTH, 440, 0, 20);
_vm->_graphicsMan->resetRefreshRects();
_vm->_graphicsMan->addRefreshRect(0, 20, SCREEN_WIDTH, SCREEN_HEIGHT - 20);

View File

@ -222,14 +222,14 @@ void GraphicsManager::loadScreen(const Common::String &file) {
_maxX = SCREEN_WIDTH;
clearScreen();
copy16BitRect(_backBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(_backBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
} else {
setScreenWidth(SCREEN_WIDTH * 2);
_maxX = SCREEN_WIDTH * 2;
clearScreen();
if (MANU_SCROLL)
copy16BitRect(_backBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(_backBuffer, 0, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
}
memcpy(_frontBuffer, _backBuffer, SCREEN_WIDTH * 2 * SCREEN_HEIGHT);
@ -409,7 +409,7 @@ void GraphicsManager::setScreenWidth(int pitch) {
/**
* Copies data from a 8-bit palette surface into the 16-bit screen
*/
void GraphicsManager::copy16BitRect(const byte *surface, int xs, int ys, int width, int height, int destX, int destY) {
void GraphicsManager::display8BitRect(const byte *surface, int xs, int ys, int width, int height, int destX, int destY) {
lockScreen();
assert(_videoPtr);
@ -436,7 +436,7 @@ void GraphicsManager::copy16BitRect(const byte *surface, int xs, int ys, int wid
addRefreshRect(destX, destY, destX + width, destY + height);
}
void GraphicsManager::copy8BitRect(const byte *surface, int xp, int yp, int width, int height, int destX, int destY) {
void GraphicsManager::displayScaled8BitRect(const byte *surface, int xp, int yp, int width, int height, int destX, int destY) {
int xCtr;
const byte *palette;
int savedXCount;
@ -501,7 +501,7 @@ void GraphicsManager::fadeIn(const byte *palette, int step, const byte *surface)
// Set the transition palette and refresh the screen
setPaletteVGA256(palData2);
copy16BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
updateScreen();
// Added a delay in order to see the fading
@ -512,7 +512,7 @@ void GraphicsManager::fadeIn(const byte *palette, int step, const byte *surface)
setPaletteVGA256(palette);
// Refresh the screen
copy16BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
updateScreen();
}
@ -531,7 +531,7 @@ void GraphicsManager::fadeOut(const byte *palette, int step, const byte *surface
}
setPaletteVGA256(palData);
copy16BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
updateScreen();
_vm->_events->delay(20);
@ -543,7 +543,7 @@ void GraphicsManager::fadeOut(const byte *palette, int step, const byte *surface
palData[i] = 0;
setPaletteVGA256(palData);
copy16BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
updateScreen();
}
@ -623,7 +623,7 @@ void GraphicsManager::setPaletteVGA256(const byte *palette) {
void GraphicsManager::setPaletteVGA256WithRefresh(const byte *palette, const byte *surface) {
changePalette(palette);
copy16BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(surface, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
updateScreen();
}
@ -1108,7 +1108,7 @@ void GraphicsManager::displayDirtyRects() {
Common::Rect dstRect;
if (_vm->_events->_breakoutFl) {
copy8BitRect(_frontBuffer, r.left, r.top, r.right - r.left, r.bottom - r.top, r.left, r.top);
displayScaled8BitRect(_frontBuffer, r.left, r.top, r.right - r.left, r.bottom - r.top, r.left, r.top);
dstRect.left = r.left * 2;
dstRect.top = r.top * 2 + 30;
dstRect.setWidth((r.right - r.left) * 2);
@ -1117,7 +1117,7 @@ void GraphicsManager::displayDirtyRects() {
r.left = MAX<int16>(r.left, _vm->_events->_startPos.x);
r.right = MIN<int16>(r.right, (int16)_vm->_events->_startPos.x + SCREEN_WIDTH);
copy16BitRect(_frontBuffer, r.left, r.top, r.right - r.left, r.bottom - r.top, r.left - _vm->_events->_startPos.x, r.top);
display8BitRect(_frontBuffer, r.left, r.top, r.right - r.left, r.bottom - r.top, r.left - _vm->_events->_startPos.x, r.top);
dstRect.left = r.left - _vm->_events->_startPos.x;
dstRect.top = r.top;
@ -1743,7 +1743,7 @@ void GraphicsManager::displayScreen(bool initPalette) {
else if (_lineNbr == (SCREEN_WIDTH * 2))
fillSurface(_frontBuffer, _colorTable, SCREEN_WIDTH * SCREEN_HEIGHT * 2);
copy16BitRect(_frontBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
display8BitRect(_frontBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
memcpy(_backBuffer, _frontBuffer, 614399);
updateScreen();
}

View File

@ -82,7 +82,7 @@ private:
void copy16bFromSurfaceScaleX2(const byte *surface);
void translateSurface(byte *destP, const byte *srcP, int count, int minThreshold, int maxThreshold);
void copy8BitRect(const byte *surface, int xp, int yp, int width, int height, int destX, int destY);
void displayScaled8BitRect(const byte *surface, int xp, int yp, int width, int height, int destX, int destY);
void lockScreen();
void unlockScreen();
@ -176,7 +176,7 @@ public:
void drawCompressedSprite(byte *surface, const byte *srcData, int xp300, int yp300, int frameIndex, int zoom1, int zoom2, bool flipFl);
void copyRect(const byte *srcSurface, int x1, int y1, uint16 width, int height, byte *destSurface, int destX, int destY);
void drawVesaSprite(byte *surface, const byte *spriteData, int xp, int yp, int spriteIndex);
void copy16BitRect(const byte *surface, int xs, int ys, int width, int height, int destX, int destY);
void display8BitRect(const byte *surface, int xs, int ys, int width, int height, int destX, int destY);
void fillSurface(byte *surface, byte *col, int size);
void displayScreen(bool initPalette);
void backupScreen();

View File

@ -2685,7 +2685,7 @@ void ObjectsManager::handleSpecialGames() {
memcpy(_vm->_graphicsMan->_palette, oldPalette, 769);
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_globals->freeMemory(oldPalette);
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
memcpy(_vm->_graphicsMan->_frontBuffer, _vm->_graphicsMan->_backBuffer, 614399);
_vm->_graphicsMan->_scrollStatus = 0;

View File

@ -138,7 +138,7 @@ void TalkManager::startAnimatedCharacterDialogue(const Common::String &filename)
_vm->_graphicsMan->initColorTable(145, 150, _vm->_graphicsMan->_palette);
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
memcpy(_vm->_graphicsMan->_frontBuffer, _vm->_graphicsMan->_backBuffer, 614399);
_vm->_globals->_disableInventFl = oldDisableInventFl;
_vm->_graphicsMan->updateScreen();
@ -1068,7 +1068,7 @@ void TalkManager::animateObject(const Common::String &filename) {
_vm->_graphicsMan->initColorTable(145, 150, _vm->_graphicsMan->_palette);
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
_vm->_graphicsMan->copy16BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->display8BitRect(_vm->_graphicsMan->_backBuffer, _vm->_events->_startPos.x, 0, SCREEN_WIDTH, SCREEN_HEIGHT, 0, 0);
_vm->_graphicsMan->setPaletteVGA256(_vm->_graphicsMan->_palette);
memcpy(_vm->_graphicsMan->_frontBuffer, _vm->_graphicsMan->_backBuffer, 614399);
_vm->_globals->_disableInventFl = false;