mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-21 01:08:25 +00:00
VOYEUR: Remove unused variables and functions in GraphicsManager
This commit is contained in:
parent
3584680587
commit
27d624e79f
@ -90,7 +90,7 @@ void EventsManager::startMainClockInt() {
|
|||||||
_mainIntNode._intFunc = &EventsManager::mainVoyeurIntFunc;
|
_mainIntNode._intFunc = &EventsManager::mainVoyeurIntFunc;
|
||||||
_mainIntNode._flags = 0;
|
_mainIntNode._flags = 0;
|
||||||
_mainIntNode._curTime = 0;
|
_mainIntNode._curTime = 0;
|
||||||
_mainIntNode._timeReset = _vm->_graphicsManager._palFlag ? 50 : 60;
|
_mainIntNode._timeReset = 60;
|
||||||
}
|
}
|
||||||
|
|
||||||
void EventsManager::mainVoyeurIntFunc() {
|
void EventsManager::mainVoyeurIntFunc() {
|
||||||
|
@ -832,7 +832,7 @@ int DisplayResource::drawText(const Common::String &msg) {
|
|||||||
ViewPortResource *viewPort = !(_flags & DISPFLAG_VIEWPORT) ? NULL :
|
ViewPortResource *viewPort = !(_flags & DISPFLAG_VIEWPORT) ? NULL :
|
||||||
(ViewPortResource *)this;
|
(ViewPortResource *)this;
|
||||||
|
|
||||||
if (gfxManager._drawTextPermFlag || (fontInfo._fontFlags & DISPFLAG_1) || fontInfo._justify ||
|
if ((fontInfo._fontFlags & DISPFLAG_1) || fontInfo._justify ||
|
||||||
(gfxManager._saveBack && fontInfo._fontSaveBack && (_flags & DISPFLAG_VIEWPORT))) {
|
(gfxManager._saveBack && fontInfo._fontSaveBack && (_flags & DISPFLAG_VIEWPORT))) {
|
||||||
msgWidth = viewPort->textWidth(msg);
|
msgWidth = viewPort->textWidth(msg);
|
||||||
yp = pos.y;
|
yp = pos.y;
|
||||||
|
@ -1238,7 +1238,7 @@ void ThreadResource::doRoom() {
|
|||||||
|
|
||||||
_vm->flipPageAndWait();
|
_vm->flipPageAndWait();
|
||||||
|
|
||||||
vm._graphicsManager.fadeUpICF1(0);
|
vm._graphicsManager.fadeUpICF1();
|
||||||
voy._eventFlags &= EVTFLAG_RECORDING;
|
voy._eventFlags &= EVTFLAG_RECORDING;
|
||||||
vm._eventsManager.showCursor();
|
vm._eventsManager.showCursor();
|
||||||
}
|
}
|
||||||
@ -1595,7 +1595,7 @@ void ThreadResource::freeTheApt() {
|
|||||||
_vm->_graphicsManager.fadeDownICF1(5);
|
_vm->_graphicsManager.fadeDownICF1(5);
|
||||||
_vm->flipPageAndWaitForFade();
|
_vm->flipPageAndWaitForFade();
|
||||||
|
|
||||||
_vm->_graphicsManager.fadeUpICF1(0);
|
_vm->_graphicsManager.fadeUpICF1();
|
||||||
|
|
||||||
if (_vm->_currentVocId != -1) {
|
if (_vm->_currentVocId != -1) {
|
||||||
_vm->_soundManager.stopVOCPlay();
|
_vm->_soundManager.stopVOCPlay();
|
||||||
|
@ -31,25 +31,17 @@ namespace Voyeur {
|
|||||||
|
|
||||||
/*------------------------------------------------------------------------*/
|
/*------------------------------------------------------------------------*/
|
||||||
|
|
||||||
DrawInfo::DrawInfo(int penColor, const Common::Point &pos, int flags) {
|
DrawInfo::DrawInfo(int penColor, const Common::Point &pos) {
|
||||||
_penColor = penColor;
|
_penColor = penColor;
|
||||||
_pos = pos;
|
_pos = pos;
|
||||||
_flags = flags;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*------------------------------------------------------------------------*/
|
/*------------------------------------------------------------------------*/
|
||||||
|
|
||||||
GraphicsManager::GraphicsManager(): _defaultDrawInfo(1, Common::Point(), 0), _drawPtr(&_defaultDrawInfo) {
|
GraphicsManager::GraphicsManager(): _defaultDrawInfo(1, Common::Point()), _drawPtr(&_defaultDrawInfo) {
|
||||||
_SVGAPage = 0;
|
|
||||||
_SVGAMode = 0;
|
_SVGAMode = 0;
|
||||||
_SVGAReset = 0;
|
|
||||||
_screenOffset = 0;
|
|
||||||
_planeSelect = 0;
|
_planeSelect = 0;
|
||||||
_sImageShift = 3;
|
|
||||||
_palFlag = false;
|
|
||||||
_MCGAMode = false;
|
|
||||||
_saveBack = true;
|
_saveBack = true;
|
||||||
_drawTextPermFlag = false;
|
|
||||||
_clipPtr = NULL;
|
_clipPtr = NULL;
|
||||||
_viewPortListPtr = NULL;
|
_viewPortListPtr = NULL;
|
||||||
_backgroundPage = NULL;
|
_backgroundPage = NULL;
|
||||||
@ -71,8 +63,6 @@ GraphicsManager::~GraphicsManager() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void GraphicsManager::setupMCGASaveRect(ViewPortResource *viewPort) {
|
void GraphicsManager::setupMCGASaveRect(ViewPortResource *viewPort) {
|
||||||
_MCGAMode = true;
|
|
||||||
|
|
||||||
if (viewPort->_activePage) {
|
if (viewPort->_activePage) {
|
||||||
viewPort->_activePage->_flags |= 1;
|
viewPort->_activePage->_flags |= 1;
|
||||||
Common::Rect *clipRect = _clipPtr;
|
Common::Rect *clipRect = _clipPtr;
|
||||||
@ -252,10 +242,9 @@ void GraphicsManager::sDrawPic(DisplayResource *srcDisplay, DisplayResource *des
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (srcFlags & DISPFLAG_1000) {
|
if (srcFlags & DISPFLAG_1000) {
|
||||||
srcImgData = srcPic->_imgData + (var4C << 14) + _screenOffset;
|
srcImgData = srcPic->_imgData + (var4C << 14);
|
||||||
for (uint idx = 0; idx < srcPic->_maskData; ++idx) {
|
for (uint idx = 0; idx < srcPic->_maskData; ++idx) {
|
||||||
if (var4C < 4) {
|
if (var4C < 4) {
|
||||||
EMSMapPageHandle(srcPic->_planeSize, srcPic->_imgData[idx], var4C);
|
|
||||||
++var4C;
|
++var4C;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -263,10 +252,9 @@ void GraphicsManager::sDrawPic(DisplayResource *srcDisplay, DisplayResource *des
|
|||||||
srcImgData = srcPic->_imgData;
|
srcImgData = srcPic->_imgData;
|
||||||
}
|
}
|
||||||
if (destFlags & DISPFLAG_1000) {
|
if (destFlags & DISPFLAG_1000) {
|
||||||
destImgData = destPic->_imgData + (var4C << 14) + _screenOffset;
|
destImgData = destPic->_imgData + (var4C << 14);
|
||||||
for (uint idx = 0; idx < srcPic->_maskData; ++idx) {
|
for (uint idx = 0; idx < srcPic->_maskData; ++idx) {
|
||||||
if (var4C < 4) {
|
if (var4C < 4) {
|
||||||
EMSMapPageHandle(destPic->_planeSize, destPic->_imgData[idx], var4C);
|
|
||||||
++var4C;
|
++var4C;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -274,7 +262,6 @@ void GraphicsManager::sDrawPic(DisplayResource *srcDisplay, DisplayResource *des
|
|||||||
destImgData = destPic->_imgData;
|
destImgData = destPic->_imgData;
|
||||||
}
|
}
|
||||||
|
|
||||||
_SVGAPage = _SVGAReset;
|
|
||||||
if (srcPic->_select != 0xff)
|
if (srcPic->_select != 0xff)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -50,9 +50,8 @@ class DrawInfo {
|
|||||||
public:
|
public:
|
||||||
int _penColor;
|
int _penColor;
|
||||||
Common::Point _pos;
|
Common::Point _pos;
|
||||||
int _flags;
|
|
||||||
public:
|
public:
|
||||||
DrawInfo(int penColor, const Common::Point &pos, int flags);
|
DrawInfo(int penColor, const Common::Point &pos);
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef void (GraphicsManager::*GraphicMethodPtr)();
|
typedef void (GraphicsManager::*GraphicMethodPtr)();
|
||||||
@ -63,32 +62,21 @@ typedef void (GraphicsManager::*ViewPortRestorePtr)(ViewPortResource *);
|
|||||||
class GraphicsManager {
|
class GraphicsManager {
|
||||||
public:
|
public:
|
||||||
VoyeurEngine *_vm;
|
VoyeurEngine *_vm;
|
||||||
bool _palFlag;
|
|
||||||
byte _VGAColors[PALETTE_SIZE];
|
byte _VGAColors[PALETTE_SIZE];
|
||||||
Common::Array<byte *> _colorChain;
|
|
||||||
PictureResource *_backgroundPage;
|
PictureResource *_backgroundPage;
|
||||||
int _SVGAPage;
|
|
||||||
int _SVGAMode;
|
int _SVGAMode;
|
||||||
int _SVGAReset;
|
|
||||||
ViewPortListResource *_viewPortListPtr;
|
ViewPortListResource *_viewPortListPtr;
|
||||||
ViewPortResource **_vPort;
|
ViewPortResource **_vPort;
|
||||||
bool _MCGAMode;
|
|
||||||
bool _saveBack;
|
bool _saveBack;
|
||||||
Common::Rect *_clipPtr;
|
Common::Rect *_clipPtr;
|
||||||
int _screenOffset;
|
|
||||||
uint _planeSelect;
|
uint _planeSelect;
|
||||||
int _sImageShift;
|
|
||||||
Graphics::Surface _screenSurface;
|
Graphics::Surface _screenSurface;
|
||||||
CMapResource *_backColors;
|
CMapResource *_backColors;
|
||||||
FontInfoResource *_fontPtr;
|
FontInfoResource *_fontPtr;
|
||||||
PictureResource *_fontChar;
|
PictureResource *_fontChar;
|
||||||
DrawInfo *_drawPtr;
|
DrawInfo *_drawPtr;
|
||||||
DrawInfo _defaultDrawInfo;
|
DrawInfo _defaultDrawInfo;
|
||||||
bool _drawTextPermFlag;
|
|
||||||
private:
|
private:
|
||||||
static void fadeIntFunc();
|
|
||||||
static void vDoCycleInt();
|
|
||||||
|
|
||||||
void restoreBack(Common::Array<Common::Rect> &rectList, int rectListCount,
|
void restoreBack(Common::Array<Common::Rect> &rectList, int rectListCount,
|
||||||
PictureResource *srcPic, PictureResource *destPic);
|
PictureResource *srcPic, PictureResource *destPic);
|
||||||
public:
|
public:
|
||||||
@ -116,7 +104,7 @@ public:
|
|||||||
void setColors(int start, int count, const byte *pal);
|
void setColors(int start, int count, const byte *pal);
|
||||||
void screenReset();
|
void screenReset();
|
||||||
void fadeDownICF1(int steps);
|
void fadeDownICF1(int steps);
|
||||||
void fadeUpICF1(int steps);
|
void fadeUpICF1(int steps = 0);
|
||||||
void fadeDownICF(int steps);
|
void fadeDownICF(int steps);
|
||||||
void drawDot();
|
void drawDot();
|
||||||
|
|
||||||
@ -124,9 +112,6 @@ public:
|
|||||||
* Synchronizes the game data
|
* Synchronizes the game data
|
||||||
*/
|
*/
|
||||||
void synchronize(Common::Serializer &s);
|
void synchronize(Common::Serializer &s);
|
||||||
|
|
||||||
// Methods in the original that are stubbed in ScummVM
|
|
||||||
void EMSMapPageHandle(int v1, int v2, int v3) {}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
} // End of namespace Voyeur
|
} // End of namespace Voyeur
|
||||||
|
Loading…
Reference in New Issue
Block a user