From 4bd05071e511c077811040c7c746d1c5f8e8c3f8 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Sat, 4 Sep 2004 01:31:04 +0000 Subject: Got rid of OSystem::move_screen svn-id: r14882 --- backends/gp32/gp32.cpp | 38 -------------------------------------- backends/gp32/gp32.h | 4 ---- 2 files changed, 42 deletions(-) (limited to 'backends/gp32') diff --git a/backends/gp32/gp32.cpp b/backends/gp32/gp32.cpp index 5a636a38da..3451aa69e0 100644 --- a/backends/gp32/gp32.cpp +++ b/backends/gp32/gp32.cpp @@ -350,44 +350,6 @@ int SDL_SetColors(SDL_Surface *surface, SDL_Color *colors, int firstcolor, int n return 1; } -// Moves the screen content around by the given amount of pixels -// but only the top height pixel rows, the rest stays untouched -void OSystem_GP32::move_screen(int dx, int dy, int height) { - if ((dx == 0) && (dy == 0)) - return; - - if (dx == 0) { - // vertical movement - if (dy > 0) { - // move down - // copy from bottom to top - for (int y = height - 1; y >= dy; y--) - copyRectToScreen((byte *)_screen->pixels + _screenWidth * (y - dy), _screenWidth, 0, y, _screenWidth, 1); - } else { - // move up - // copy from top to bottom - for (int y = 0; y < height + dx; y++) - copyRectToScreen((byte *)_screen->pixels + _screenWidth * (y - dy), _screenWidth, 0, y, _screenWidth, 1); - } - } else if (dy == 0) { - // horizontal movement - if (dx > 0) { - // move right - // copy from right to left - for (int x = _screenWidth - 1; x >= dx; x--) - copyRectToScreen((byte *)_screen->pixels + x - dx, _screenWidth, x, 0, 1, height); - } else { - // move left - // copy from left to right - for (int x = 0; x < _screenWidth; x++) - copyRectToScreen((byte *)_screen->pixels + x - dx, _screenWidth, x, 0, 1, height); - } - } else { - // free movement - // not necessary for now - } -} - void OSystem_GP32::load_gfx_mode() { GpRectFill(NULL,&gpDraw[GAME_SURFACE], 0, 0, 320, 240, 0); //black border diff --git a/backends/gp32/gp32.h b/backends/gp32/gp32.h index 80b3160673..fbb0253773 100644 --- a/backends/gp32/gp32.h +++ b/backends/gp32/gp32.h @@ -47,10 +47,6 @@ public: // The screen will not be updated to reflect the new bitmap void copyRectToScreen(const byte *buf, int pitch, int x, int y, int w, int h); - // Moves the screen content around by the given amount of pixels - // but only the top height pixel rows, the rest stays untouched - void move_screen(int dx, int dy, int height); - // Update the dirty areas of the screen void updateScreen(); -- cgit v1.2.3