From cae3dc04a2db3de692c18e9ff05663def5112c34 Mon Sep 17 00:00:00 2001 From: spacy51 Date: Sun, 20 Jan 2008 20:15:10 +0000 Subject: [PATCH] Resource file cleanup. Remove reference to non-existent InterlaceIB function. Removed non-IFB MotionBlur. --- VBA.vcproj | 4 - src/motionblur.cpp | 192 -------------------------------------------- src/sdl/filters.cpp | 3 - src/win32/VBA.cpp | 3 - src/win32/VBA.rc | 35 -------- 5 files changed, 237 deletions(-) delete mode 100644 src/motionblur.cpp diff --git a/VBA.vcproj b/VBA.vcproj index bd2f8c7d..1e757683 100644 --- a/VBA.vcproj +++ b/VBA.vcproj @@ -573,10 +573,6 @@ RelativePath=".\src\interframe.cpp" > - - diff --git a/src/motionblur.cpp b/src/motionblur.cpp deleted file mode 100644 index 4248363c..00000000 --- a/src/motionblur.cpp +++ /dev/null @@ -1,192 +0,0 @@ -// VisualBoyAdvance - Nintendo Gameboy/GameboyAdvance (TM) emulator. -// Copyright (C) 1999-2003 Forgotten -// Copyright (C) 2004 Forgotten and the VBA development team - -// This program is free software; you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation; either version 2, or(at your option) -// any later version. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with this program; if not, write to the Free Software Foundation, -// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - -#include "System.h" - -extern int RGB_LOW_BITS_MASK; - -void MotionBlur(u8 *srcPtr, u32 srcPitch, u8 *deltaPtr, - u8 *dstPtr, u32 dstPitch, int width, int height) -{ - u8 *nextLine, *finish; - u32 colorMask = ~(RGB_LOW_BITS_MASK | (RGB_LOW_BITS_MASK << 16)); - u32 lowPixelMask = RGB_LOW_BITS_MASK; - - nextLine = dstPtr + dstPitch; - - do { - u32 *bP = (u32 *) srcPtr; - u32 *xP = (u32 *) deltaPtr; - u32 *dP = (u32 *) dstPtr; - u32 *nL = (u32 *) nextLine; - u32 currentPixel; - u32 nextPixel; - u32 currentDelta; - u32 nextDelta; - - finish = (u8 *) bP + ((width+2) << 1); - nextPixel = *bP++; - nextDelta = *xP++; - - do { - currentPixel = nextPixel; - currentDelta = nextDelta; - nextPixel = *bP++; - nextDelta = *xP++; - - if(currentPixel != currentDelta) { - u32 colorA, product, colorB; - - *(xP - 2) = currentPixel; -#ifdef WORDS_BIGENDIAN - colorA = currentPixel >> 16; - colorB = currentDelta >> 16; -#else - colorA = currentPixel & 0xffff; - colorB = currentDelta & 0xffff; -#endif - - product = ((((colorA & colorMask) >> 1) + - ((colorB & colorMask) >> 1) + - (colorA & colorB & lowPixelMask))); - - *(dP) = product | product << 16; - *(nL) = product | product << 16; - -#ifdef WORDS_BIGENDIAN - colorA = (currentPixel & 0xffff); - colorB = (currentDelta & 0xffff); -#else - colorA = currentPixel >> 16; - colorB = currentDelta >> 16; -#endif - product = ((((colorA & colorMask) >> 1) + - ((colorB & colorMask) >> 1) + - (colorA & colorB & lowPixelMask))); - - *(dP + 1) = product | product << 16; - *(nL + 1) = product | product << 16; - } else { - u32 colorA, product; - - *(xP - 2) = currentPixel; -#ifdef WORDS_BIGENDIAN - colorA = currentPixel >> 16; -#else - colorA = currentPixel & 0xffff; -#endif - - product = colorA; - - *(dP) = product | product << 16; - *(nL) = product | product << 16; -#ifdef WORDS_BIGENDIAN - colorA = (currentPixel & 0xffff); -#else - colorA = currentPixel >> 16; -#endif - product = colorA; - - *(dP + 1) = product | product << 16; - *(nL + 1) = product | product << 16; - } - - dP += 2; - nL += 2; - } while ((u8 *) bP < finish); - - deltaPtr += srcPitch; - srcPtr += srcPitch; - dstPtr += dstPitch << 1; - nextLine += dstPitch << 1; - } - while (--height); -} - -void MotionBlur32(u8 *srcPtr, u32 srcPitch, u8 *deltaPtr, - u8 *dstPtr, u32 dstPitch, int width, int height) -{ - u8 *nextLine, *finish; - u32 colorMask = ~RGB_LOW_BITS_MASK; - u32 lowPixelMask = RGB_LOW_BITS_MASK; - - nextLine = dstPtr + dstPitch; - - do { - u32 *bP = (u32 *) srcPtr; - u32 *xP = (u32 *) deltaPtr; - u32 *dP = (u32 *) dstPtr; - u32 *nL = (u32 *) nextLine; - u32 currentPixel; - u32 nextPixel; - u32 currentDelta; - u32 nextDelta; - - finish = (u8 *) bP + ((width+1) << 2); - nextPixel = *bP++; - nextDelta = *xP++; - - do { - currentPixel = nextPixel; - currentDelta = nextDelta; - nextPixel = *bP++; - nextDelta = *xP++; - - u32 colorA, product, colorB; - - *(xP - 2) = currentPixel; - colorA = currentPixel; - colorB = currentDelta; - - product = ((((colorA & colorMask) >> 1) + - ((colorB & colorMask) >> 1) + - (colorA & colorB & lowPixelMask))); - - *(dP) = product; - *(dP+1) = product; - *(nL) = product; - *(nL+1) = product; - - *(xP - 1) = nextPixel; - - colorA = nextPixel; - colorB = nextDelta; - - product = ((((colorA & colorMask) >> 1) + - ((colorB & colorMask) >> 1) + - (colorA & colorB & lowPixelMask))); - - *(dP + 2) = product; - *(dP + 3) = product; - *(nL + 2) = product; - *(nL + 3) = product; - - nextPixel = *bP++; - nextDelta = *xP++; - - dP += 4; - nL += 4; - } while ((u8 *) bP < finish); - - deltaPtr += srcPitch; - srcPtr += srcPitch; - dstPtr += dstPitch << 1; - nextLine += dstPitch << 1; - } - while (--height); -} diff --git a/src/sdl/filters.cpp b/src/sdl/filters.cpp index e67203d2..6a4131f8 100644 --- a/src/sdl/filters.cpp +++ b/src/sdl/filters.cpp @@ -34,8 +34,6 @@ extern void SuperEagle(u8*,u32,u8*,u8*,u32,int,int); extern void SuperEagle32(u8*,u32,u8*,u8*,u32,int,int); extern void Pixelate(u8*,u32,u8*,u8*,u32,int,int); extern void Pixelate32(u8*,u32,u8*,u8*,u32,int,int); -extern void MotionBlur(u8*,u32,u8*,u8*,u32,int,int); -extern void MotionBlur32(u8*,u32,u8*,u8*,u32,int,int); extern void AdMame2x(u8*,u32,u8*,u8*,u32,int,int); extern void AdMame2x32(u8*,u32,u8*,u8*,u32,int,int); extern void Bilinear(u8*,u32,u8*,u8*,u32,int,int); @@ -70,7 +68,6 @@ const FilterDesc Filters[] = { { "Super 2xSaI", 2, Super2xSaI, 0, Super2xSaI32 }, { "Super Eagle", 2, SuperEagle, 0, SuperEagle32 }, { "Pixelate", 2, Pixelate, 0, Pixelate32 }, - { "Motion Blur", 2, MotionBlur, 0, MotionBlur32 }, { "AdvanceMAME Scale2x", 2, AdMame2x, 0, AdMame2x32 }, { "Bilinear", 2, Bilinear, 0, Bilinear32 }, { "Bilinear Plus", 2, BilinearPlus, 0, BilinearPlus32 }, diff --git a/src/win32/VBA.cpp b/src/win32/VBA.cpp index 82e0570c..75a8117f 100644 --- a/src/win32/VBA.cpp +++ b/src/win32/VBA.cpp @@ -60,8 +60,6 @@ extern void Pixelate(u8*,u32,u8*,u8*,u32,int,int); extern void Pixelate32(u8*,u32,u8*,u8*,u32,int,int); -extern void MotionBlur(u8*,u32,u8*,u8*,u32,int,int); -extern void MotionBlur32(u8*,u32,u8*,u8*,u32,int,int); extern void _2xSaI(u8*,u32,u8*,u8*,u32,int,int); extern void _2xSaI32(u8*,u32,u8*,u8*,u32,int,int); extern void Super2xSaI(u8*,u32,u8*,u8*,u32,int,int); @@ -96,7 +94,6 @@ extern void hq4x32(u8*,u32,u8*,u8*,u32,int,int); extern void SmartIB(u8*,u32,int,int); extern void SmartIB32(u8*,u32,int,int); extern void MotionBlurIB(u8*,u32,int,int); -extern void InterlaceIB(u8*,u32,int,int); extern void MotionBlurIB32(u8*,u32,int,int); extern IDisplay *newGDIDisplay(); diff --git a/src/win32/VBA.rc b/src/win32/VBA.rc index 48f7dc43..0a98daa5 100644 --- a/src/win32/VBA.rc +++ b/src/win32/VBA.rc @@ -12,41 +12,6 @@ ///////////////////////////////////////////////////////////////////////////// #undef APSTUDIO_READONLY_SYMBOLS -///////////////////////////////////////////////////////////////////////////// -// German (Germany) resources - -#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_DEU) -#ifdef _WIN32 -LANGUAGE LANG_GERMAN, SUBLANG_GERMAN -#pragma code_page(1252) -#endif //_WIN32 - -#ifdef APSTUDIO_INVOKED -///////////////////////////////////////////////////////////////////////////// -// -// TEXTINCLUDE -// - -1 TEXTINCLUDE -BEGIN - "resource.\0" -END - -3 TEXTINCLUDE -BEGIN - "\r\0" -END - -2 TEXTINCLUDE -BEGIN - "#include ""afxres.h""\r\0" -END - -#endif // APSTUDIO_INVOKED - -#endif // German (Germany) resources -///////////////////////////////////////////////////////////////////////////// - ///////////////////////////////////////////////////////////////////////////// // English (U.S.) resources