-
Notifications
You must be signed in to change notification settings - Fork 0
/
vga256.h
263 lines (261 loc) · 12.9 KB
/
vga256.h
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
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
#ifndef CHARLIE86_VGA256_H
#define CHARLIE86_VGA256_H
uint32_t vga256_to_rgb[] = { // VGA256 colour pallete as RGB values
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (2<<8) + 170), // RGB: 0002aa
((20<<16) + (170<<8) + 0), // RGB: 14aa00
((0<<16) + (170<<8) + 170), // RGB: 00aaaa
((170<<16) + (0<<8) + 3), // RGB: aa0003
((170<<16) + (0<<8) + 170), // RGB: aa00aa
((170<<16) + (85<<8) + 0), // RGB: aa5500
((170<<16) + (170<<8) + 170), // RGB: aaaaaa
((85<<16) + (85<<8) + 85), // RGB: 555555
((85<<16) + (85<<8) + 255), // RGB: 5555ff
((85<<16) + (255<<8) + 85), // RGB: 55ff55
((85<<16) + (255<<8) + 255), // RGB: 55ffff
((255<<16) + (85<<8) + 85), // RGB: ff5555
((253<<16) + (85<<8) + 255), // RGB: fd55ff
((255<<16) + (255<<8) + 85), // RGB: ffff55
((255<<16) + (255<<8) + 255), // RGB: ffffff
((0<<16) + (0<<8) + 0), // RGB: 000000
((16<<16) + (16<<8) + 16), // RGB: 101010
((32<<16) + (32<<8) + 32), // RGB: 202020
((53<<16) + (53<<8) + 53), // RGB: 353535
((69<<16) + (69<<8) + 69), // RGB: 454545
((85<<16) + (85<<8) + 85), // RGB: 555555
((101<<16) + (101<<8) + 101), // RGB: 656565
((117<<16) + (117<<8) + 117), // RGB: 757575
((138<<16) + (138<<8) + 138), // RGB: 8a8a8a
((154<<16) + (154<<8) + 154), // RGB: 9a9a9a
((170<<16) + (170<<8) + 170), // RGB: aaaaaa
((186<<16) + (186<<8) + 186), // RGB: bababa
((202<<16) + (202<<8) + 202), // RGB: cacaca
((223<<16) + (223<<8) + 223), // RGB: dfdfdf
((239<<16) + (239<<8) + 239), // RGB: efefef
((255<<16) + (255<<8) + 255), // RGB: ffffff
((0<<16) + (4<<8) + 255), // RGB: 0004ff
((65<<16) + (4<<8) + 255), // RGB: 4104ff
((130<<16) + (3<<8) + 255), // RGB: 8203ff
((190<<16) + (2<<8) + 255), // RGB: be02ff
((253<<16) + (0<<8) + 255), // RGB: fd00ff
((254<<16) + (0<<8) + 190), // RGB: fe00be
((255<<16) + (0<<8) + 130), // RGB: ff0082
((255<<16) + (0<<8) + 65), // RGB: ff0041
((255<<16) + (0<<8) + 8), // RGB: ff0008
((255<<16) + (65<<8) + 5), // RGB: ff4105
((255<<16) + (130<<8) + 0), // RGB: ff8200
((255<<16) + (190<<8) + 0), // RGB: ffbe00
((255<<16) + (255<<8) + 0), // RGB: ffff00
((190<<16) + (255<<8) + 0), // RGB: beff00
((130<<16) + (255<<8) + 0), // RGB: 82ff00
((65<<16) + (255<<8) + 1), // RGB: 41ff01
((36<<16) + (255<<8) + 0), // RGB: 24ff00
((34<<16) + (255<<8) + 66), // RGB: 22ff42
((29<<16) + (255<<8) + 130), // RGB: 1dff82
((18<<16) + (255<<8) + 190), // RGB: 12ffbe
((0<<16) + (255<<8) + 255), // RGB: 00ffff
((0<<16) + (190<<8) + 255), // RGB: 00beff
((1<<16) + (130<<8) + 255), // RGB: 0182ff
((0<<16) + (65<<8) + 255), // RGB: 0041ff
((130<<16) + (130<<8) + 255), // RGB: 8282ff
((158<<16) + (130<<8) + 255), // RGB: 9e82ff
((190<<16) + (130<<8) + 255), // RGB: be82ff
((223<<16) + (130<<8) + 255), // RGB: df82ff
((253<<16) + (130<<8) + 255), // RGB: fd82ff
((254<<16) + (130<<8) + 223), // RGB: fe82df
((255<<16) + (130<<8) + 190), // RGB: ff82be
((255<<16) + (130<<8) + 158), // RGB: ff829e
((255<<16) + (130<<8) + 130), // RGB: ff8282
((255<<16) + (158<<8) + 130), // RGB: ff9e82
((255<<16) + (190<<8) + 130), // RGB: ffbe82
((255<<16) + (223<<8) + 130), // RGB: ffdf82
((255<<16) + (255<<8) + 130), // RGB: ffff82
((223<<16) + (255<<8) + 130), // RGB: dfff82
((190<<16) + (255<<8) + 130), // RGB: beff82
((158<<16) + (255<<8) + 130), // RGB: 9eff82
((130<<16) + (255<<8) + 130), // RGB: 82ff82
((130<<16) + (255<<8) + 158), // RGB: 82ff9e
((130<<16) + (255<<8) + 190), // RGB: 82ffbe
((130<<16) + (255<<8) + 223), // RGB: 82ffdf
((130<<16) + (255<<8) + 255), // RGB: 82ffff
((130<<16) + (223<<8) + 255), // RGB: 82dfff
((130<<16) + (190<<8) + 255), // RGB: 82beff
((130<<16) + (158<<8) + 255), // RGB: 829eff
((186<<16) + (186<<8) + 255), // RGB: babaff
((202<<16) + (186<<8) + 255), // RGB: cabaff
((223<<16) + (186<<8) + 255), // RGB: dfbaff
((239<<16) + (186<<8) + 255), // RGB: efbaff
((254<<16) + (186<<8) + 255), // RGB: febaff
((254<<16) + (186<<8) + 239), // RGB: febaef
((255<<16) + (186<<8) + 223), // RGB: ffbadf
((255<<16) + (186<<8) + 202), // RGB: ffbaca
((255<<16) + (186<<8) + 186), // RGB: ffbaba
((255<<16) + (202<<8) + 186), // RGB: ffcaba
((255<<16) + (223<<8) + 186), // RGB: ffdfba
((255<<16) + (239<<8) + 186), // RGB: ffefba
((255<<16) + (255<<8) + 186), // RGB: ffffba
((239<<16) + (255<<8) + 186), // RGB: efffba
((223<<16) + (255<<8) + 186), // RGB: dfffba
((202<<16) + (255<<8) + 187), // RGB: caffbb
((186<<16) + (255<<8) + 186), // RGB: baffba
((186<<16) + (255<<8) + 202), // RGB: baffca
((186<<16) + (255<<8) + 223), // RGB: baffdf
((186<<16) + (255<<8) + 239), // RGB: baffef
((186<<16) + (255<<8) + 255), // RGB: baffff
((186<<16) + (239<<8) + 255), // RGB: baefff
((186<<16) + (223<<8) + 255), // RGB: badfff
((186<<16) + (202<<8) + 255), // RGB: bacaff
((1<<16) + (1<<8) + 113), // RGB: 010171
((28<<16) + (1<<8) + 113), // RGB: 1c0171
((57<<16) + (1<<8) + 113), // RGB: 390171
((85<<16) + (0<<8) + 113), // RGB: 550071
((113<<16) + (0<<8) + 113), // RGB: 710071
((113<<16) + (0<<8) + 85), // RGB: 710055
((113<<16) + (0<<8) + 57), // RGB: 710039
((113<<16) + (0<<8) + 28), // RGB: 71001c
((113<<16) + (0<<8) + 1), // RGB: 710001
((113<<16) + (28<<8) + 1), // RGB: 711c01
((113<<16) + (57<<8) + 0), // RGB: 713900
((113<<16) + (85<<8) + 0), // RGB: 715500
((113<<16) + (113<<8) + 0), // RGB: 717100
((85<<16) + (113<<8) + 0), // RGB: 557100
((57<<16) + (113<<8) + 0), // RGB: 397100
((28<<16) + (113<<8) + 0), // RGB: 1c7100
((9<<16) + (113<<8) + 0), // RGB: 097100
((9<<16) + (113<<8) + 28), // RGB: 09711c
((6<<16) + (113<<8) + 57), // RGB: 067139
((3<<16) + (113<<8) + 85), // RGB: 037155
((0<<16) + (113<<8) + 113), // RGB: 007171
((0<<16) + (85<<8) + 113), // RGB: 005571
((0<<16) + (57<<8) + 113), // RGB: 003971
((0<<16) + (28<<8) + 113), // RGB: 001c71
((57<<16) + (57<<8) + 113), // RGB: 393971
((69<<16) + (57<<8) + 113), // RGB: 453971
((85<<16) + (57<<8) + 113), // RGB: 553971
((97<<16) + (57<<8) + 113), // RGB: 613971
((113<<16) + (57<<8) + 113), // RGB: 713971
((113<<16) + (57<<8) + 97), // RGB: 713961
((113<<16) + (57<<8) + 85), // RGB: 713955
((113<<16) + (57<<8) + 69), // RGB: 713945
((113<<16) + (57<<8) + 57), // RGB: 713939
((113<<16) + (69<<8) + 57), // RGB: 714539
((113<<16) + (85<<8) + 57), // RGB: 715539
((113<<16) + (97<<8) + 57), // RGB: 716139
((113<<16) + (113<<8) + 57), // RGB: 717139
((97<<16) + (113<<8) + 57), // RGB: 617139
((85<<16) + (113<<8) + 57), // RGB: 557139
((69<<16) + (113<<8) + 58), // RGB: 45713a
((57<<16) + (113<<8) + 57), // RGB: 397139
((57<<16) + (113<<8) + 69), // RGB: 397145
((57<<16) + (113<<8) + 85), // RGB: 397155
((57<<16) + (113<<8) + 97), // RGB: 397161
((57<<16) + (113<<8) + 113), // RGB: 397171
((57<<16) + (97<<8) + 113), // RGB: 396171
((57<<16) + (85<<8) + 113), // RGB: 395571
((57<<16) + (69<<8) + 114), // RGB: 394572
((81<<16) + (81<<8) + 113), // RGB: 515171
((89<<16) + (81<<8) + 113), // RGB: 595171
((97<<16) + (81<<8) + 113), // RGB: 615171
((105<<16) + (81<<8) + 113), // RGB: 695171
((113<<16) + (81<<8) + 113), // RGB: 715171
((113<<16) + (81<<8) + 105), // RGB: 715169
((113<<16) + (81<<8) + 97), // RGB: 715161
((113<<16) + (81<<8) + 89), // RGB: 715159
((113<<16) + (81<<8) + 81), // RGB: 715151
((113<<16) + (89<<8) + 81), // RGB: 715951
((113<<16) + (97<<8) + 81), // RGB: 716151
((113<<16) + (105<<8) + 81), // RGB: 716951
((113<<16) + (113<<8) + 81), // RGB: 717151
((105<<16) + (113<<8) + 81), // RGB: 697151
((97<<16) + (113<<8) + 81), // RGB: 617151
((89<<16) + (113<<8) + 81), // RGB: 597151
((81<<16) + (113<<8) + 81), // RGB: 517151
((81<<16) + (113<<8) + 90), // RGB: 51715a
((81<<16) + (113<<8) + 97), // RGB: 517161
((81<<16) + (113<<8) + 105), // RGB: 517169
((81<<16) + (113<<8) + 113), // RGB: 517171
((81<<16) + (105<<8) + 113), // RGB: 516971
((81<<16) + (97<<8) + 113), // RGB: 516171
((81<<16) + (89<<8) + 113), // RGB: 515971
((0<<16) + (0<<8) + 66), // RGB: 000042
((17<<16) + (0<<8) + 65), // RGB: 110041
((32<<16) + (0<<8) + 65), // RGB: 200041
((49<<16) + (0<<8) + 65), // RGB: 310041
((65<<16) + (0<<8) + 65), // RGB: 410041
((65<<16) + (0<<8) + 50), // RGB: 410032
((65<<16) + (0<<8) + 32), // RGB: 410020
((65<<16) + (0<<8) + 16), // RGB: 410010
((65<<16) + (0<<8) + 0), // RGB: 410000
((65<<16) + (16<<8) + 0), // RGB: 411000
((65<<16) + (32<<8) + 0), // RGB: 412000
((65<<16) + (49<<8) + 0), // RGB: 413100
((65<<16) + (65<<8) + 0), // RGB: 414100
((49<<16) + (65<<8) + 0), // RGB: 314100
((32<<16) + (65<<8) + 0), // RGB: 204100
((16<<16) + (65<<8) + 0), // RGB: 104100
((3<<16) + (65<<8) + 0), // RGB: 034100
((3<<16) + (65<<8) + 16), // RGB: 034110
((2<<16) + (65<<8) + 32), // RGB: 024120
((1<<16) + (65<<8) + 49), // RGB: 014131
((0<<16) + (65<<8) + 65), // RGB: 004141
((0<<16) + (49<<8) + 65), // RGB: 003141
((0<<16) + (32<<8) + 65), // RGB: 002041
((0<<16) + (16<<8) + 65), // RGB: 001041
((32<<16) + (32<<8) + 65), // RGB: 202041
((40<<16) + (32<<8) + 65), // RGB: 282041
((49<<16) + (32<<8) + 65), // RGB: 312041
((57<<16) + (32<<8) + 65), // RGB: 392041
((65<<16) + (32<<8) + 65), // RGB: 412041
((65<<16) + (32<<8) + 57), // RGB: 412039
((65<<16) + (32<<8) + 49), // RGB: 412031
((65<<16) + (32<<8) + 40), // RGB: 412028
((65<<16) + (32<<8) + 32), // RGB: 412020
((65<<16) + (40<<8) + 32), // RGB: 412820
((65<<16) + (49<<8) + 32), // RGB: 413120
((65<<16) + (57<<8) + 33), // RGB: 413921
((65<<16) + (65<<8) + 32), // RGB: 414120
((57<<16) + (65<<8) + 32), // RGB: 394120
((49<<16) + (65<<8) + 32), // RGB: 314120
((40<<16) + (65<<8) + 32), // RGB: 284120
((32<<16) + (65<<8) + 32), // RGB: 204120
((32<<16) + (65<<8) + 40), // RGB: 204128
((32<<16) + (65<<8) + 49), // RGB: 204131
((32<<16) + (65<<8) + 57), // RGB: 204139
((32<<16) + (65<<8) + 65), // RGB: 204141
((32<<16) + (57<<8) + 65), // RGB: 203941
((32<<16) + (49<<8) + 65), // RGB: 203141
((32<<16) + (40<<8) + 65), // RGB: 202841
((45<<16) + (45<<8) + 65), // RGB: 2d2d41
((49<<16) + (45<<8) + 65), // RGB: 312d41
((53<<16) + (45<<8) + 65), // RGB: 352d41
((61<<16) + (45<<8) + 65), // RGB: 3d2d41
((65<<16) + (45<<8) + 65), // RGB: 412d41
((65<<16) + (45<<8) + 61), // RGB: 412d3d
((65<<16) + (45<<8) + 53), // RGB: 412d35
((65<<16) + (45<<8) + 49), // RGB: 412d31
((65<<16) + (45<<8) + 45), // RGB: 412d2d
((65<<16) + (49<<8) + 45), // RGB: 41312d
((65<<16) + (53<<8) + 45), // RGB: 41352d
((65<<16) + (61<<8) + 45), // RGB: 413d2d
((65<<16) + (65<<8) + 45), // RGB: 41412d
((61<<16) + (65<<8) + 45), // RGB: 3d412d
((53<<16) + (65<<8) + 45), // RGB: 35412d
((49<<16) + (65<<8) + 45), // RGB: 31412d
((45<<16) + (65<<8) + 45), // RGB: 2d412d
((45<<16) + (65<<8) + 49), // RGB: 2d4131
((45<<16) + (65<<8) + 53), // RGB: 2d4135
((45<<16) + (65<<8) + 61), // RGB: 2d413d
((45<<16) + (65<<8) + 65), // RGB: 2d4141
((45<<16) + (61<<8) + 65), // RGB: 2d3d41
((45<<16) + (53<<8) + 65), // RGB: 2d3541
((45<<16) + (49<<8) + 65), // RGB: 2d3141
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
((0<<16) + (0<<8) + 0), // RGB: 000000
};
#endif //CHARLIE86_VGA256_H