mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-18 07:53:12 +00:00
TOLTECS: Take advantage of Surface::getPixels.
This commit is contained in:
parent
2977ff8ba0
commit
863ead081d
@ -69,7 +69,7 @@ int MenuSystem::run(MenuID menuId) {
|
||||
_vm->_screen->blastSprite(0x140 + _vm->_cameraX, 0x175 + _vm->_cameraY, 0, 1, 0x4000);
|
||||
shadeRect(60, 39, 520, 247, 225, 229);
|
||||
|
||||
memcpy(_background->getBasePtr(0, 0), _vm->_screen->_frontScreen, 640 * 400);
|
||||
memcpy(_background->getPixels(), _vm->_screen->_frontScreen, 640 * 400);
|
||||
|
||||
while (_running) {
|
||||
update();
|
||||
@ -229,7 +229,7 @@ void MenuSystem::initMenu(MenuID menuID) {
|
||||
|
||||
_items.clear();
|
||||
|
||||
memcpy(_vm->_screen->_frontScreen, _background->getBasePtr(0, 0), 640 * 400);
|
||||
memcpy(_vm->_screen->_frontScreen, _background->getPixels(), 640 * 400);
|
||||
|
||||
switch (menuID) {
|
||||
case kMenuIdMain:
|
||||
|
@ -651,7 +651,7 @@ void Screen::drawSurface(int16 x, int16 y, Graphics::Surface *surface) {
|
||||
int16 skipX = 0;
|
||||
int16 width = surface->w;
|
||||
int16 height = surface->h;
|
||||
byte *surfacePixels = (byte *)surface->getBasePtr(0, 0);
|
||||
byte *surfacePixels = (byte *)surface->getPixels();
|
||||
byte *frontScreen;
|
||||
|
||||
// Not on screen, skip
|
||||
|
@ -373,7 +373,7 @@ void SegmentMap::loadSegmapMaskRectSurface(byte *maskData, SegmapMaskRect &maskR
|
||||
maskRect.surface->create(maskRect.width, maskRect.height, Graphics::PixelFormat::createFormatCLUT8());
|
||||
|
||||
byte *backScreen = _vm->_screen->_backScreen + maskRect.x + (maskRect.y * _vm->_sceneWidth);
|
||||
byte *dest = (byte *)maskRect.surface->getBasePtr(0, 0);
|
||||
byte *dest = (byte *)maskRect.surface->getPixels();
|
||||
|
||||
for (int16 h = 0; h < maskRect.height; h++) {
|
||||
int16 w = maskRect.width;
|
||||
|
Loading…
x
Reference in New Issue
Block a user