~ubuntu-branches/ubuntu/wily/mupen64plus/wily

« back to all changes in this revision

Viewing changes to roms/mupen64plus/include/config.h

  • Committer: Bazaar Package Importer
  • Author(s): Sven Eckelmann
  • Date: 2011-07-24 14:23:26 UTC
  • mfrom: (10.1.2 experimental)
  • Revision ID: james.westby@ubuntu.com-20110724142326-x9z5qu8j9jecrmod
Tags: 1.99.4+2
* Upload to unstable
* Remove overrides for lintian warning about change to native package
* Update Vcs-* fields to new anonscm.debian.org URLs in debian/control
* Fix spelling of "Flexible" in debian/control (Closes: #633693)
* Mark all targets in debian/rules as phony
* Add some information about the mupen64plus 2.0 vision in debian/NEWS

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2
 
 *   Mupen64plus - config.h                                                *
3
 
 *   Mupen64Plus homepage: http://code.google.com/p/mupen64plus/           *
4
 
 *   Copyright (C) 2008 Marshallh                                          *
5
 
 *                                                                         *
6
 
 *   This program is free software; you can redistribute it and/or modify  *
7
 
 *   it under the terms of the GNU General Public License as published by  *
8
 
 *   the Free Software Foundation; either version 2 of the License, or     *
9
 
 *   (at your option) any later version.                                   *
10
 
 *                                                                         *
11
 
 *   This program is distributed in the hope that it will be useful,       *
12
 
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
13
 
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
14
 
 *   GNU General Public License for more details.                          *
15
 
 *                                                                         *
16
 
 *   You should have received a copy of the GNU General Public License     *
17
 
 *   along with this program; if not, write to the                         *
18
 
 *   Free Software Foundation, Inc.,                                       *
19
 
 *   51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.          *
20
 
 * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
21
 
 
22
 
#ifndef __CONFIG_H__
23
 
#define __CONFIG_H__
24
 
 
25
 
#include <ultra64.h>
26
 
 
27
 
/* Controllers */
28
 
#define NUM_CONT 4
29
 
 
30
 
/* Screen */
31
 
#define SCREEN_WIDTH  320
32
 
#define SCREEN_HEIGHT 240
33
 
 
34
 
#define SCREEN_BPP_16
35
 
 
36
 
#define SCREEN_MODE OS_VI_NTSC_LAN1 /* 16-bit 320x240 */
37
 
/* #define SCREEN_MODE OS_VI_NTSC_LAN2 /* 32-bit 320x240 */
38
 
/* #define SCREEN_MODE OS_VI_NTSC_HAN1 /* 16-bit 640x480 normal */
39
 
/* #define SCREEN_MODE OS_VI_NTSC_HAF1 /* 16-bit 640x480 deflicker */
40
 
 
41
 
#define NUM_CFB 2
42
 
 
43
 
/* Maximum items drawn at once. */
44
 
#define MAX_ENTITIES 128
45
 
 
46
 
/* Stack size. */
47
 
#define STACKSIZE 0x2000
48
 
 
49
 
/* FIFO buffer size. */
50
 
#define FIFOSIZE 131072 /* will require 256k */
51
 
 
52
 
/* RSP segment numbers. */
53
 
#define STATIC_SEG  1
54
 
#define DYNAMIC_SEG 2
55
 
 
56
 
/* Message queue lengths. */
57
 
#define PI_MSGQUEUE_SIZE      8
58
 
#define DMA_MSGQUEUE_SIZE     1
59
 
#define RDPDONE_MSGQUEUE_SIZE 1
60
 
#define RSPDONE_MSGQUEUE_SIZE 1
61
 
#define RETRACE_MSGQUEUE_SIZE 1
62
 
 
63
 
/* Main display list size. */
64
 
#define GDL_SIZE 32768
65
 
 
66
 
/* Thread priorities. */
67
 
#define MAIN_PRIORITY 10
68
 
#define GAME_PRIORITY 10
69
 
 
70
 
/* Thread ID. */
71
 
#define MAIN_ID 3
72
 
#define GAME_ID 4
73
 
 
74
 
/* Misc defines. */
75
 
#define NO  0
76
 
#define YES 1
77
 
 
78
 
#define _rsp_staticSegmentRomStart ((u32)_static_seg_org)
79
 
#define _rsp_staticSegmentRomEnd ((u32)_static_seg_org+(u32)_static_seg_size)
80
 
#define _cfbSegmentStart (_cfb_obj)
81
 
#define _codeSegmentEnd ((u32)_code_bss_obj+(u32)_code_bss_size)
82
 
 
83
 
typedef struct
84
 
{
85
 
    Mtx proj;
86
 
    Mtx view;
87
 
    Mtx xform[MAX_ENTITIES];
88
 
    Gfx glist[GDL_SIZE];
89
 
}
90
 
Dynamic;
91
 
 
92
 
extern u32 ScreenClearColor;
93
 
extern u64 _rspdrambuf[];
94
 
extern u16 _zbuf[];
95
 
 
96
 
/* CFB */
97
 
#ifdef SCREEN_BPP_8
98
 
extern u8  _cfb[NUM_CFB][SCREEN_WIDTH * SCREEN_HEIGHT]; /* 8-bit */
99
 
#else
100
 
#ifdef SCREEN_BPP_16
101
 
extern u16 _cfb[NUM_CFB][SCREEN_WIDTH * SCREEN_HEIGHT]; /* 16-bit */
102
 
#else
103
 
#ifdef SCREEN_BPP_32
104
 
extern u32 _cfb[NUM_CFB][SCREEN_WIDTH * SCREEN_HEIGHT]; /* 32-bit */
105
 
#endif
106
 
#endif
107
 
#endif
108
 
 
109
 
/* Frame buffer variables. */
110
 
 
111
 
#ifdef SCREEN_BPP_8
112
 
extern u8* Logical_CFB; /* 8-bit */
113
 
extern u8* Next_CFB;
114
 
extern u8* Next2_CFB;
115
 
extern u16 CFB_Count;
116
 
extern u16 CFB_NextCount;
117
 
extern u16 CFB_NextCount2;
118
 
#else
119
 
#ifdef SCREEN_BPP_16
120
 
extern u16* Logical_CFB; /* 16-bit */
121
 
extern u16* Next_CFB;
122
 
extern u16* Next2_CFB;
123
 
extern u16 CFB_Count;
124
 
extern u16 CFB_NextCount;
125
 
extern u16 CFB_NextCount2;
126
 
#else
127
 
#ifdef SCREEN_BPP_32
128
 
extern u32* Logical_CFB; /* 32-bit */
129
 
extern u32* Next_CFB;
130
 
extern u32* Next2_CFB;
131
 
extern u16 CFB_Count;
132
 
extern u16 CFB_NextCount;
133
 
extern u16 CFB_NextCount2;
134
 
#endif
135
 
#endif
136
 
#endif
137
 
 
138
 
extern Gfx* gdl_end;
139
 
extern Gfx* gdl_start;
140
 
extern OSTask task[];
141
 
extern Dynamic* generate;
142
 
 
143
 
extern int entity;
144
 
extern char* rsp_static_addr;
145
 
extern char* rsp_static_end;
146
 
extern u32 rsp_static_len;
147
 
 
148
 
extern Gfx rspinit_dl[];
149
 
extern Gfx rdpinit_dl[];
150
 
extern Gfx scrnclr_dl[];
151
 
 
152
 
extern Vp vp;
153
 
 
154
 
/* Message queues. */
155
 
extern OSMesg      PiMessages[];
156
 
extern OSMesgQueue PiMessageQ;
157
 
extern OSMesg      DMAMessages[];
158
 
extern OSMesgQueue DMAMessageQ;
159
 
extern OSMesg      RDPDoneMessages[];
160
 
extern OSMesgQueue RDPDoneMessageQ;
161
 
extern OSMesg      RSPDoneMessages[];
162
 
extern OSMesgQueue RSPDoneMessageQ;
163
 
extern OSMesg      RetraceMessages[];
164
 
extern OSMesgQueue RetraceMessageQ;
165
 
 
166
 
/* Symbols to tell us where various segments are
167
 
 * in cartridge ROM, and in RDRAM.
168
 
 */
169
 
extern char _static_seg_org[];
170
 
extern char _static_seg_size[];
171
 
extern char _static_seg_obj[];
172
 
extern char _rom_seg_org[];
173
 
extern char _rom_seg_size[];
174
 
extern char _cfb_obj[];
175
 
extern char _code_bss_obj[];
176
 
extern char _code_bss_size[];
177
 
 
178
 
extern u64 fifobuffer[];
179
 
extern u8* fifosize;
180
 
 
181
 
extern Gfx N64DLinitRSP[];
182
 
extern Gfx N64DLinitRDP[];
183
 
extern Gfx N64DLclearZbuffer[];
184
 
extern Gfx N64DLset3dRenderMode[];
185
 
 
186
 
extern Vp vp;
187
 
extern Lights1 light1;
188
 
 
189
 
void boot(void*);
190
 
 
191
 
#endif /* __CONFIG_H__ */