This repository has been archived by the owner on Jan 19, 2024. It is now read-only.
forked from n64decomp/sm64
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtitle_screen_bg.c
211 lines (176 loc) · 7.02 KB
/
title_screen_bg.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
#include <ultra64.h>
#include "sm64.h"
#include "make_const_nonconst.h"
// 0x0A000000 - 0x0A000100
static const Vtx title_screen_bg_vertex_0A000000[] = {
{{{ 0, 60, -1}, 0, { 0, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 60, -1}, 0, { 2528, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 80, -1}, 0, { 2528, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 80, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 40, -1}, 0, { 0, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 40, -1}, 0, { 2528, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 60, -1}, 0, { 2528, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 60, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 20, -1}, 0, { 0, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 20, -1}, 0, { 2528, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 40, -1}, 0, { 2528, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 40, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 0, -1}, 0, { 0, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 0, -1}, 0, { 2528, 608}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 80, 20, -1}, 0, { 2528, 0}, {0xff, 0xff, 0xff, 0xff}}},
{{{ 0, 20, -1}, 0, { 0, 0}, {0xff, 0xff, 0xff, 0xff}}},
};
// 0x0A000100 - 0x0A000118
const Gfx title_screen_bg_dl_0A000100[] = {
gsDPSetCombineMode(G_CC_DECALRGB, G_CC_DECALRGB),
gsDPSetRenderMode(G_RM_AA_OPA_SURF, G_RM_AA_OPA_SURF2),
gsSPEndDisplayList(),
};
// 0x0A000118 - 0x0A000130
const Gfx title_screen_bg_dl_0A000118[] = {
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
gsSPVertex(title_screen_bg_vertex_0A000000, 16, 0),
gsSPEndDisplayList(),
};
// 0x0A000130 - 0x0A000148
const Gfx title_screen_bg_dl_0A000130[] = {
gsSP2Triangles( 0, 1, 2, 0x0, 0, 2, 3, 0x0),
gsSPEndDisplayList(),
};
// 0x0A000148 - 0x0A000160
const Gfx title_screen_bg_dl_0A000148[] = {
gsSP2Triangles( 4, 5, 6, 0x0, 4, 6, 7, 0x0),
gsSPEndDisplayList(),
};
// 0x0A000160 - 0x0A000178
const Gfx title_screen_bg_dl_0A000160[] = {
gsSP2Triangles( 8, 9, 10, 0x0, 8, 10, 11, 0x0),
gsSPEndDisplayList(),
};
// 0x0A000178 - 0x0A000190
const Gfx title_screen_bg_dl_0A000178[] = {
gsSP2Triangles(12, 13, 14, 0x0, 12, 14, 15, 0x0),
gsSPEndDisplayList(),
};
// 0x0A000190 - 0x0A0001C0
const Gfx title_screen_bg_dl_0A000190[] = {
gsDPPipeSync(),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF),
gsSPSetGeometryMode(G_LIGHTING),
gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE),
gsDPSetRenderMode(G_RM_AA_ZB_OPA_SURF, G_RM_AA_ZB_OPA_SURF2),
gsSPEndDisplayList(),
};
#if defined(VERSION_CN)
// 0x0A0001C0
ALIGNED8 static const Texture title_texture_0A0001C0[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.001C0.rgba16.inc.c"
};
// 0x0A000E40
ALIGNED8 static const Texture title_texture_0A000E40[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.00E40.rgba16.inc.c"
};
// 0x0A001AC0
ALIGNED8 static const Texture title_texture_0A001AC0[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.01AC0.rgba16.inc.c"
};
// 0x0A002740
ALIGNED8 static const Texture title_texture_0A002740[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.02740.rgba16.inc.c"
};
// 0x0A0033C0
ALIGNED8 static const Texture title_texture_0A0033C0[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.033C0.rgba16.inc.c"
};
// 0x0A004040
ALIGNED8 static const Texture title_texture_0A004040[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.04040.rgba16.inc.c"
};
// 0x0A004CC0
ALIGNED8 static const Texture title_texture_0A004CC0[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.04CC0.rgba16.inc.c"
};
// 0x0A005940
ALIGNED8 static const Texture title_texture_0A005940[] = {
#include "textures/title_screen_bg/title_screen_bg_ique.05940.rgba16.inc.c"
};
#else
// 0x0A0001C0
ALIGNED8 static const Texture title_texture_0A0001C0[] = {
#include "textures/title_screen_bg/title_screen_bg.001C0.rgba16.inc.c"
};
// 0x0A000E40
ALIGNED8 static const Texture title_texture_0A000E40[] = {
#include "textures/title_screen_bg/title_screen_bg.00E40.rgba16.inc.c"
};
// 0x0A001AC0
ALIGNED8 static const Texture title_texture_0A001AC0[] = {
#include "textures/title_screen_bg/title_screen_bg.01AC0.rgba16.inc.c"
};
// 0x0A002740
ALIGNED8 static const Texture title_texture_0A002740[] = {
#include "textures/title_screen_bg/title_screen_bg.02740.rgba16.inc.c"
};
// 0x0A0033C0
ALIGNED8 static const Texture title_texture_0A0033C0[] = {
#include "textures/title_screen_bg/title_screen_bg.033C0.rgba16.inc.c"
};
// 0x0A004040
ALIGNED8 static const Texture title_texture_0A004040[] = {
#include "textures/title_screen_bg/title_screen_bg.04040.rgba16.inc.c"
};
// 0x0A004CC0
ALIGNED8 static const Texture title_texture_0A004CC0[] = {
#include "textures/title_screen_bg/title_screen_bg.04CC0.rgba16.inc.c"
};
// 0x0A005940
ALIGNED8 static const Texture title_texture_0A005940[] = {
#include "textures/title_screen_bg/title_screen_bg.05940.rgba16.inc.c"
};
#endif
// 0x0A0065C0
const Texture *const mario_title_texture_table[] = {
title_texture_0A0001C0, title_texture_0A000E40, title_texture_0A001AC0, title_texture_0A002740,
};
// 0x0A0065D0
const Texture *const game_over_texture_table[] = {
title_texture_0A0033C0, title_texture_0A004040, title_texture_0A004CC0, title_texture_0A005940,
};
UNUSED static const u64 title_screen_bg_unused_0 = 0;
#if defined(VERSION_SH) || defined(VERSION_CN)
const Gfx title_screen_bg_dl_0A0065E8[] = {
gsDPPipeSync(),
gsDPSetCycleType(G_CYC_COPY),
gsDPSetTexturePersp(G_TP_NONE),
gsDPSetTextureFilter(G_TF_POINT),
gsDPSetRenderMode(G_RM_NOOP, G_RM_NOOP2),
gsSPEndDisplayList(),
};
const Gfx title_screen_bg_dl_0A006618[] = {
gsDPPipeSync(),
gsDPSetCycleType(G_CYC_1CYCLE),
gsDPSetTexturePersp(G_TP_PERSP),
gsDPSetTextureFilter(G_TF_BILERP),
gsDPSetRenderMode(G_RM_AA_ZB_OPA_SURF, G_RM_AA_ZB_OPA_SURF2),
gsSPEndDisplayList(),
};
ALIGNED8 static const u8 title_texture_rumble_pak[] = {
#include "textures/title_screen_bg/title_screen_bg.06648.rgba16.inc.c"
};
const Gfx title_screen_bg_dl_0A007548[] = {
gsDPPipeSync(),
gsDPSetCycleType(G_CYC_COPY),
gsDPSetTexturePersp(G_TP_NONE),
gsDPSetTextureFilter(G_TF_POINT),
gsDPSetRenderMode(G_RM_NOOP, G_RM_NOOP2),
gsDPSetScissor(G_SC_NON_INTERLACE, 0, 0, 319, 239),
gsDPLoadTextureTile(title_texture_rumble_pak, G_IM_FMT_RGBA, G_IM_SIZ_16b, 80, 0, 0, 0, 79, 23, 0, G_TX_NOMIRROR | G_TX_CLAMP, G_TX_NOMIRROR | G_TX_CLAMP, 7, 5, G_TX_NOLOD, G_TX_NOLOD),
gsSPTextureRectangle(220 << 2, 200 << 2, 299 << 2, 223 << 2, G_TX_RENDERTILE, 0, 0, 4 << 10, 1 << 10),
gsDPPipeSync(),
gsDPSetCycleType(G_CYC_1CYCLE),
gsDPSetTexturePersp(G_TP_PERSP),
gsDPSetTextureFilter(G_TF_BILERP),
gsDPSetRenderMode(G_RM_AA_ZB_OPA_SURF, G_RM_AA_ZB_OPA_SURF2),
gsSPEndDisplayList(),
};
#endif