Plugins: In ZegoGS, convert FASTCALL to __fastcall, since it's in the new headers. Turn two #defines into functions. Adjust #includes and makefiles as suggested by Jake on all plugins.

git-svn-id: http://pcsx2-playground.googlecode.com/svn/trunk@554 a6443dda-0b58-4228-96e9-037be469359c
This commit is contained in:
arcum42 2009-01-05 13:39:59 +00:00 committed by Gregory Hainaut
parent fb183df3c1
commit eeb1ddca65
15 changed files with 276 additions and 275 deletions

View File

@ -21,7 +21,7 @@
#pragma warning(disable:4018)
#endif
#include "../../common/PS2Edefs.h"
#include "PS2Edefs.h"
#include "libiso.h"
#ifdef __cplusplus

View File

@ -9,7 +9,7 @@ OBJS = ../CDVDisop.o Config.o Linux.o ../libiso.o
CFGOBJS = conf.o interface.o support.o ${OBJS}
LIBS = -lz -lbz2 -lstdc++
CFGLIBS = $(shell pkg-config --libs gtk+-2.0) ${LIBS}
CFLAGS += $(shell pkg-config --cflags gtk+-2.0)
CFLAGS += $(shell pkg-config --cflags gtk+-2.0) -I../../../common
DEPS:= $(OBJS:.o=.d) $(CFGOBJS:.o=.d)
all: plugin cfg
@ -30,4 +30,4 @@ clean:
%.o: %.c
${CC} ${CFLAGS} -c -o $@ $< -MD -MF $(patsubst %.o,%.d,$@)
-include ${DEPS}
-include ${DEPS}

View File

