cdrom: cleanup irq reschedule and pause hacks
[pcsx_rearmed.git] / plugins / gpu-gles / gpuPlugin.h
1 /***************************************************************************\r
2                             gpu.h  -  description\r
3                              -------------------\r
4     begin                : Sun Mar 08 2009\r
5     copyright            : (C) 1999-2009 by Pete Bernert\r
6     web                  : www.pbernert.com   \r
7  ***************************************************************************/\r
8 \r
9 /***************************************************************************\r
10  *                                                                         *\r
11  *   This program is free software; you can redistribute it and/or modify  *\r
12  *   it under the terms of the GNU General Public License as published by  *\r
13  *   the Free Software Foundation; either version 2 of the License, or     *\r
14  *   (at your option) any later version. See also the license.txt file for *\r
15  *   additional informations.                                              *\r
16  *                                                                         *\r
17  ***************************************************************************/\r
18 \r
19 //*************************************************************************// \r
20 // History of changes:\r
21 //\r
22 // 2009/03/08 - Pete  \r
23 // - generic cleanup for the Peops release\r
24 //\r
25 //*************************************************************************// \r
26 \r
27 #ifndef _GPU_PLUGIN_H\r
28 #define _GPU_PLUGIN_H\r
29 \r
30 /////////////////////////////////////////////////////////////////////////////\r
31 \r
32 #ifdef __cplusplus\r
33 extern "C" {\r
34 #endif \r
35 \r
36 #if !defined(_WINDOWS) && !defined(__NANOGL__)\r
37 #define glOrtho(x,y,z,xx,yy,zz) glOrthof(x,y,z,xx,yy,zz)\r
38 #endif\r
39 \r
40 #define PRED(x)   ((x << 3) & 0xF8)\r
41 #define PBLUE(x)  ((x >> 2) & 0xF8)\r
42 #define PGREEN(x) ((x >> 7) & 0xF8)\r
43 \r
44 #define RED(x) (x & 0xff)\r
45 #define BLUE(x) ((x>>16) & 0xff)\r
46 #define GREEN(x) ((x>>8) & 0xff)\r
47 #define COLOR(x) (x & 0xffffff)\r
48 \r
49 \r
50 #include "gpuExternals.h"\r
51 \r
52 /////////////////////////////////////////////////////////////////////////////\r
53 \r
54 #define CALLBACK\r
55 \r
56 #define bool unsigned short\r
57 \r
58 typedef struct {\r
59         unsigned int ulFreezeVersion;\r
60         unsigned int ulStatus;\r
61         unsigned int ulControl[256];\r
62         unsigned char psxVRam[1024*1024*2];\r
63 } GPUFreeze_t;\r
64 \r
65 #if 0\r
66 long CALLBACK GPUinit();\r
67 long CALLBACK GPUshutdown();\r
68 long CALLBACK GPUopen(int hwndGPU);\r
69 long CALLBACK GPUclose();\r
70 unsigned long CALLBACK GPUreadData(void);\r
71 void CALLBACK GPUreadDataMem(unsigned long * pMem, int iSize);\r
72 unsigned long CALLBACK GPUreadStatus(void);\r
73 void CALLBACK GPUwriteData(unsigned long gdata);\r
74 void CALLBACK GPUwriteDataMem(unsigned long * pMem, int iSize);\r
75 void CALLBACK GPUwriteStatus(unsigned long gdata);\r
76 long CALLBACK GPUdmaChain(unsigned long * baseAddrL, unsigned long addr);\r
77 void CALLBACK GPUupdateLace(void);\r
78 void CALLBACK GPUmakeSnapshot(void);\r
79 long CALLBACK GPUfreeze(unsigned long ulGetFreezeData,GPUFreeze_t * pF);\r
80 long CALLBACK GPUgetScreenPic(unsigned char * pMem);\r
81 long CALLBACK GPUshowScreenPic(unsigned char * pMem);\r
82 //void CALLBACK GPUkeypressed(int keycode);\r
83 //void CALLBACK GPUdisplayText(s8 * pText);\r
84 //void CALLBACK GPUclearDynarec(void (CALLBACK *callback)(void));\r
85 long CALLBACK GPUconfigure(void);\r
86 long CALLBACK GPUtest(void);\r
87 void CALLBACK GPUabout(void);\r
88 #endif\r
89 \r
90 void           DoSnapShot(void);\r
91 void               GPUvSinc(void);\r
92 void           updateDisplay(void);\r
93 void           updateFrontDisplay(void);\r
94 void           SetAutoFrameCap(void);\r
95 void           SetAspectRatio(void);\r
96 void           CheckVRamRead(int x, int y, int dx, int dy, bool bFront);\r
97 void           CheckVRamReadEx(int x, int y, int dx, int dy);\r
98 void           SetFixes(void);\r
99 \r
100 void PaintPicDot(unsigned char * p,unsigned char c);\r
101 //void DrawNumBorPic(unsigned char *pMem, int lSelectedSlot);\r
102 void ResizeWindow();\r
103 \r
104 ////////////////////////////////////////////////////////////////////////////\r
105 #ifdef __cplusplus\r
106 }\r
107 #endif \r
108 \r
109 \r
110 #endif // _GPU_INTERNALS_H\r