windows: fixup filter compilation with gcc #3414832

From rogerman
This commit is contained in:
riccardom 2011-10-04 17:23:23 +00:00
parent b7ba91a0b9
commit d6525883d9
3 changed files with 5 additions and 12 deletions

View File

@ -3,11 +3,6 @@
//ref: http://vba-rerecording.googlecode.com/svn/trunk/src/2xsai.cpp //ref: http://vba-rerecording.googlecode.com/svn/trunk/src/2xsai.cpp
typedef unsigned char u8;
typedef unsigned short u16;
typedef unsigned int u32;
typedef int s32;
static u32 colorMask = 0xfefefe; static u32 colorMask = 0xfefefe;
static u32 lowPixelMask = 0x010101; static u32 lowPixelMask = 0x010101;
static u32 qcolorMask = 0xfcfcfc; static u32 qcolorMask = 0xfcfcfc;
@ -1184,4 +1179,4 @@ void RenderSuperEagle (SSurface Src, SSurface Dst)
lpSrc, lpSrc,
lpDst, Dst.Pitch*2, Src.Width, Src.Height); lpDst, Dst.Pitch*2, Src.Width, Src.Height);
} }

View File

@ -16,12 +16,12 @@ along with the this software. If not, see <http://www.gnu.org/licenses/>.
*/ */
struct SSurface { typedef struct {
unsigned char *Surface; unsigned char *Surface;
unsigned int Pitch; unsigned int Pitch;
unsigned int Width, Height; unsigned int Width, Height;
}; } SSurface;
void RenderNearest2X (SSurface Src, SSurface Dst); void RenderNearest2X (SSurface Src, SSurface Dst);
void RenderLQ2X (SSurface Src, SSurface Dst); void RenderLQ2X (SSurface Src, SSurface Dst);

View File

@ -31,9 +31,7 @@
#ifndef __INTERP_H #ifndef __INTERP_H
#define __INTERP_H #define __INTERP_H
typedef unsigned char u8; #include "types.h"
typedef unsigned short u16;
typedef unsigned int u32;
/***************************************************************************/ /***************************************************************************/
/* Basic types */ /* Basic types */
@ -278,7 +276,7 @@ static int interp_32_diff(u32 p1, u32 p2)
#define INTERP_LIMIT2 (96000) #define INTERP_LIMIT2 (96000)
//#define ABS(x) ((x) < 0 ? -(x) : (x)) //#define ABS(x) ((x) < 0 ? -(x) : (x))
static __forceinline unsigned int ABS(int x) { return (x+(x>>31))^(x>>31); } // faster static FORCEINLINE u32 ABS(s32 x) { return (x+(x>>31))^(x>>31); } // faster
#define MAX(x,y) ((x) > (y) ? (x) : (y)) #define MAX(x,y) ((x) > (y) ? (x) : (y))
#define MIN(x,y) ((x) < (y) ? (x) : (y)) #define MIN(x,y) ((x) < (y) ? (x) : (y))
// //