@ -319,15 +319,15 @@ extern u8* g_pBasePS2Mem;
//
// GIFTag
REG128(GIFTag)
UINT32 NLOOP:15;
UINT32 EOP:1;
UINT32 _PAD1:16;
UINT32 _PAD2:14;
UINT32 PRE:1;
UINT32 PRIM:11;
UINT32 FLG:2; // enum GIF_FLG
UINT32 NREG:4;
UINT64 REGS:64;
u32 NLOOP:15;
u32 EOP:1;
u32 _PAD1:16;
u32 _PAD2:14;
u32 PRE:1;
u32 PRIM:11;
u32 FLG:2; // enum GIF_FLG
u32 NREG:4;
u64 REGS:64;
REG_END
typedef struct {

View File

@ -105,24 +105,29 @@ void __fastcall GIFPackedRegHandlerUV(u32* data)
gs.vertexregs.v = data[1] & 0x3fff;
}
#define KICK_VERTEX2() { \
if( ++gs.primC >= (int)g_primmult[prim->prim]) { \
if( !(g_GameSettings&GAME_XENOSPECHACK) || !ZeroGS::vb[prim->ctxt].zbuf.zmsk ) \
(*ZeroGS::drawfn[prim->prim])(); \
gs.primC -= g_primsub[prim->prim]; \
} \
} \
void __forceinline KICK_VERTEX2()
{
if (++gs.primC >= (int)g_primmult[prim->prim])
{
if (!(g_GameSettings&GAME_XENOSPECHACK) || !ZeroGS::vb[prim->ctxt].zbuf.zmsk)
(*ZeroGS::drawfn[prim->prim])();
gs.primC -= g_primsub[prim->prim];
}
}
#define KICK_VERTEX3() { \
if( ++gs.primC >= (int)g_primmult[prim->prim] ) { \
gs.primC -= g_primsub[prim->prim]; \
if( prim->prim == 5 ) { \
/* tri fans need special processing */ \
if( gs.nTriFanVert == gs.primIndex ) \
gs.primIndex = (gs.primIndex+1)%ARRAYSIZE(gs.gsvertex); \
} \
} \
} \
void __forceinline KICK_VERTEX3()
{
if (++gs.primC >= (int)g_primmult[prim->prim])
{
gs.primC -= g_primsub[prim->prim];
if (prim->prim == 5)
{
/* tri fans need special processing */
if (gs.nTriFanVert == gs.primIndex)
gs.primIndex = (gs.primIndex+1)%ARRAY_SIZE(gs.gsvertex);
}
}
}
void __fastcall GIFPackedRegHandlerXYZF2(u32* data)
{

View File

@ -26,7 +26,7 @@
// need C definitions
extern "C" {
#define GSdefs
#include "../../common/PS2Edefs.h"
#include "PS2Edefs.h"
}
#ifdef _WIN32
@ -135,18 +135,6 @@ extern GLWindow GLWin;
#endif // linux basic definitions
#if defined(_MSC_VER)
#define FASTCALL(fn) __fastcall fn
#else
#ifdef __x86_64
#define FASTCALL(fn) fn
#else
#define FASTCALL(fn) __attribute__((fastcall)) fn
#endif
#endif
struct Vector_16F
{
u16 x, y, z, w;
@ -446,14 +434,14 @@ typedef struct {
#define GSOPTION_LOADED 0x8000
typedef struct {
int interlace;
int aa; // antialiasing 0 - off, 1 - 2x, 2 - 4x
int bilinear; // set to enable bilinear support
u8 mrtdepth; // write color in render target
u8 interlace;
u8 aa; // antialiasing 0 - off, 1 - 2x, 2 - 4x
u8 bilinear; // set to enable bilinear support
u32 options;
u32 gamesettings; // default game settings
int width, height;
int winstyle; // window style before full screen
int mrtdepth; // write color in render target
#ifdef GS_LOG
u32 log;
#endif

View File

@ -2,5 +2,5 @@ noinst_LIBRARIES = libZeroGSLinux.a
libZeroGSLinux_a_CPPFLAGS = -fPIC
libZeroGSLinux_a_CXXFLAGS = -fPIC
libZeroGSLinux_a_CFLAGS = -fPIC
INCLUDES = $(shell pkg-config --cflags gtk+-2.0) -I../
INCLUDES = $(shell pkg-config --cflags gtk+-2.0) -I@srcdir@/../ -I@srcdir@/../../../common
libZeroGSLinux_a_SOURCES = callbacks.c Conf.cpp interface.c Linux.cpp support.c

View File

@ -1,6 +1,7 @@
# Create a shared library libZeroGSogl
AUTOMAKE_OPTIONS = foreign
noinst_LIBRARIES = libZeroGSogl.a
INCLUDES = -I@srcdir@/../../common
libZeroGSogl_a_CPPFLAGS = $(shell pkg-config --cflags gtk+-2.0)
libZeroGSogl_a_CXXFLAGS = $(shell pkg-config --cflags gtk+-2.0)

View File

@ -73,14 +73,14 @@ C_ASSERT(sizeof(g_GIFRegHandlers)/sizeof(g_GIFRegHandlers[0]) == 100 );
// values for keeping track of changes
u32 s_uTex1Data[2][2] = {0}, s_uClampData[2] = {0};
void FASTCALL(GIFPackedRegHandlerNull(u32* data))
void __fastcall GIFPackedRegHandlerNull(u32* data)
{
#ifdef _DEBUG
printf("Unexpected packed reg handler %8.8lx_%8.8lx %x\n", data[0], data[1], data[2]);
#endif
}
void FASTCALL(GIFPackedRegHandlerRGBA(u32* data))
void __fastcall GIFPackedRegHandlerRGBA(u32* data)
{
gs.rgba = (data[0] & 0xff) |
((data[1] & 0xff) << 8) |
@ -90,39 +90,44 @@ void FASTCALL(GIFPackedRegHandlerRGBA(u32* data))
gs.vertexregs.q = gs.q;
}
void FASTCALL(GIFPackedRegHandlerSTQ(u32* data))
void __fastcall GIFPackedRegHandlerSTQ(u32* data)
{
*(u32*)&gs.vertexregs.s = data[0]&0xffffff00;
*(u32*)&gs.vertexregs.t = data[1]&0xffffff00;
*(u32*)&gs.q = data[2];
}
void FASTCALL(GIFPackedRegHandlerUV(u32* data))
void __fastcall GIFPackedRegHandlerUV(u32* data)
{
gs.vertexregs.u = data[0] & 0x3fff;
gs.vertexregs.v = data[1] & 0x3fff;
}
#define KICK_VERTEX2() { \
if( ++gs.primC >= (int)g_primmult[prim->prim]) { \
if( !(g_GameSettings&GAME_XENOSPECHACK) || !ZeroGS::vb[prim->ctxt].zbuf.zmsk ) \
(*ZeroGS::drawfn[prim->prim])(); \
gs.primC -= g_primsub[prim->prim]; \
} \
} \
void __forceinline KICK_VERTEX2()
{
if (++gs.primC >= (int)g_primmult[prim->prim])
{
if (!(g_GameSettings&GAME_XENOSPECHACK) || !ZeroGS::vb[prim->ctxt].zbuf.zmsk)
(*ZeroGS::drawfn[prim->prim])();
gs.primC -= g_primsub[prim->prim];
}
}
#define KICK_VERTEX3() { \
if( ++gs.primC >= (int)g_primmult[prim->prim] ) { \
gs.primC -= g_primsub[prim->prim]; \
if( prim->prim == 5 ) { \
/* tri fans need special processing */ \
if( gs.nTriFanVert == gs.primIndex ) \
gs.primIndex = (gs.primIndex+1)%ARRAY_SIZE(gs.gsvertex); \
} \
} \
} \
void __forceinline KICK_VERTEX3()
{
if (++gs.primC >= (int)g_primmult[prim->prim])
{
gs.primC -= g_primsub[prim->prim];
if (prim->prim == 5)
{
/* tri fans need special processing */
if (gs.nTriFanVert == gs.primIndex)
gs.primIndex = (gs.primIndex+1)%ARRAY_SIZE(gs.gsvertex);
}
}
}
void FASTCALL(GIFPackedRegHandlerXYZF2(u32* data))
void __fastcall GIFPackedRegHandlerXYZF2(u32* data)
{
gs.vertexregs.x = (data[0] >> 0) & 0xffff;
gs.vertexregs.y = (data[1] >> 0) & 0xffff;
@ -139,7 +144,7 @@ void FASTCALL(GIFPackedRegHandlerXYZF2(u32* data))
}
}
void FASTCALL(GIFPackedRegHandlerXYZ2(u32* data))
void __fastcall GIFPackedRegHandlerXYZ2(u32* data)
{
gs.vertexregs.x = (data[0] >> 0) & 0xffff;
gs.vertexregs.y = (data[1] >> 0) & 0xffff;
@ -155,12 +160,12 @@ void FASTCALL(GIFPackedRegHandlerXYZ2(u32* data))
}
}
void FASTCALL(GIFPackedRegHandlerFOG(u32* data))
void __fastcall GIFPackedRegHandlerFOG(u32* data)
{
gs.vertexregs.f = (data[3]&0xff0)>>4;
}
void FASTCALL(GIFPackedRegHandlerA_D(u32* data))
void __fastcall GIFPackedRegHandlerA_D(u32* data)
{
if((data[2] & 0xff) < 100)
g_GIFRegHandlers[data[2] & 0xff](data);
@ -168,7 +173,7 @@ void FASTCALL(GIFPackedRegHandlerA_D(u32* data))
GIFRegHandlerNull(data);
}
void FASTCALL(GIFPackedRegHandlerNOP(u32* data))
void __fastcall GIFPackedRegHandlerNOP(u32* data)
{
}
@ -358,7 +363,7 @@ __forceinline void clampWrite(int i, u32 *data)
}
}
void FASTCALL(GIFRegHandlerNull(u32* data))
void __fastcall GIFRegHandlerNull(u32* data)
{
#ifdef _DEBUG
if( (((uptr)&data[2])&0xffff) == 0 )
@ -371,7 +376,7 @@ void FASTCALL(GIFRegHandlerNull(u32* data))
#endif
}
void FASTCALL(GIFRegHandlerPRIM(u32 *data))
void __fastcall GIFRegHandlerPRIM(u32 *data)
{
if (data[0] & ~0x3ff) {
#ifdef WARN_LOG
@ -389,27 +394,27 @@ void FASTCALL(GIFRegHandlerPRIM(u32 *data))
ZeroGS::Prim();
}
void FASTCALL(GIFRegHandlerRGBAQ(u32* data))
void __fastcall GIFRegHandlerRGBAQ(u32* data)
{
gs.rgba = data[0];
gs.vertexregs.rgba = data[0];
*(u32*)&gs.vertexregs.q = data[1];
}
void FASTCALL(GIFRegHandlerST(u32* data))
void __fastcall GIFRegHandlerST(u32* data)
{
*(u32*)&gs.vertexregs.s = data[0]&0xffffff00;
*(u32*)&gs.vertexregs.t = data[1]&0xffffff00;
//*(u32*)&gs.q = data[2];
}
void FASTCALL(GIFRegHandlerUV(u32* data))
void __fastcall GIFRegHandlerUV(u32* data)
{
gs.vertexregs.u = (data[0]) & 0x3fff;
gs.vertexregs.v = (data[0] >> 16) & 0x3fff;
}
void FASTCALL(GIFRegHandlerXYZF2(u32* data))
void __fastcall GIFRegHandlerXYZF2(u32* data)
{
gs.vertexregs.x = (data[0]) & 0xffff;
gs.vertexregs.y = (data[0] >> (16)) & 0xffff;
@ -421,7 +426,7 @@ void FASTCALL(GIFRegHandlerXYZF2(u32* data))
KICK_VERTEX2();
}
void FASTCALL(GIFRegHandlerXYZ2(u32* data))
void __fastcall GIFRegHandlerXYZ2(u32* data)
{
gs.vertexregs.x = (data[0]) & 0xffff;
gs.vertexregs.y = (data[0] >> (16)) & 0xffff;
@ -432,7 +437,7 @@ void FASTCALL(GIFRegHandlerXYZ2(u32* data))
KICK_VERTEX2();
}
void FASTCALL(GIFRegHandlerTEX0_1(u32* data))
void __fastcall GIFRegHandlerTEX0_1(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[0].zbuf.zmsk ) {
return;
@ -440,7 +445,7 @@ void FASTCALL(GIFRegHandlerTEX0_1(u32* data))
tex0Write(0, data);
}
void FASTCALL(GIFRegHandlerTEX0_2(u32* data))
void __fastcall GIFRegHandlerTEX0_2(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[1].zbuf.zmsk ) {
return;
@ -448,7 +453,7 @@ void FASTCALL(GIFRegHandlerTEX0_2(u32* data))
tex0Write(1, data);
}
void FASTCALL(GIFRegHandlerCLAMP_1(u32* data))
void __fastcall GIFRegHandlerCLAMP_1(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[0].zbuf.zmsk ) {
return;
@ -456,7 +461,7 @@ void FASTCALL(GIFRegHandlerCLAMP_1(u32* data))
clampWrite(0, data);
}
void FASTCALL(GIFRegHandlerCLAMP_2(u32* data))
void __fastcall GIFRegHandlerCLAMP_2(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[1].zbuf.zmsk ) {
return;
@ -464,13 +469,13 @@ void FASTCALL(GIFRegHandlerCLAMP_2(u32* data))
clampWrite(1, data);
}
void FASTCALL(GIFRegHandlerFOG(u32* data))
void __fastcall GIFRegHandlerFOG(u32* data)
{
//gs.gsvertex[gs.primIndex].f = (data[1] >> 24); // shift to upper bits
gs.vertexregs.f = data[1]>>24;
}
void FASTCALL(GIFRegHandlerXYZF3(u32* data))
void __fastcall GIFRegHandlerXYZF3(u32* data)
{
gs.vertexregs.x = (data[0]) & 0xffff;
gs.vertexregs.y = (data[0] >> (16)) & 0xffff;
@ -482,7 +487,7 @@ void FASTCALL(GIFRegHandlerXYZF3(u32* data))
KICK_VERTEX3();
}
void FASTCALL(GIFRegHandlerXYZ3(u32* data))
void __fastcall GIFRegHandlerXYZ3(u32* data)
{
gs.vertexregs.x = (data[0]) & 0xffff;
gs.vertexregs.y = (data[0] >> (16)) & 0xffff;
@ -493,7 +498,7 @@ void FASTCALL(GIFRegHandlerXYZ3(u32* data))
KICK_VERTEX3();
}
void FASTCALL(GIFRegHandlerNOP(u32* data))
void __fastcall GIFRegHandlerNOP(u32* data)
{
}
@ -514,7 +519,7 @@ void tex1Write(int i, u32* data)
tex1.k = (data[1] >> 4) & 0xff;
}
void FASTCALL(GIFRegHandlerTEX1_1(u32* data))
void __fastcall GIFRegHandlerTEX1_1(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[0].zbuf.zmsk ) {
return;
@ -523,7 +528,7 @@ void FASTCALL(GIFRegHandlerTEX1_1(u32* data))
tex1Write(0, data);
}
void FASTCALL(GIFRegHandlerTEX1_2(u32* data))
void __fastcall GIFRegHandlerTEX1_2(u32* data)
{
if( (g_GameSettings&GAME_XENOSPECHACK) && ZeroGS::vb[1].zbuf.zmsk )
return;
@ -531,17 +536,17 @@ void FASTCALL(GIFRegHandlerTEX1_2(u32* data))
tex1Write(1, data);
}
void FASTCALL(GIFRegHandlerTEX2_1(u32* data))
void __fastcall GIFRegHandlerTEX2_1(u32* data)
{
tex2Write(0, data);
}
void FASTCALL(GIFRegHandlerTEX2_2(u32* data))
void __fastcall GIFRegHandlerTEX2_2(u32* data)
{
tex2Write(1, data);
}
void FASTCALL(GIFRegHandlerXYOFFSET_1(u32* data))
void __fastcall GIFRegHandlerXYOFFSET_1(u32* data)
{
// eliminator low 4 bits for now
ZeroGS::vb[0].offset.x = (data[0]) & 0xffff;
@ -553,7 +558,7 @@ void FASTCALL(GIFRegHandlerXYOFFSET_1(u32* data))
// }
}
void FASTCALL(GIFRegHandlerXYOFFSET_2(u32* data))
void __fastcall GIFRegHandlerXYOFFSET_2(u32* data)
{
ZeroGS::vb[1].offset.x = (data[0]) & 0xffff;
ZeroGS::vb[1].offset.y = (data[1]) & 0xffff;
@ -564,7 +569,7 @@ void FASTCALL(GIFRegHandlerXYOFFSET_2(u32* data))
// }
}
void FASTCALL(GIFRegHandlerPRMODECONT(u32* data))
void __fastcall GIFRegHandlerPRMODECONT(u32* data)
{
gs.prac = data[0] & 0x1;
prim = &gs._prim[gs.prac];
@ -572,7 +577,7 @@ void FASTCALL(GIFRegHandlerPRMODECONT(u32* data))
ZeroGS::Prim();
}
void FASTCALL(GIFRegHandlerPRMODE(u32* data))
void __fastcall GIFRegHandlerPRMODE(u32* data)
{
gs._prim[0]._val = (data[0]>>3)&0xff;
@ -580,7 +585,7 @@ void FASTCALL(GIFRegHandlerPRMODE(u32* data))
ZeroGS::Prim();
}
void FASTCALL(GIFRegHandlerTEXCLUT(u32* data))
void __fastcall GIFRegHandlerTEXCLUT(u32* data)
{
if( ZeroGS::vb[0].bNeedTexCheck )
ZeroGS::vb[0].FlushTexData();
@ -591,7 +596,7 @@ void FASTCALL(GIFRegHandlerTEXCLUT(u32* data))
gs.clut.cov = (data[0] >> 12) & 0x3ff;
}
void FASTCALL(GIFRegHandlerSCANMSK(u32* data))
void __fastcall GIFRegHandlerSCANMSK(u32* data)
{
// ZeroGS::Flush(0);
// ZeroGS::Flush(1);
@ -601,7 +606,7 @@ void FASTCALL(GIFRegHandlerSCANMSK(u32* data))
gs.smask = data[0] & 0x3;
}
void FASTCALL(GIFRegHandlerMIPTBP1_1(u32* data))
void __fastcall GIFRegHandlerMIPTBP1_1(u32* data)
{
miptbpInfo& miptbp0 = ZeroGS::vb[0].miptbp0;
miptbp0.tbp[0] = (data[0] ) & 0x3fff;
@ -612,7 +617,7 @@ void FASTCALL(GIFRegHandlerMIPTBP1_1(u32* data))
miptbp0.tbw[2] = (data[1] >> 22) & 0x3f;
}
void FASTCALL(GIFRegHandlerMIPTBP1_2(u32* data))
void __fastcall GIFRegHandlerMIPTBP1_2(u32* data)
{
miptbpInfo& miptbp0 = ZeroGS::vb[1].miptbp0;
miptbp0.tbp[0] = (data[0] ) & 0x3fff;
@ -623,7 +628,7 @@ void FASTCALL(GIFRegHandlerMIPTBP1_2(u32* data))
miptbp0.tbw[2] = (data[1] >> 22) & 0x3f;
}
void FASTCALL(GIFRegHandlerMIPTBP2_1(u32* data))
void __fastcall GIFRegHandlerMIPTBP2_1(u32* data)
{
miptbpInfo& miptbp1 = ZeroGS::vb[0].miptbp1;
miptbp1.tbp[0] = (data[0] ) & 0x3fff;
@ -634,7 +639,7 @@ void FASTCALL(GIFRegHandlerMIPTBP2_1(u32* data))
miptbp1.tbw[2] = (data[1] >> 22) & 0x3f;
}
void FASTCALL(GIFRegHandlerMIPTBP2_2(u32* data))
void __fastcall GIFRegHandlerMIPTBP2_2(u32* data)
{
miptbpInfo& miptbp1 = ZeroGS::vb[1].miptbp1;
miptbp1.tbp[0] = (data[0] ) & 0x3fff;
@ -645,7 +650,7 @@ void FASTCALL(GIFRegHandlerMIPTBP2_2(u32* data))
miptbp1.tbw[2] = (data[1] >> 22) & 0x3f;
}
void FASTCALL(GIFRegHandlerTEXA(u32* data))
void __fastcall GIFRegHandlerTEXA(u32* data)
{
texaInfo newinfo;
newinfo.aem = (data[0] >> 15) & 0x1;
@ -664,17 +669,17 @@ void FASTCALL(GIFRegHandlerTEXA(u32* data))
}
}
void FASTCALL(GIFRegHandlerFOGCOL(u32* data))
void __fastcall GIFRegHandlerFOGCOL(u32* data)
{
ZeroGS::SetFogColor(data[0]&0xffffff);
}
void FASTCALL(GIFRegHandlerTEXFLUSH(u32* data))
void __fastcall GIFRegHandlerTEXFLUSH(u32* data)
{
ZeroGS::SetTexFlush();
}
void FASTCALL(GIFRegHandlerSCISSOR_1(u32* data))
void __fastcall GIFRegHandlerSCISSOR_1(u32* data)
{
Rect2& scissor = ZeroGS::vb[0].scissor;
@ -695,7 +700,7 @@ void FASTCALL(GIFRegHandlerSCISSOR_1(u32* data))
}
}
void FASTCALL(GIFRegHandlerSCISSOR_2(u32* data))
void __fastcall GIFRegHandlerSCISSOR_2(u32* data)
{
Rect2& scissor = ZeroGS::vb[1].scissor;
@ -717,7 +722,7 @@ void FASTCALL(GIFRegHandlerSCISSOR_2(u32* data))
}
}
void FASTCALL(GIFRegHandlerALPHA_1(u32* data))
void __fastcall GIFRegHandlerALPHA_1(u32* data)
{
alphaInfo newalpha;
newalpha.abcd = *(u8*)data;
@ -735,7 +740,7 @@ void FASTCALL(GIFRegHandlerALPHA_1(u32* data))
}
}
void FASTCALL(GIFRegHandlerALPHA_2(u32* data))
void __fastcall GIFRegHandlerALPHA_2(u32* data)
{
alphaInfo newalpha;
newalpha.abcd = *(u8*)data;
@ -753,31 +758,31 @@ void FASTCALL(GIFRegHandlerALPHA_2(u32* data))
}
}
void FASTCALL(GIFRegHandlerDIMX(u32* data))
void __fastcall GIFRegHandlerDIMX(u32* data)
{
}
void FASTCALL(GIFRegHandlerDTHE(u32* data))
void __fastcall GIFRegHandlerDTHE(u32* data)
{
gs.dthe = data[0] & 0x1;
}
void FASTCALL(GIFRegHandlerCOLCLAMP(u32* data))
void __fastcall GIFRegHandlerCOLCLAMP(u32* data)
{
gs.colclamp = data[0] & 0x1;
}
void FASTCALL(GIFRegHandlerTEST_1(u32* data))
void __fastcall GIFRegHandlerTEST_1(u32* data)
{
testWrite(0, data);
}
void FASTCALL(GIFRegHandlerTEST_2(u32* data))
void __fastcall GIFRegHandlerTEST_2(u32* data)
{
testWrite(1, data);
}
void FASTCALL(GIFRegHandlerPABE(u32* data))
void __fastcall GIFRegHandlerPABE(u32* data)
{
//ZeroGS::SetAlphaChanged(0, GPUREG_PABE);
//ZeroGS::SetAlphaChanged(1, GPUREG_PABE);
@ -787,31 +792,31 @@ void FASTCALL(GIFRegHandlerPABE(u32* data))
gs.pabe = *data & 0x1;
}
void FASTCALL(GIFRegHandlerFBA_1(u32* data))
void __fastcall GIFRegHandlerFBA_1(u32* data)
{
ZeroGS::Flush(0);
ZeroGS::Flush(1);
ZeroGS::vb[0].fba.fba = *data & 0x1;
}
void FASTCALL(GIFRegHandlerFBA_2(u32* data))
void __fastcall GIFRegHandlerFBA_2(u32* data)
{
ZeroGS::Flush(0);
ZeroGS::Flush(1);
ZeroGS::vb[1].fba.fba = *data & 0x1;
}
void FASTCALL(GIFRegHandlerFRAME_1(u32* data))
void __fastcall GIFRegHandlerFRAME_1(u32* data)
{
frameWrite(0, data);
}
void FASTCALL(GIFRegHandlerFRAME_2(u32* data))
void __fastcall GIFRegHandlerFRAME_2(u32* data)
{
frameWrite(1, data);
}
void FASTCALL(GIFRegHandlerZBUF_1(u32* data))
void __fastcall GIFRegHandlerZBUF_1(u32* data)
{
zbufInfo& zbuf = ZeroGS::vb[0].zbuf;
@ -839,7 +844,7 @@ void FASTCALL(GIFRegHandlerZBUF_1(u32* data))
ZeroGS::vb[0].bNeedZCheck = 1;
}
void FASTCALL(GIFRegHandlerZBUF_2(u32* data))
void __fastcall GIFRegHandlerZBUF_2(u32* data)
{
zbufInfo& zbuf = ZeroGS::vb[1].zbuf;
@ -867,7 +872,7 @@ void FASTCALL(GIFRegHandlerZBUF_2(u32* data))
if( zbuf.psm > 0x31 ) ZeroGS::vb[1].zprimmask = 0xffff;
}
void FASTCALL(GIFRegHandlerBITBLTBUF(u32* data))
void __fastcall GIFRegHandlerBITBLTBUF(u32* data)
{
gs.srcbufnew.bp = ((data[0] ) & 0x3fff);// * 64;
gs.srcbufnew.bw = ((data[0] >> 16) & 0x3f) * 64;
@ -879,7 +884,7 @@ void FASTCALL(GIFRegHandlerBITBLTBUF(u32* data))
if (gs.dstbufnew.bw == 0) gs.dstbufnew.bw = 64;
}
void FASTCALL(GIFRegHandlerTRXPOS(u32* data))
void __fastcall GIFRegHandlerTRXPOS(u32* data)
{
gs.trxposnew.sx = (data[0] ) & 0x7ff;
gs.trxposnew.sy = (data[0] >> 16) & 0x7ff;
@ -888,13 +893,13 @@ void FASTCALL(GIFRegHandlerTRXPOS(u32* data))
gs.trxposnew.dir = (data[1] >> 27) & 0x3;
}
void FASTCALL(GIFRegHandlerTRXREG(u32* data))
void __fastcall GIFRegHandlerTRXREG(u32* data)
{
gs.imageWtemp = data[0]&0xfff;
gs.imageHtemp = data[1]&0xfff;
}
void FASTCALL(GIFRegHandlerTRXDIR(u32* data))
void __fastcall GIFRegHandlerTRXDIR(u32* data)
{
// terminate any previous transfers
switch( gs.imageTransfer ) {
@ -944,7 +949,7 @@ void FASTCALL(GIFRegHandlerTRXDIR(u32* data))
}
static u32 oldhw[4];
void FASTCALL(GIFRegHandlerHWREG(u32* data))
void __fastcall GIFRegHandlerHWREG(u32* data)
{
if( gs.imageTransfer == 0 ) {
ZeroGS::TransferHostLocal(data, 2);
@ -959,7 +964,7 @@ void FASTCALL(GIFRegHandlerHWREG(u32* data))
extern int g_GSMultiThreaded;
void FASTCALL(GIFRegHandlerSIGNAL(u32* data))
void __fastcall GIFRegHandlerSIGNAL(u32* data)
{
if(!g_GSMultiThreaded) {
SIGLBLID->SIGID = (SIGLBLID->SIGID&~data[1])|(data[0]&data[1]);
@ -977,7 +982,7 @@ void FASTCALL(GIFRegHandlerSIGNAL(u32* data))
}
}
void FASTCALL(GIFRegHandlerFINISH(u32* data))
void __fastcall GIFRegHandlerFINISH(u32* data)
{
if(!g_GSMultiThreaded) {
@ -999,7 +1004,7 @@ void FASTCALL(GIFRegHandlerFINISH(u32* data))
}
}
void FASTCALL(GIFRegHandlerLABEL(u32* data))
void __fastcall GIFRegHandlerLABEL(u32* data)
{
if(!g_GSMultiThreaded) {
SIGLBLID->LBLID = (SIGLBLID->LBLID&~data[1])|(data[0]&data[1]);

View File

@ -26,76 +26,76 @@ typedef void (__fastcall *GIFRegHandler)(u32* data);
#ifdef __x86_64__
typedef void (*GIFRegHandler)(u32* data);
#else
typedef void (__attribute__((fastcall)) *GIFRegHandler)(u32* data);
typedef void (__fastcall *GIFRegHandler)(u32* data);
#endif
#endif
void FASTCALL(GIFPackedRegHandlerNull(u32* data));
void FASTCALL(GIFPackedRegHandlerRGBA(u32* data));
void FASTCALL(GIFPackedRegHandlerSTQ(u32* data));
void FASTCALL(GIFPackedRegHandlerUV(u32* data));
void FASTCALL(GIFPackedRegHandlerXYZF2(u32* data));
void FASTCALL(GIFPackedRegHandlerXYZ2(u32* data));
void FASTCALL(GIFPackedRegHandlerFOG(u32* data));
void FASTCALL(GIFPackedRegHandlerA_D(u32* data));
void FASTCALL(GIFPackedRegHandlerNOP(u32* data));
void __fastcall GIFPackedRegHandlerNull(u32* data);
void __fastcall GIFPackedRegHandlerRGBA(u32* data);
void __fastcall GIFPackedRegHandlerSTQ(u32* data);
void __fastcall GIFPackedRegHandlerUV(u32* data);
void __fastcall GIFPackedRegHandlerXYZF2(u32* data);
void __fastcall GIFPackedRegHandlerXYZ2(u32* data);
void __fastcall GIFPackedRegHandlerFOG(u32* data);
void __fastcall GIFPackedRegHandlerA_D(u32* data);
void __fastcall GIFPackedRegHandlerNOP(u32* data);
void FASTCALL(GIFRegHandlerNull(u32* data));
void FASTCALL(GIFRegHandlerPRIM(u32* data));
void FASTCALL(GIFRegHandlerRGBAQ(u32* data));
void FASTCALL(GIFRegHandlerST(u32* data));
void FASTCALL(GIFRegHandlerUV(u32* data));
void FASTCALL(GIFRegHandlerXYZF2(u32* data));
void FASTCALL(GIFRegHandlerXYZ2(u32* data));
void FASTCALL(GIFRegHandlerTEX0_1(u32* data));
void FASTCALL(GIFRegHandlerTEX0_2(u32* data));
void FASTCALL(GIFRegHandlerCLAMP_1(u32* data));
void FASTCALL(GIFRegHandlerCLAMP_2(u32* data));
void FASTCALL(GIFRegHandlerFOG(u32* data));
void FASTCALL(GIFRegHandlerXYZF3(u32* data));
void FASTCALL(GIFRegHandlerXYZ3(u32* data));
void FASTCALL(GIFRegHandlerNOP(u32* data));
void FASTCALL(GIFRegHandlerTEX1_1(u32* data));
void FASTCALL(GIFRegHandlerTEX1_2(u32* data));
void FASTCALL(GIFRegHandlerTEX2_1(u32* data));
void FASTCALL(GIFRegHandlerTEX2_2(u32* data));
void FASTCALL(GIFRegHandlerXYOFFSET_1(u32* data));
void FASTCALL(GIFRegHandlerXYOFFSET_2(u32* data));
void FASTCALL(GIFRegHandlerPRMODECONT(u32* data));
void FASTCALL(GIFRegHandlerPRMODE(u32* data));
void FASTCALL(GIFRegHandlerTEXCLUT(u32* data));
void FASTCALL(GIFRegHandlerSCANMSK(u32* data));
void FASTCALL(GIFRegHandlerMIPTBP1_1(u32* data));
void FASTCALL(GIFRegHandlerMIPTBP1_2(u32* data));
void FASTCALL(GIFRegHandlerMIPTBP2_1(u32* data));
void FASTCALL(GIFRegHandlerMIPTBP2_2(u32* data));
void FASTCALL(GIFRegHandlerTEXA(u32* data));
void FASTCALL(GIFRegHandlerFOGCOL(u32* data));
void FASTCALL(GIFRegHandlerTEXFLUSH(u32* data));
void FASTCALL(GIFRegHandlerSCISSOR_1(u32* data));
void FASTCALL(GIFRegHandlerSCISSOR_2(u32* data));
void FASTCALL(GIFRegHandlerALPHA_1(u32* data));
void FASTCALL(GIFRegHandlerALPHA_2(u32* data));
void FASTCALL(GIFRegHandlerDIMX(u32* data));
void FASTCALL(GIFRegHandlerDTHE(u32* data));
void FASTCALL(GIFRegHandlerCOLCLAMP(u32* data));
void FASTCALL(GIFRegHandlerTEST_1(u32* data));
void FASTCALL(GIFRegHandlerTEST_2(u32* data));
void FASTCALL(GIFRegHandlerPABE(u32* data));
void FASTCALL(GIFRegHandlerFBA_1(u32* data));
void FASTCALL(GIFRegHandlerFBA_2(u32* data));
void FASTCALL(GIFRegHandlerFRAME_1(u32* data));
void FASTCALL(GIFRegHandlerFRAME_2(u32* data));
void FASTCALL(GIFRegHandlerZBUF_1(u32* data));
void FASTCALL(GIFRegHandlerZBUF_2(u32* data));
void FASTCALL(GIFRegHandlerBITBLTBUF(u32* data));
void FASTCALL(GIFRegHandlerTRXPOS(u32* data));
void FASTCALL(GIFRegHandlerTRXREG(u32* data));
void FASTCALL(GIFRegHandlerTRXDIR(u32* data));
void FASTCALL(GIFRegHandlerHWREG(u32* data));
void FASTCALL(GIFRegHandlerSIGNAL(u32* data));
void FASTCALL(GIFRegHandlerFINISH(u32* data));
void FASTCALL(GIFRegHandlerLABEL(u32* data));
void __fastcall GIFRegHandlerNull(u32* data);
void __fastcall GIFRegHandlerPRIM(u32* data);
void __fastcall GIFRegHandlerRGBAQ(u32* data);
void __fastcall GIFRegHandlerST(u32* data);
void __fastcall GIFRegHandlerUV(u32* data);
void __fastcall GIFRegHandlerXYZF2(u32* data);
void __fastcall GIFRegHandlerXYZ2(u32* data);
void __fastcall GIFRegHandlerTEX0_1(u32* data);
void __fastcall GIFRegHandlerTEX0_2(u32* data);
void __fastcall GIFRegHandlerCLAMP_1(u32* data);
void __fastcall GIFRegHandlerCLAMP_2(u32* data);
void __fastcall GIFRegHandlerFOG(u32* data);
void __fastcall GIFRegHandlerXYZF3(u32* data);
void __fastcall GIFRegHandlerXYZ3(u32* data);
void __fastcall GIFRegHandlerNOP(u32* data);
void __fastcall GIFRegHandlerTEX1_1(u32* data);
void __fastcall GIFRegHandlerTEX1_2(u32* data);
void __fastcall GIFRegHandlerTEX2_1(u32* data);
void __fastcall GIFRegHandlerTEX2_2(u32* data);
void __fastcall GIFRegHandlerXYOFFSET_1(u32* data);
void __fastcall GIFRegHandlerXYOFFSET_2(u32* data);
void __fastcall GIFRegHandlerPRMODECONT(u32* data);
void __fastcall GIFRegHandlerPRMODE(u32* data);
void __fastcall GIFRegHandlerTEXCLUT(u32* data);
void __fastcall GIFRegHandlerSCANMSK(u32* data);
void __fastcall GIFRegHandlerMIPTBP1_1(u32* data);
void __fastcall GIFRegHandlerMIPTBP1_2(u32* data);
void __fastcall GIFRegHandlerMIPTBP2_1(u32* data);
void __fastcall GIFRegHandlerMIPTBP2_2(u32* data);
void __fastcall GIFRegHandlerTEXA(u32* data);
void __fastcall GIFRegHandlerFOGCOL(u32* data);
void __fastcall GIFRegHandlerTEXFLUSH(u32* data);
void __fastcall GIFRegHandlerSCISSOR_1(u32* data);
void __fastcall GIFRegHandlerSCISSOR_2(u32* data);
void __fastcall GIFRegHandlerALPHA_1(u32* data);
void __fastcall GIFRegHandlerALPHA_2(u32* data);
void __fastcall GIFRegHandlerDIMX(u32* data);
void __fastcall GIFRegHandlerDTHE(u32* data);
void __fastcall GIFRegHandlerCOLCLAMP(u32* data);
void __fastcall GIFRegHandlerTEST_1(u32* data);
void __fastcall GIFRegHandlerTEST_2(u32* data);
void __fastcall GIFRegHandlerPABE(u32* data);
void __fastcall GIFRegHandlerFBA_1(u32* data);
void __fastcall GIFRegHandlerFBA_2(u32* data);
void __fastcall GIFRegHandlerFRAME_1(u32* data);
void __fastcall GIFRegHandlerFRAME_2(u32* data);
void __fastcall GIFRegHandlerZBUF_1(u32* data);
void __fastcall GIFRegHandlerZBUF_2(u32* data);
void __fastcall GIFRegHandlerBITBLTBUF(u32* data);
void __fastcall GIFRegHandlerTRXPOS(u32* data);
void __fastcall GIFRegHandlerTRXREG(u32* data);
void __fastcall GIFRegHandlerTRXDIR(u32* data);
void __fastcall GIFRegHandlerHWREG(u32* data);
void __fastcall GIFRegHandlerSIGNAL(u32* data);
void __fastcall GIFRegHandlerFINISH(u32* data);
void __fastcall GIFRegHandlerLABEL(u32* data);
#endif

View File

@ -30,7 +30,7 @@
// swizzling
void FASTCALL(SwizzleBlock32_c(u8* dst, u8* src, int srcpitch, u32 WriteMask))
void __fastcall SwizzleBlock32_c(u8* dst, u8* src, int srcpitch, u32 WriteMask)
{
u32* d = &g_columnTable32[0][0];
@ -48,7 +48,7 @@ void FASTCALL(SwizzleBlock32_c(u8* dst, u8* src, int srcpitch, u32 WriteMask))
}
}
void FASTCALL(SwizzleBlock16_c(u8* dst, u8* src, int srcpitch))
void __fastcall SwizzleBlock16_c(u8* dst, u8* src, int srcpitch)
{
u32* d = &g_columnTable16[0][0];
@ -57,7 +57,7 @@ void FASTCALL(SwizzleBlock16_c(u8* dst, u8* src, int srcpitch))
((u16*)dst)[d[i]] = ((u16*)src)[i];
}
void FASTCALL(SwizzleBlock8_c(u8* dst, u8* src, int srcpitch))
void __fastcall SwizzleBlock8_c(u8* dst, u8* src, int srcpitch)
{
u32* d = &g_columnTable8[0][0];
@ -66,7 +66,7 @@ void FASTCALL(SwizzleBlock8_c(u8* dst, u8* src, int srcpitch))
dst[d[i]] = src[i];
}
void FASTCALL(SwizzleBlock4_c(u8* dst, u8* src, int srcpitch))
void __fastcall SwizzleBlock4_c(u8* dst, u8* src, int srcpitch)
{
u32* d = &g_columnTable4[0][0];
@ -84,7 +84,7 @@ void FASTCALL(SwizzleBlock4_c(u8* dst, u8* src, int srcpitch))
#define _FrameSwizzleBlock(type, transfer, transfer16, incsrc) \
/* FrameSwizzleBlock32 */ \
void FASTCALL(FrameSwizzleBlock32##type##c(u32* dst, u32* src, int srcpitch, u32 WriteMask)) \
void __fastcall FrameSwizzleBlock32##type##c(u32* dst, u32* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable32[0][0]; \
\
@ -107,7 +107,7 @@ void FASTCALL(FrameSwizzleBlock32##type##c(u32* dst, u32* src, int srcpitch, u32
} \
\
/* FrameSwizzleBlock16 */ \
void FASTCALL(FrameSwizzleBlock16##type##c(u16* dst, u32* src, int srcpitch, u32 WriteMask)) \
void __fastcall FrameSwizzleBlock16##type##c(u16* dst, u32* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable16[0][0]; \
\
@ -133,7 +133,7 @@ void FASTCALL(FrameSwizzleBlock16##type##c(u16* dst, u32* src, int srcpitch, u32
} \
\
/* Frame16SwizzleBlock32 */ \
void FASTCALL(Frame16SwizzleBlock32##type##c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask)) \
void __fastcall Frame16SwizzleBlock32##type##c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable32[0][0]; \
\
@ -159,7 +159,7 @@ void FASTCALL(Frame16SwizzleBlock32##type##c(u32* dst, Vector_16F* src, int srcp
} \
\
/* Frame16SwizzleBlock32Z */ \
void FASTCALL(Frame16SwizzleBlock32Z##type##c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask)) \
void __fastcall Frame16SwizzleBlock32Z##type##c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable32[0][0]; \
if( WriteMask == 0xffffffff ) { /* breaks KH text if not checked */ \
@ -184,7 +184,7 @@ void FASTCALL(Frame16SwizzleBlock32Z##type##c(u32* dst, Vector_16F* src, int src
} \
\
/* Frame16SwizzleBlock16 */ \
void FASTCALL(Frame16SwizzleBlock16##type##c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask)) \
void __fastcall Frame16SwizzleBlock16##type##c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable16[0][0]; \
\
@ -210,7 +210,7 @@ void FASTCALL(Frame16SwizzleBlock16##type##c(u16* dst, Vector_16F* src, int srcp
} \
\
/* Frame16SwizzleBlock16Z */ \
void FASTCALL(Frame16SwizzleBlock16Z##type##c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask)) \
void __fastcall Frame16SwizzleBlock16Z##type##c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask) \
{ \
u32* d = &g_columnTable16[0][0]; \
\
@ -229,7 +229,7 @@ _FrameSwizzleBlock(A4_, (src[2*j]+src[2*j+1]+src[2*j+srcpitch]+src[2*j+srcpitch+
#ifdef ZEROGS_SSE2
//void FASTCALL(WriteCLUT_T16_I8_CSM1_sse2(u32* vm, u32* clut)
//void __fastcall WriteCLUT_T16_I8_CSM1_sse2(u32* vm, u32* clut)
//{
// __asm {
// mov eax, vm
@ -294,7 +294,7 @@ _FrameSwizzleBlock(A4_, (src[2*j]+src[2*j+1]+src[2*j+srcpitch]+src[2*j+srcpitch+
#if (defined(_WIN32)||defined(__x86_64__))
extern "C" void FASTCALL(WriteCLUT_T32_I8_CSM1_sse2(u32* vm, u32* clut))
extern "C" void __fastcall WriteCLUT_T32_I8_CSM1_sse2(u32* vm, u32* clut)
{
__m128i* src = (__m128i*)vm;
__m128i* dst = (__m128i*)clut;
@ -326,7 +326,7 @@ extern "C" void FASTCALL(WriteCLUT_T32_I8_CSM1_sse2(u32* vm, u32* clut))
}
}
extern "C" void FASTCALL(WriteCLUT_T32_I4_CSM1_sse2(u32* vm, u32* clut))
extern "C" void __fastcall WriteCLUT_T32_I4_CSM1_sse2(u32* vm, u32* clut)
{
__m128i* src = (__m128i*)vm;
__m128i* dst = (__m128i*)clut;
@ -353,7 +353,7 @@ PCSX2_ALIGNED16(int s_clut16mask[8]) = { 0xffff0000, 0xffff0000, 0xffff0000, 0xf
#if !defined(__x86_64__)
extern "C" void FASTCALL(WriteCLUT_T16_I4_CSM1_sse2(u32* vm, u32* clut))
extern "C" void __fastcall WriteCLUT_T16_I4_CSM1_sse2(u32* vm, u32* clut)
{
__asm {
mov eax, vm
@ -472,7 +472,7 @@ End:
#endif // ZEROGS_SSE2
void FASTCALL(WriteCLUT_T16_I8_CSM1_c(u32* _vm, u32* _clut))
void __fastcall WriteCLUT_T16_I8_CSM1_c(u32* _vm, u32* _clut)
{
const static u32 map[] =
{
@ -511,7 +511,7 @@ void FASTCALL(WriteCLUT_T16_I8_CSM1_c(u32* _vm, u32* _clut))
}
}
void FASTCALL(WriteCLUT_T32_I8_CSM1_c(u32* vm, u32* clut))
void __fastcall WriteCLUT_T32_I8_CSM1_c(u32* vm, u32* clut)
{
u64* src = (u64*)vm;
u64* dst = (u64*)clut;
@ -540,7 +540,7 @@ void FASTCALL(WriteCLUT_T32_I8_CSM1_c(u32* vm, u32* clut))
}
}
void FASTCALL(WriteCLUT_T16_I4_CSM1_c(u32* _vm, u32* _clut))
void __fastcall WriteCLUT_T16_I4_CSM1_c(u32* _vm, u32* _clut)
{
u16* dst = (u16*)_clut;
u16* src = (u16*)_vm;
@ -555,7 +555,7 @@ void FASTCALL(WriteCLUT_T16_I4_CSM1_c(u32* _vm, u32* _clut))
dst[28] = src[28]; dst[30] = src[30];
}
void FASTCALL(WriteCLUT_T32_I4_CSM1_c(u32* vm, u32* clut))
void __fastcall WriteCLUT_T32_I4_CSM1_c(u32* vm, u32* clut)
{
u64* src = (u64*)vm;
u64* dst = (u64*)clut;

View File

@ -24,84 +24,84 @@
#include "GS.h"
extern "C" void FASTCALL(SwizzleBlock32_sse2(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff));
extern "C" void FASTCALL(SwizzleBlock16_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void FASTCALL(SwizzleBlock8_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void FASTCALL(SwizzleBlock4_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void FASTCALL(SwizzleBlock32u_sse2(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff));
extern "C" void FASTCALL(SwizzleBlock16u_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void FASTCALL(SwizzleBlock8u_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void FASTCALL(SwizzleBlock4u_sse2(u8* dst, u8* src, int srcpitch));
extern "C" void __fastcall SwizzleBlock32_sse2(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff);
extern "C" void __fastcall SwizzleBlock16_sse2(u8* dst, u8* src, int srcpitch);
extern "C" void __fastcall SwizzleBlock8_sse2(u8* dst, u8* src, int srcpitch);
extern "C" void __fastcall SwizzleBlock4_sse2(u8* dst, u8* src, int srcpitch);
extern "C" void __fastcall SwizzleBlock32u_sse2(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff);
extern "C" void __fastcall SwizzleBlock16u_sse2(u8* dst, u8* src, int srcpitch);
extern "C" void __fastcall SwizzleBlock8u_sse2(u8* dst, u8* src, int srcpitch);
extern "C" void __fastcall SwizzleBlock4u_sse2(u8* dst, u8* src, int srcpitch);
// frame swizzling
// no AA
extern "C" void FASTCALL(FrameSwizzleBlock32_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(FrameSwizzleBlock16_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32Z_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16Z_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void __fastcall FrameSwizzleBlock32_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall FrameSwizzleBlock16_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32Z_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16Z_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
// AA 2x
extern "C" void FASTCALL(FrameSwizzleBlock32A2_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(FrameSwizzleBlock16A2_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32A2_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32ZA2_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16A2_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16ZA2_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void __fastcall FrameSwizzleBlock32A2_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall FrameSwizzleBlock16A2_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32A2_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32ZA2_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16A2_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16ZA2_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
// AA 4x
extern "C" void FASTCALL(FrameSwizzleBlock32A4_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(FrameSwizzleBlock16A4_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32A4_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock32ZA4_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16A4_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void FASTCALL(Frame16SwizzleBlock16ZA4_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern "C" void __fastcall FrameSwizzleBlock32A4_sse2(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall FrameSwizzleBlock16A4_sse2(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32A4_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock32ZA4_sse2(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16A4_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern "C" void __fastcall Frame16SwizzleBlock16ZA4_sse2(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void FASTCALL(SwizzleBlock32_c(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff));
extern void FASTCALL(SwizzleBlock16_c(u8* dst, u8* src, int srcpitch));
extern void FASTCALL(SwizzleBlock8_c(u8* dst, u8* src, int srcpitch));
extern void FASTCALL(SwizzleBlock4_c(u8* dst, u8* src, int srcpitch));
extern void __fastcall SwizzleBlock32_c(u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff);
extern void __fastcall SwizzleBlock16_c(u8* dst, u8* src, int srcpitch);
extern void __fastcall SwizzleBlock8_c(u8* dst, u8* src, int srcpitch);
extern void __fastcall SwizzleBlock4_c(u8* dst, u8* src, int srcpitch);
// no AA
extern void FASTCALL(FrameSwizzleBlock32_c(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(FrameSwizzleBlock16_c(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32Z_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16Z_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void __fastcall FrameSwizzleBlock32_c(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall FrameSwizzleBlock16_c(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32Z_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16Z_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
// AA 2x
extern void FASTCALL(FrameSwizzleBlock32A2_c(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(FrameSwizzleBlock16A2_c(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32A2_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32ZA2_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16A2_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16ZA2_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void __fastcall FrameSwizzleBlock32A2_c(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall FrameSwizzleBlock16A2_c(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32A2_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32ZA2_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16A2_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16ZA2_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
// AA 4x
extern void FASTCALL(FrameSwizzleBlock32A4_c(u32* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(FrameSwizzleBlock16A4_c(u16* dst, u32* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32A4_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock32ZA4_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16A4_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void FASTCALL(Frame16SwizzleBlock16ZA4_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask));
extern void __fastcall FrameSwizzleBlock32A4_c(u32* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall FrameSwizzleBlock16A4_c(u16* dst, u32* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32A4_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock32ZA4_c(u32* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16A4_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void __fastcall Frame16SwizzleBlock16ZA4_c(u16* dst, Vector_16F* src, int srcpitch, u32 WriteMask);
extern void FASTCALL(SwizzleColumn32_c(int y, u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff));
extern void FASTCALL(SwizzleColumn16_c(int y, u8* dst, u8* src, int srcpitch));
extern void FASTCALL(SwizzleColumn8_c(int y, u8* dst, u8* src, int srcpitch));
extern void FASTCALL(SwizzleColumn4_c(int y, u8* dst, u8* src, int srcpitch));
extern void __fastcall SwizzleColumn32_c(int y, u8* dst, u8* src, int srcpitch, u32 WriteMask = 0xffffffff);
extern void __fastcall SwizzleColumn16_c(int y, u8* dst, u8* src, int srcpitch);
extern void __fastcall SwizzleColumn8_c(int y, u8* dst, u8* src, int srcpitch);
extern void __fastcall SwizzleColumn4_c(int y, u8* dst, u8* src, int srcpitch);
extern "C" void FASTCALL(WriteCLUT_T16_I8_CSM1_sse2(u32* vm, u32* clut));
extern "C" void FASTCALL(WriteCLUT_T32_I8_CSM1_sse2(u32* vm, u32* clut));
extern "C" void FASTCALL(WriteCLUT_T16_I4_CSM1_sse2(u32* vm, u32* clut));
extern "C" void FASTCALL(WriteCLUT_T32_I4_CSM1_sse2(u32* vm, u32* clut));
extern void FASTCALL(WriteCLUT_T16_I8_CSM1_c(u32* vm, u32* clut));
extern void FASTCALL(WriteCLUT_T32_I8_CSM1_c(u32* vm, u32* clut));
extern "C" void __fastcall WriteCLUT_T16_I8_CSM1_sse2(u32* vm, u32* clut);
extern "C" void __fastcall WriteCLUT_T32_I8_CSM1_sse2(u32* vm, u32* clut);
extern "C" void __fastcall WriteCLUT_T16_I4_CSM1_sse2(u32* vm, u32* clut);
extern "C" void __fastcall WriteCLUT_T32_I4_CSM1_sse2(u32* vm, u32* clut);
extern void __fastcall WriteCLUT_T16_I8_CSM1_c(u32* vm, u32* clut);
extern void __fastcall WriteCLUT_T32_I8_CSM1_c(u32* vm, u32* clut);
extern void FASTCALL(WriteCLUT_T16_I4_CSM1_c(u32* vm, u32* clut));
extern void FASTCALL(WriteCLUT_T32_I4_CSM1_c(u32* vm, u32* clut));
extern void __fastcall WriteCLUT_T16_I4_CSM1_c(u32* vm, u32* clut);
extern void __fastcall WriteCLUT_T32_I4_CSM1_c(u32* vm, u32* clut);
#ifdef ZEROGS_SSE2

View File

@ -1,6 +1,7 @@
# Create a shared library libZeroPAD
AUTOMAKE_OPTIONS = foreign
noinst_LIBRARIES = libZeroPAD.a
INCLUDES = -I@srcdir@/../common
libZeroPAD_a_CXXFLAGS = $(shell pkg-config --cflags gtk+-2.0)
libZeroPAD_a_CFLAGS = $(shell pkg-config --cflags gtk+-2.0)

View File

@ -42,7 +42,7 @@ using namespace std;
#define PADdefs
extern "C" {
#include "../common/PS2Edefs.h"
#include "PS2Edefs.h"
}
extern char libraryName[256];

View File

@ -1,6 +1,7 @@
# Create a shared library libZeroSPU2
AUTOMAKE_OPTIONS = foreign
noinst_LIBRARIES = libZeroSPU2.a
INCLUDES = -I@srcdir@/../common
libZeroSPU2_a_CXXFLAGS = $(shell pkg-config --cflags gtk+-2.0)
libZeroSPU2_a_CFLAGS = $(shell pkg-config --cflags gtk+-2.0)

View File

@ -27,7 +27,7 @@
extern "C" {
#define SPU2defs
#include "../common/PS2Edefs.h"
#include "PS2Edefs.h"
}
#ifdef __LINUX__