cc68a136 |
1 | \r |
2 | #include <stdio.h>\r |
3 | \r |
cc68a136 |
4 | #define WIN32_LEAN_AND_MEAN\r |
5 | #include <windows.h>\r |
6 | #include <d3d8.h>\r |
cc68a136 |
7 | \r |
8 | #include <d3dx8.h>\r |
9 | \r |
4b2b67eb |
10 | #include <Pico/Pico.h>\r |
cc68a136 |
11 | \r |
12 | #define PI 3.14159265f\r |
13 | \r |
14 | #define RELEASE(x) if (x) x->Release(); x=NULL;\r |
15 | \r |
cc68a136 |
16 | \r |
17 | // Emu.cpp\r |
18 | extern unsigned short *EmuScreen;\r |
19 | extern int EmuWidth,EmuHeight;\r |
20 | int EmuInit();\r |
21 | void EmuExit();\r |
22 | int EmuRomLoad(char *name);\r |
23 | int EmuFrame();\r |
24 | \r |
25 | // Input.cpp\r |
26 | struct Input\r |
27 | {\r |
28 | short axis[4];\r |
29 | unsigned char button[16];\r |
30 | unsigned char held[16]; // How long has the button been held\r |
31 | char repeat[16]; // Auto-repeat\r |
32 | };\r |
33 | extern struct Input Inp;\r |
34 | int InputInit();\r |
35 | void InputExit();\r |
36 | int InputUpdate();\r |
37 | int InputLightCal(int cx,int cy,int ux,int uy);\r |
38 | \r |
39 | // LightCal.cpp\r |
40 | int LightCalReset();\r |
41 | int LightCalUpdate();\r |
42 | int LightCalRender();\r |
43 | \r |
44 | // Loop.cpp\r |
cc68a136 |
45 | extern char LoopQuit;\r |
46 | extern int LoopMode;\r |
47 | \r |
48 | int LoopInit();\r |
49 | void LoopExit();\r |
50 | int LoopCode();\r |
4b2b67eb |
51 | //extern "C" int dprintf(char *format, ...);\r |
52 | extern "C" int dprintf2(char *format, ...);\r |
cc68a136 |
53 | \r |
54 | // Main.cpp\r |
8831ef19 |
55 | extern char *romname;\r |
cc68a136 |
56 | extern HWND FrameWnd;\r |
57 | extern int MainWidth,MainHeight;\r |
4b2b67eb |
58 | extern void error(char *text);\r |
cc68a136 |
59 | \r |
60 | // Rom.cpp\r |
61 | extern unsigned char *RomData;\r |
62 | extern int RomLen;\r |
63 | extern char RomName[260];\r |
64 | int RomLoad();\r |
65 | void RomFree();\r |
66 | \r |
67 | // --------------------------------------------\r |
68 | // Direct.cpp\r |
69 | extern IDirect3DDevice8 *Device;\r |
70 | extern IDirect3DSurface8 *DirectBack; // Back Buffer\r |
71 | int DirectInit();\r |
72 | int DirectClear(unsigned int colour);\r |
73 | int DirectScreen();\r |
74 | int DirectPresent();\r |
75 | void DirectExit();\r |
76 | \r |
77 | // DSound.cpp:\r |
78 | int DSoundInit();\r |
79 | void DSoundExit();\r |
80 | int DSoundUpdate();\r |
81 | extern short *DSoundNext; // Buffer for next sound data to put in loop\r |
82 | //extern int DSoundSeg; // Seg length in samples\r |
83 | void DSoundMute();\r |
84 | void DSoundUnMute();\r |
85 | \r |
86 | // Font.cpp\r |
87 | int FontInit();\r |
88 | void FontExit();\r |
89 | int FontSetColour(unsigned int colour);\r |
90 | int FontText(WCHAR *,int,int);\r |
91 | \r |
92 | // TexScreen.cpp\r |
93 | extern IDirect3DTexture8 *TexScreen;\r |
94 | extern int TexWidth,TexHeight;\r |
95 | int TexScreenInit();\r |
96 | void TexScreenExit();\r |
97 | int TexScreenSwizzle();\r |
98 | int TexScreenLinear();\r |