X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=pcsx_rearmed.git;a=blobdiff_plain;f=frontend%2Fplugin.c;h=33efbf0be3876d1ac7273c383294632c93cedf6a;hp=6c83a4477833cfc312dccc2455c60f0986f4a4e7;hb=799b0b8773d6add1de99efd582c93701b82e970d;hpb=201c21e2ad6be25a4b843d1434eabb432ce72884 diff --git a/frontend/plugin.c b/frontend/plugin.c index 6c83a447..33efbf0b 100644 --- a/frontend/plugin.c +++ b/frontend/plugin.c @@ -43,15 +43,21 @@ extern void SPUplayCDDAchannel(short *, int); /* PAD */ static long PADreadPort1(PadDataS *pad) { - pad->controllerType = PSE_PAD_TYPE_STANDARD; - pad->buttonStatus = ~keystate; + pad->controllerType = in_type; + pad->buttonStatus = ~in_keystate; + if (in_type == PSE_PAD_TYPE_ANALOGPAD) { + pad->leftJoyX = in_a1[0]; + pad->leftJoyY = in_a1[1]; + pad->rightJoyX = in_a2[0]; + pad->rightJoyY = in_a2[1]; + } return 0; } static long PADreadPort2(PadDataS *pad) { pad->controllerType = PSE_PAD_TYPE_STANDARD; - pad->buttonStatus = ~keystate >> 16; + pad->buttonStatus = ~in_keystate >> 16; return 0; } @@ -68,17 +74,7 @@ extern uint32_t GPUreadData(void); extern void GPUreadDataMem(uint32_t *, int); extern long GPUdmaChain(uint32_t *,uint32_t); extern void GPUupdateLace(void); -extern long GPUconfigure(void); -extern long GPUtest(void); -extern void GPUabout(void); -extern void GPUmakeSnapshot(void); -extern void GPUkeypressed(int); -extern void GPUdisplayText(char *); extern long GPUfreeze(uint32_t, void *); -extern long GPUgetScreenPic(unsigned char *); -extern long GPUshowScreenPic(unsigned char *); -extern void GPUclearDynarec(void (*callback)(void)); -extern void GPUvBlank(int); #define DUMMY(id, name) \ @@ -87,6 +83,7 @@ extern void GPUvBlank(int); #define DIRECT(id, name) \ { id, #name, name } +#define DUMMY_GPU(name) DUMMY(PLUGIN_GPU, name) #define DUMMY_CDR(name) DUMMY(PLUGIN_CDR, name) #define DUMMY_PAD(name) DUMMY(PLUGIN_PAD, name) #define DIRECT_SPU(name) DIRECT(PLUGIN_SPU, name) @@ -159,9 +156,6 @@ static const struct { DIRECT_GPU(GPUupdateLace), DIRECT_GPU(GPUinit), DIRECT_GPU(GPUshutdown), - DIRECT_GPU(GPUconfigure), - DIRECT_GPU(GPUtest), - DIRECT_GPU(GPUabout), DIRECT_GPU(GPUopen), DIRECT_GPU(GPUclose), DIRECT_GPU(GPUreadStatus), @@ -171,12 +165,18 @@ static const struct { DIRECT_GPU(GPUwriteData), DIRECT_GPU(GPUwriteDataMem), DIRECT_GPU(GPUdmaChain), + DIRECT_GPU(GPUfreeze), + + DUMMY_GPU(GPUdisplayText), +/* DIRECT_GPU(GPUkeypressed), - DIRECT_GPU(GPUdisplayText), DIRECT_GPU(GPUmakeSnapshot), - DIRECT_GPU(GPUfreeze), + DIRECT_GPU(GPUconfigure), + DIRECT_GPU(GPUtest), + DIRECT_GPU(GPUabout), DIRECT_GPU(GPUgetScreenPic), DIRECT_GPU(GPUshowScreenPic), +*/ // DIRECT_GPU(GPUclearDynarec), // DIRECT_GPU(GPUvBlank), };