├── .gitattributes
├── .github
└── FUNDING.yml
├── .gitignore
├── CMakeLists.txt
├── LICENSE.txt
├── font.h
├── main.c
├── math_utils.c
├── math_utils.h
├── reRescaler.yml
├── renderer.c
├── renderer.h
└── shaders
├── lcd3x_f.h
├── lcd3x_v.h
├── sharp_bilinear_f.h
├── sharp_bilinear_simple_f.h
├── sharp_bilinear_simple_v.h
├── sharp_bilinear_v.h
├── src
├── lcd3x_f.cg
├── lcd3x_v.cg
├── sharp_bilinear_f.cg
├── sharp_bilinear_simple_f.cg
├── sharp_bilinear_simple_v.cg
├── sharp_bilinear_v.cg
├── texture2d_f.cg
└── texture2d_v.cg
├── texture2d_f.h
└── texture2d_v.h
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
4 | # Custom for Visual Studio
5 | *.cs diff=csharp
6 |
7 | # Standard to msysgit
8 | *.doc diff=astextplain
9 | *.DOC diff=astextplain
10 | *.docx diff=astextplain
11 | *.DOCX diff=astextplain
12 | *.dot diff=astextplain
13 | *.DOT diff=astextplain
14 | *.pdf diff=astextplain
15 | *.PDF diff=astextplain
16 | *.rtf diff=astextplain
17 | *.RTF diff=astextplain
18 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | patreon: Rinnegatamante
2 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | build/*
2 |
3 | # Windows thumbnail cache files
4 | Thumbs.db
5 | ehthumbs.db
6 | ehthumbs_vista.db
7 |
8 | # Folder config file
9 | Desktop.ini
10 |
11 | # Recycle Bin used on file shares
12 | $RECYCLE.BIN/
13 |
14 | # Windows Installer files
15 | *.cab
16 | *.msi
17 | *.msm
18 | *.msp
19 |
20 | # Windows shortcuts
21 | *.lnk
22 |
23 | # =========================
24 | # Operating System Files
25 | # =========================
26 |
--------------------------------------------------------------------------------
/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 2.8)
2 |
3 | if(NOT DEFINED CMAKE_TOOLCHAIN_FILE)
4 | if(DEFINED ENV{VITASDK})
5 | set(CMAKE_TOOLCHAIN_FILE "$ENV{VITASDK}/share/vita.toolchain.cmake" CACHE PATH "toolchain file")
6 | else()
7 | message(FATAL_ERROR "Please define VITASDK to point to your SDK path!")
8 | endif()
9 | endif()
10 |
11 | project(reRescaler)
12 | include("${VITASDK}/share/vita.cmake" REQUIRED)
13 |
14 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -Wall -O3 -std=gnu99")
15 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fno-rtti -fno-exceptions")
16 |
17 | include_directories(
18 | )
19 |
20 | link_directories(
21 | ${CMAKE_CURRENT_BINARY_DIR}
22 | )
23 |
24 | if (NOT ${RELEASE})
25 | add_definitions(-DENABLE_LOGGING)
26 | endif()
27 |
28 | add_executable(reRescaler
29 | main.c
30 | renderer.c
31 | math_utils.c
32 | )
33 |
34 | target_link_libraries(reRescaler
35 | taihen_stub
36 | SceLibKernel_stub_weak
37 | SceDisplay_stub_weak
38 | SceAppMgr_stub_weak
39 | SceCtrl_stub_weak
40 | SceIofilemgr_stub_weak
41 | SceGxm_stub_weak
42 | SceSysmem_stub_weak
43 | SceRtc_stub_weak
44 | k
45 | gcc
46 | )
47 |
48 | set_target_properties(reRescaler
49 | PROPERTIES LINK_FLAGS "-nostdlib"
50 | )
51 |
52 | vita_create_self(reRescaler.suprx reRescaler
53 | CONFIG ${CMAKE_SOURCE_DIR}/reRescaler.yml
54 | )
55 |
--------------------------------------------------------------------------------
/LICENSE.txt:
--------------------------------------------------------------------------------
1 | GNU GENERAL PUBLIC LICENSE
2 | Version 3, 29 June 2007
3 |
4 | Copyright (C) 2007 Free Software Foundation, Inc.
5 | Everyone is permitted to copy and distribute verbatim copies
6 | of this license document, but changing it is not allowed.
7 |
8 | Preamble
9 |
10 | The GNU General Public License is a free, copyleft license for
11 | software and other kinds of works.
12 |
13 | The licenses for most software and other practical works are designed
14 | to take away your freedom to share and change the works. By contrast,
15 | the GNU General Public License is intended to guarantee your freedom to
16 | share and change all versions of a program--to make sure it remains free
17 | software for all its users. We, the Free Software Foundation, use the
18 | GNU General Public License for most of our software; it applies also to
19 | any other work released this way by its authors. You can apply it to
20 | your programs, too.
21 |
22 | When we speak of free software, we are referring to freedom, not
23 | price. Our General Public Licenses are designed to make sure that you
24 | have the freedom to distribute copies of free software (and charge for
25 | them if you wish), that you receive source code or can get it if you
26 | want it, that you can change the software or use pieces of it in new
27 | free programs, and that you know you can do these things.
28 |
29 | To protect your rights, we need to prevent others from denying you
30 | these rights or asking you to surrender the rights. Therefore, you have
31 | certain responsibilities if you distribute copies of the software, or if
32 | you modify it: responsibilities to respect the freedom of others.
33 |
34 | For example, if you distribute copies of such a program, whether
35 | gratis or for a fee, you must pass on to the recipients the same
36 | freedoms that you received. You must make sure that they, too, receive
37 | or can get the source code. And you must show them these terms so they
38 | know their rights.
39 |
40 | Developers that use the GNU GPL protect your rights with two steps:
41 | (1) assert copyright on the software, and (2) offer you this License
42 | giving you legal permission to copy, distribute and/or modify it.
43 |
44 | For the developers' and authors' protection, the GPL clearly explains
45 | that there is no warranty for this free software. For both users' and
46 | authors' sake, the GPL requires that modified versions be marked as
47 | changed, so that their problems will not be attributed erroneously to
48 | authors of previous versions.
49 |
50 | Some devices are designed to deny users access to install or run
51 | modified versions of the software inside them, although the manufacturer
52 | can do so. This is fundamentally incompatible with the aim of
53 | protecting users' freedom to change the software. The systematic
54 | pattern of such abuse occurs in the area of products for individuals to
55 | use, which is precisely where it is most unacceptable. Therefore, we
56 | have designed this version of the GPL to prohibit the practice for those
57 | products. If such problems arise substantially in other domains, we
58 | stand ready to extend this provision to those domains in future versions
59 | of the GPL, as needed to protect the freedom of users.
60 |
61 | Finally, every program is threatened constantly by software patents.
62 | States should not allow patents to restrict development and use of
63 | software on general-purpose computers, but in those that do, we wish to
64 | avoid the special danger that patents applied to a free program could
65 | make it effectively proprietary. To prevent this, the GPL assures that
66 | patents cannot be used to render the program non-free.
67 |
68 | The precise terms and conditions for copying, distribution and
69 | modification follow.
70 |
71 | TERMS AND CONDITIONS
72 |
73 | 0. Definitions.
74 |
75 | "This License" refers to version 3 of the GNU General Public License.
76 |
77 | "Copyright" also means copyright-like laws that apply to other kinds of
78 | works, such as semiconductor masks.
79 |
80 | "The Program" refers to any copyrightable work licensed under this
81 | License. Each licensee is addressed as "you". "Licensees" and
82 | "recipients" may be individuals or organizations.
83 |
84 | To "modify" a work means to copy from or adapt all or part of the work
85 | in a fashion requiring copyright permission, other than the making of an
86 | exact copy. The resulting work is called a "modified version" of the
87 | earlier work or a work "based on" the earlier work.
88 |
89 | A "covered work" means either the unmodified Program or a work based
90 | on the Program.
91 |
92 | To "propagate" a work means to do anything with it that, without
93 | permission, would make you directly or secondarily liable for
94 | infringement under applicable copyright law, except executing it on a
95 | computer or modifying a private copy. Propagation includes copying,
96 | distribution (with or without modification), making available to the
97 | public, and in some countries other activities as well.
98 |
99 | To "convey" a work means any kind of propagation that enables other
100 | parties to make or receive copies. Mere interaction with a user through
101 | a computer network, with no transfer of a copy, is not conveying.
102 |
103 | An interactive user interface displays "Appropriate Legal Notices"
104 | to the extent that it includes a convenient and prominently visible
105 | feature that (1) displays an appropriate copyright notice, and (2)
106 | tells the user that there is no warranty for the work (except to the
107 | extent that warranties are provided), that licensees may convey the
108 | work under this License, and how to view a copy of this License. If
109 | the interface presents a list of user commands or options, such as a
110 | menu, a prominent item in the list meets this criterion.
111 |
112 | 1. Source Code.
113 |
114 | The "source code" for a work means the preferred form of the work
115 | for making modifications to it. "Object code" means any non-source
116 | form of a work.
117 |
118 | A "Standard Interface" means an interface that either is an official
119 | standard defined by a recognized standards body, or, in the case of
120 | interfaces specified for a particular programming language, one that
121 | is widely used among developers working in that language.
122 |
123 | The "System Libraries" of an executable work include anything, other
124 | than the work as a whole, that (a) is included in the normal form of
125 | packaging a Major Component, but which is not part of that Major
126 | Component, and (b) serves only to enable use of the work with that
127 | Major Component, or to implement a Standard Interface for which an
128 | implementation is available to the public in source code form. A
129 | "Major Component", in this context, means a major essential component
130 | (kernel, window system, and so on) of the specific operating system
131 | (if any) on which the executable work runs, or a compiler used to
132 | produce the work, or an object code interpreter used to run it.
133 |
134 | The "Corresponding Source" for a work in object code form means all
135 | the source code needed to generate, install, and (for an executable
136 | work) run the object code and to modify the work, including scripts to
137 | control those activities. However, it does not include the work's
138 | System Libraries, or general-purpose tools or generally available free
139 | programs which are used unmodified in performing those activities but
140 | which are not part of the work. For example, Corresponding Source
141 | includes interface definition files associated with source files for
142 | the work, and the source code for shared libraries and dynamically
143 | linked subprograms that the work is specifically designed to require,
144 | such as by intimate data communication or control flow between those
145 | subprograms and other parts of the work.
146 |
147 | The Corresponding Source need not include anything that users
148 | can regenerate automatically from other parts of the Corresponding
149 | Source.
150 |
151 | The Corresponding Source for a work in source code form is that
152 | same work.
153 |
154 | 2. Basic Permissions.
155 |
156 | All rights granted under this License are granted for the term of
157 | copyright on the Program, and are irrevocable provided the stated
158 | conditions are met. This License explicitly affirms your unlimited
159 | permission to run the unmodified Program. The output from running a
160 | covered work is covered by this License only if the output, given its
161 | content, constitutes a covered work. This License acknowledges your
162 | rights of fair use or other equivalent, as provided by copyright law.
163 |
164 | You may make, run and propagate covered works that you do not
165 | convey, without conditions so long as your license otherwise remains
166 | in force. You may convey covered works to others for the sole purpose
167 | of having them make modifications exclusively for you, or provide you
168 | with facilities for running those works, provided that you comply with
169 | the terms of this License in conveying all material for which you do
170 | not control copyright. Those thus making or running the covered works
171 | for you must do so exclusively on your behalf, under your direction
172 | and control, on terms that prohibit them from making any copies of
173 | your copyrighted material outside their relationship with you.
174 |
175 | Conveying under any other circumstances is permitted solely under
176 | the conditions stated below. Sublicensing is not allowed; section 10
177 | makes it unnecessary.
178 |
179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
180 |
181 | No covered work shall be deemed part of an effective technological
182 | measure under any applicable law fulfilling obligations under article
183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or
184 | similar laws prohibiting or restricting circumvention of such
185 | measures.
186 |
187 | When you convey a covered work, you waive any legal power to forbid
188 | circumvention of technological measures to the extent such circumvention
189 | is effected by exercising rights under this License with respect to
190 | the covered work, and you disclaim any intention to limit operation or
191 | modification of the work as a means of enforcing, against the work's
192 | users, your or third parties' legal rights to forbid circumvention of
193 | technological measures.
194 |
195 | 4. Conveying Verbatim Copies.
196 |
197 | You may convey verbatim copies of the Program's source code as you
198 | receive it, in any medium, provided that you conspicuously and
199 | appropriately publish on each copy an appropriate copyright notice;
200 | keep intact all notices stating that this License and any
201 | non-permissive terms added in accord with section 7 apply to the code;
202 | keep intact all notices of the absence of any warranty; and give all
203 | recipients a copy of this License along with the Program.
204 |
205 | You may charge any price or no price for each copy that you convey,
206 | and you may offer support or warranty protection for a fee.
207 |
208 | 5. Conveying Modified Source Versions.
209 |
210 | You may convey a work based on the Program, or the modifications to
211 | produce it from the Program, in the form of source code under the
212 | terms of section 4, provided that you also meet all of these conditions:
213 |
214 | a) The work must carry prominent notices stating that you modified
215 | it, and giving a relevant date.
216 |
217 | b) The work must carry prominent notices stating that it is
218 | released under this License and any conditions added under section
219 | 7. This requirement modifies the requirement in section 4 to
220 | "keep intact all notices".
221 |
222 | c) You must license the entire work, as a whole, under this
223 | License to anyone who comes into possession of a copy. This
224 | License will therefore apply, along with any applicable section 7
225 | additional terms, to the whole of the work, and all its parts,
226 | regardless of how they are packaged. This License gives no
227 | permission to license the work in any other way, but it does not
228 | invalidate such permission if you have separately received it.
229 |
230 | d) If the work has interactive user interfaces, each must display
231 | Appropriate Legal Notices; however, if the Program has interactive
232 | interfaces that do not display Appropriate Legal Notices, your
233 | work need not make them do so.
234 |
235 | A compilation of a covered work with other separate and independent
236 | works, which are not by their nature extensions of the covered work,
237 | and which are not combined with it such as to form a larger program,
238 | in or on a volume of a storage or distribution medium, is called an
239 | "aggregate" if the compilation and its resulting copyright are not
240 | used to limit the access or legal rights of the compilation's users
241 | beyond what the individual works permit. Inclusion of a covered work
242 | in an aggregate does not cause this License to apply to the other
243 | parts of the aggregate.
244 |
245 | 6. Conveying Non-Source Forms.
246 |
247 | You may convey a covered work in object code form under the terms
248 | of sections 4 and 5, provided that you also convey the
249 | machine-readable Corresponding Source under the terms of this License,
250 | in one of these ways:
251 |
252 | a) Convey the object code in, or embodied in, a physical product
253 | (including a physical distribution medium), accompanied by the
254 | Corresponding Source fixed on a durable physical medium
255 | customarily used for software interchange.
256 |
257 | b) Convey the object code in, or embodied in, a physical product
258 | (including a physical distribution medium), accompanied by a
259 | written offer, valid for at least three years and valid for as
260 | long as you offer spare parts or customer support for that product
261 | model, to give anyone who possesses the object code either (1) a
262 | copy of the Corresponding Source for all the software in the
263 | product that is covered by this License, on a durable physical
264 | medium customarily used for software interchange, for a price no
265 | more than your reasonable cost of physically performing this
266 | conveying of source, or (2) access to copy the
267 | Corresponding Source from a network server at no charge.
268 |
269 | c) Convey individual copies of the object code with a copy of the
270 | written offer to provide the Corresponding Source. This
271 | alternative is allowed only occasionally and noncommercially, and
272 | only if you received the object code with such an offer, in accord
273 | with subsection 6b.
274 |
275 | d) Convey the object code by offering access from a designated
276 | place (gratis or for a charge), and offer equivalent access to the
277 | Corresponding Source in the same way through the same place at no
278 | further charge. You need not require recipients to copy the
279 | Corresponding Source along with the object code. If the place to
280 | copy the object code is a network server, the Corresponding Source
281 | may be on a different server (operated by you or a third party)
282 | that supports equivalent copying facilities, provided you maintain
283 | clear directions next to the object code saying where to find the
284 | Corresponding Source. Regardless of what server hosts the
285 | Corresponding Source, you remain obligated to ensure that it is
286 | available for as long as needed to satisfy these requirements.
287 |
288 | e) Convey the object code using peer-to-peer transmission, provided
289 | you inform other peers where the object code and Corresponding
290 | Source of the work are being offered to the general public at no
291 | charge under subsection 6d.
292 |
293 | A separable portion of the object code, whose source code is excluded
294 | from the Corresponding Source as a System Library, need not be
295 | included in conveying the object code work.
296 |
297 | A "User Product" is either (1) a "consumer product", which means any
298 | tangible personal property which is normally used for personal, family,
299 | or household purposes, or (2) anything designed or sold for incorporation
300 | into a dwelling. In determining whether a product is a consumer product,
301 | doubtful cases shall be resolved in favor of coverage. For a particular
302 | product received by a particular user, "normally used" refers to a
303 | typical or common use of that class of product, regardless of the status
304 | of the particular user or of the way in which the particular user
305 | actually uses, or expects or is expected to use, the product. A product
306 | is a consumer product regardless of whether the product has substantial
307 | commercial, industrial or non-consumer uses, unless such uses represent
308 | the only significant mode of use of the product.
309 |
310 | "Installation Information" for a User Product means any methods,
311 | procedures, authorization keys, or other information required to install
312 | and execute modified versions of a covered work in that User Product from
313 | a modified version of its Corresponding Source. The information must
314 | suffice to ensure that the continued functioning of the modified object
315 | code is in no case prevented or interfered with solely because
316 | modification has been made.
317 |
318 | If you convey an object code work under this section in, or with, or
319 | specifically for use in, a User Product, and the conveying occurs as
320 | part of a transaction in which the right of possession and use of the
321 | User Product is transferred to the recipient in perpetuity or for a
322 | fixed term (regardless of how the transaction is characterized), the
323 | Corresponding Source conveyed under this section must be accompanied
324 | by the Installation Information. But this requirement does not apply
325 | if neither you nor any third party retains the ability to install
326 | modified object code on the User Product (for example, the work has
327 | been installed in ROM).
328 |
329 | The requirement to provide Installation Information does not include a
330 | requirement to continue to provide support service, warranty, or updates
331 | for a work that has been modified or installed by the recipient, or for
332 | the User Product in which it has been modified or installed. Access to a
333 | network may be denied when the modification itself materially and
334 | adversely affects the operation of the network or violates the rules and
335 | protocols for communication across the network.
336 |
337 | Corresponding Source conveyed, and Installation Information provided,
338 | in accord with this section must be in a format that is publicly
339 | documented (and with an implementation available to the public in
340 | source code form), and must require no special password or key for
341 | unpacking, reading or copying.
342 |
343 | 7. Additional Terms.
344 |
345 | "Additional permissions" are terms that supplement the terms of this
346 | License by making exceptions from one or more of its conditions.
347 | Additional permissions that are applicable to the entire Program shall
348 | be treated as though they were included in this License, to the extent
349 | that they are valid under applicable law. If additional permissions
350 | apply only to part of the Program, that part may be used separately
351 | under those permissions, but the entire Program remains governed by
352 | this License without regard to the additional permissions.
353 |
354 | When you convey a copy of a covered work, you may at your option
355 | remove any additional permissions from that copy, or from any part of
356 | it. (Additional permissions may be written to require their own
357 | removal in certain cases when you modify the work.) You may place
358 | additional permissions on material, added by you to a covered work,
359 | for which you have or can give appropriate copyright permission.
360 |
361 | Notwithstanding any other provision of this License, for material you
362 | add to a covered work, you may (if authorized by the copyright holders of
363 | that material) supplement the terms of this License with terms:
364 |
365 | a) Disclaiming warranty or limiting liability differently from the
366 | terms of sections 15 and 16 of this License; or
367 |
368 | b) Requiring preservation of specified reasonable legal notices or
369 | author attributions in that material or in the Appropriate Legal
370 | Notices displayed by works containing it; or
371 |
372 | c) Prohibiting misrepresentation of the origin of that material, or
373 | requiring that modified versions of such material be marked in
374 | reasonable ways as different from the original version; or
375 |
376 | d) Limiting the use for publicity purposes of names of licensors or
377 | authors of the material; or
378 |
379 | e) Declining to grant rights under trademark law for use of some
380 | trade names, trademarks, or service marks; or
381 |
382 | f) Requiring indemnification of licensors and authors of that
383 | material by anyone who conveys the material (or modified versions of
384 | it) with contractual assumptions of liability to the recipient, for
385 | any liability that these contractual assumptions directly impose on
386 | those licensors and authors.
387 |
388 | All other non-permissive additional terms are considered "further
389 | restrictions" within the meaning of section 10. If the Program as you
390 | received it, or any part of it, contains a notice stating that it is
391 | governed by this License along with a term that is a further
392 | restriction, you may remove that term. If a license document contains
393 | a further restriction but permits relicensing or conveying under this
394 | License, you may add to a covered work material governed by the terms
395 | of that license document, provided that the further restriction does
396 | not survive such relicensing or conveying.
397 |
398 | If you add terms to a covered work in accord with this section, you
399 | must place, in the relevant source files, a statement of the
400 | additional terms that apply to those files, or a notice indicating
401 | where to find the applicable terms.
402 |
403 | Additional terms, permissive or non-permissive, may be stated in the
404 | form of a separately written license, or stated as exceptions;
405 | the above requirements apply either way.
406 |
407 | 8. Termination.
408 |
409 | You may not propagate or modify a covered work except as expressly
410 | provided under this License. Any attempt otherwise to propagate or
411 | modify it is void, and will automatically terminate your rights under
412 | this License (including any patent licenses granted under the third
413 | paragraph of section 11).
414 |
415 | However, if you cease all violation of this License, then your
416 | license from a particular copyright holder is reinstated (a)
417 | provisionally, unless and until the copyright holder explicitly and
418 | finally terminates your license, and (b) permanently, if the copyright
419 | holder fails to notify you of the violation by some reasonable means
420 | prior to 60 days after the cessation.
421 |
422 | Moreover, your license from a particular copyright holder is
423 | reinstated permanently if the copyright holder notifies you of the
424 | violation by some reasonable means, this is the first time you have
425 | received notice of violation of this License (for any work) from that
426 | copyright holder, and you cure the violation prior to 30 days after
427 | your receipt of the notice.
428 |
429 | Termination of your rights under this section does not terminate the
430 | licenses of parties who have received copies or rights from you under
431 | this License. If your rights have been terminated and not permanently
432 | reinstated, you do not qualify to receive new licenses for the same
433 | material under section 10.
434 |
435 | 9. Acceptance Not Required for Having Copies.
436 |
437 | You are not required to accept this License in order to receive or
438 | run a copy of the Program. Ancillary propagation of a covered work
439 | occurring solely as a consequence of using peer-to-peer transmission
440 | to receive a copy likewise does not require acceptance. However,
441 | nothing other than this License grants you permission to propagate or
442 | modify any covered work. These actions infringe copyright if you do
443 | not accept this License. Therefore, by modifying or propagating a
444 | covered work, you indicate your acceptance of this License to do so.
445 |
446 | 10. Automatic Licensing of Downstream Recipients.
447 |
448 | Each time you convey a covered work, the recipient automatically
449 | receives a license from the original licensors, to run, modify and
450 | propagate that work, subject to this License. You are not responsible
451 | for enforcing compliance by third parties with this License.
452 |
453 | An "entity transaction" is a transaction transferring control of an
454 | organization, or substantially all assets of one, or subdividing an
455 | organization, or merging organizations. If propagation of a covered
456 | work results from an entity transaction, each party to that
457 | transaction who receives a copy of the work also receives whatever
458 | licenses to the work the party's predecessor in interest had or could
459 | give under the previous paragraph, plus a right to possession of the
460 | Corresponding Source of the work from the predecessor in interest, if
461 | the predecessor has it or can get it with reasonable efforts.
462 |
463 | You may not impose any further restrictions on the exercise of the
464 | rights granted or affirmed under this License. For example, you may
465 | not impose a license fee, royalty, or other charge for exercise of
466 | rights granted under this License, and you may not initiate litigation
467 | (including a cross-claim or counterclaim in a lawsuit) alleging that
468 | any patent claim is infringed by making, using, selling, offering for
469 | sale, or importing the Program or any portion of it.
470 |
471 | 11. Patents.
472 |
473 | A "contributor" is a copyright holder who authorizes use under this
474 | License of the Program or a work on which the Program is based. The
475 | work thus licensed is called the contributor's "contributor version".
476 |
477 | A contributor's "essential patent claims" are all patent claims
478 | owned or controlled by the contributor, whether already acquired or
479 | hereafter acquired, that would be infringed by some manner, permitted
480 | by this License, of making, using, or selling its contributor version,
481 | but do not include claims that would be infringed only as a
482 | consequence of further modification of the contributor version. For
483 | purposes of this definition, "control" includes the right to grant
484 | patent sublicenses in a manner consistent with the requirements of
485 | this License.
486 |
487 | Each contributor grants you a non-exclusive, worldwide, royalty-free
488 | patent license under the contributor's essential patent claims, to
489 | make, use, sell, offer for sale, import and otherwise run, modify and
490 | propagate the contents of its contributor version.
491 |
492 | In the following three paragraphs, a "patent license" is any express
493 | agreement or commitment, however denominated, not to enforce a patent
494 | (such as an express permission to practice a patent or covenant not to
495 | sue for patent infringement). To "grant" such a patent license to a
496 | party means to make such an agreement or commitment not to enforce a
497 | patent against the party.
498 |
499 | If you convey a covered work, knowingly relying on a patent license,
500 | and the Corresponding Source of the work is not available for anyone
501 | to copy, free of charge and under the terms of this License, through a
502 | publicly available network server or other readily accessible means,
503 | then you must either (1) cause the Corresponding Source to be so
504 | available, or (2) arrange to deprive yourself of the benefit of the
505 | patent license for this particular work, or (3) arrange, in a manner
506 | consistent with the requirements of this License, to extend the patent
507 | license to downstream recipients. "Knowingly relying" means you have
508 | actual knowledge that, but for the patent license, your conveying the
509 | covered work in a country, or your recipient's use of the covered work
510 | in a country, would infringe one or more identifiable patents in that
511 | country that you have reason to believe are valid.
512 |
513 | If, pursuant to or in connection with a single transaction or
514 | arrangement, you convey, or propagate by procuring conveyance of, a
515 | covered work, and grant a patent license to some of the parties
516 | receiving the covered work authorizing them to use, propagate, modify
517 | or convey a specific copy of the covered work, then the patent license
518 | you grant is automatically extended to all recipients of the covered
519 | work and works based on it.
520 |
521 | A patent license is "discriminatory" if it does not include within
522 | the scope of its coverage, prohibits the exercise of, or is
523 | conditioned on the non-exercise of one or more of the rights that are
524 | specifically granted under this License. You may not convey a covered
525 | work if you are a party to an arrangement with a third party that is
526 | in the business of distributing software, under which you make payment
527 | to the third party based on the extent of your activity of conveying
528 | the work, and under which the third party grants, to any of the
529 | parties who would receive the covered work from you, a discriminatory
530 | patent license (a) in connection with copies of the covered work
531 | conveyed by you (or copies made from those copies), or (b) primarily
532 | for and in connection with specific products or compilations that
533 | contain the covered work, unless you entered into that arrangement,
534 | or that patent license was granted, prior to 28 March 2007.
535 |
536 | Nothing in this License shall be construed as excluding or limiting
537 | any implied license or other defenses to infringement that may
538 | otherwise be available to you under applicable patent law.
539 |
540 | 12. No Surrender of Others' Freedom.
541 |
542 | If conditions are imposed on you (whether by court order, agreement or
543 | otherwise) that contradict the conditions of this License, they do not
544 | excuse you from the conditions of this License. If you cannot convey a
545 | covered work so as to satisfy simultaneously your obligations under this
546 | License and any other pertinent obligations, then as a consequence you may
547 | not convey it at all. For example, if you agree to terms that obligate you
548 | to collect a royalty for further conveying from those to whom you convey
549 | the Program, the only way you could satisfy both those terms and this
550 | License would be to refrain entirely from conveying the Program.
551 |
552 | 13. Use with the GNU Affero General Public License.
553 |
554 | Notwithstanding any other provision of this License, you have
555 | permission to link or combine any covered work with a work licensed
556 | under version 3 of the GNU Affero General Public License into a single
557 | combined work, and to convey the resulting work. The terms of this
558 | License will continue to apply to the part which is the covered work,
559 | but the special requirements of the GNU Affero General Public License,
560 | section 13, concerning interaction through a network will apply to the
561 | combination as such.
562 |
563 | 14. Revised Versions of this License.
564 |
565 | The Free Software Foundation may publish revised and/or new versions of
566 | the GNU General Public License from time to time. Such new versions will
567 | be similar in spirit to the present version, but may differ in detail to
568 | address new problems or concerns.
569 |
570 | Each version is given a distinguishing version number. If the
571 | Program specifies that a certain numbered version of the GNU General
572 | Public License "or any later version" applies to it, you have the
573 | option of following the terms and conditions either of that numbered
574 | version or of any later version published by the Free Software
575 | Foundation. If the Program does not specify a version number of the
576 | GNU General Public License, you may choose any version ever published
577 | by the Free Software Foundation.
578 |
579 | If the Program specifies that a proxy can decide which future
580 | versions of the GNU General Public License can be used, that proxy's
581 | public statement of acceptance of a version permanently authorizes you
582 | to choose that version for the Program.
583 |
584 | Later license versions may give you additional or different
585 | permissions. However, no additional obligations are imposed on any
586 | author or copyright holder as a result of your choosing to follow a
587 | later version.
588 |
589 | 15. Disclaimer of Warranty.
590 |
591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
599 |
600 | 16. Limitation of Liability.
601 |
602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
610 | SUCH DAMAGES.
611 |
612 | 17. Interpretation of Sections 15 and 16.
613 |
614 | If the disclaimer of warranty and limitation of liability provided
615 | above cannot be given local legal effect according to their terms,
616 | reviewing courts shall apply local law that most closely approximates
617 | an absolute waiver of all civil liability in connection with the
618 | Program, unless a warranty or assumption of liability accompanies a
619 | copy of the Program in return for a fee.
620 |
621 | END OF TERMS AND CONDITIONS
622 |
623 | How to Apply These Terms to Your New Programs
624 |
625 | If you develop a new program, and you want it to be of the greatest
626 | possible use to the public, the best way to achieve this is to make it
627 | free software which everyone can redistribute and change under these terms.
628 |
629 | To do so, attach the following notices to the program. It is safest
630 | to attach them to the start of each source file to most effectively
631 | state the exclusion of warranty; and each file should have at least
632 | the "copyright" line and a pointer to where the full notice is found.
633 |
634 |
635 | Copyright (C)
636 |
637 | This program is free software: you can redistribute it and/or modify
638 | it under the terms of the GNU General Public License as published by
639 | the Free Software Foundation, either version 3 of the License, or
640 | (at your option) any later version.
641 |
642 | This program is distributed in the hope that it will be useful,
643 | but WITHOUT ANY WARRANTY; without even the implied warranty of
644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
645 | GNU General Public License for more details.
646 |
647 | You should have received a copy of the GNU General Public License
648 | along with this program. If not, see .
649 |
650 | Also add information on how to contact you by electronic and paper mail.
651 |
652 | If the program does terminal interaction, make it output a short
653 | notice like this when it starts in an interactive mode:
654 |
655 | Copyright (C)
656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
657 | This is free software, and you are welcome to redistribute it
658 | under certain conditions; type `show c' for details.
659 |
660 | The hypothetical commands `show w' and `show c' should show the appropriate
661 | parts of the General Public License. Of course, your program's commands
662 | might be different; for a GUI interface, you would use an "about box".
663 |
664 | You should also get your employer (if you work as a programmer) or school,
665 | if any, to sign a "copyright disclaimer" for the program, if necessary.
666 | For more information on this, and how to apply and follow the GNU GPL, see
667 | .
668 |
669 | The GNU General Public License does not permit incorporating your program
670 | into proprietary programs. If your program is a subroutine library, you
671 | may consider it more useful to permit linking proprietary applications with
672 | the library. If this is what you want to do, use the GNU Lesser General
673 | Public License instead of this License. But first, please read
674 | .
675 |
--------------------------------------------------------------------------------
/font.h:
--------------------------------------------------------------------------------
1 | //---------------------------------------------------------------------------------
2 | // Linux 6x10 font
3 | // https://github.com/torvalds/linux/tree/master/lib/fonts
4 | //---------------------------------------------------------------------------------
5 | #define FONT_WIDTH 6
6 | #define FONT_HEIGHT 10
7 | //---------------------------------------------------------------------------------
8 | static const unsigned char font[] = {
9 |
10 | /* 0 0x00 '^@' */
11 | 0x00, /* 00000000 */
12 | 0x00, /* 00000000 */
13 | 0x00, /* 00000000 */
14 | 0x00, /* 00000000 */
15 | 0x00, /* 00000000 */
16 | 0x00, /* 00000000 */
17 | 0x00, /* 00000000 */
18 | 0x00, /* 00000000 */
19 | 0x00, /* 00000000 */
20 | 0x00, /* 00000000 */
21 |
22 | /* 1 0x01 '^A' */
23 | 0x00, /* 00000000 */
24 | 0x78, /* 01111000 */
25 | 0x84, /* 10000100 */
26 | 0xCC, /* 11001100 */
27 | 0x84, /* 10000100 */
28 | 0xCC, /* 11001100 */
29 | 0xB4, /* 10110100 */
30 | 0x78, /* 01111000 */
31 | 0x00, /* 00000000 */
32 | 0x00, /* 00000000 */
33 |
34 | /* 2 0x02 '^B' */
35 | 0x00, /* 00000000 */
36 | 0x78, /* 01111000 */
37 | 0xFC, /* 11111100 */
38 | 0xB4, /* 10110100 */
39 | 0xFC, /* 11111100 */
40 | 0xB4, /* 10110100 */
41 | 0xCC, /* 11001100 */
42 | 0x78, /* 01111000 */
43 | 0x00, /* 00000000 */
44 | 0x00, /* 00000000 */
45 |
46 | /* 3 0x03 '^C' */
47 | 0x00, /* 00000000 */
48 | 0x00, /* 00000000 */
49 | 0x28, /* 00101000 */
50 | 0x7C, /* 01111100 */
51 | 0x7C, /* 01111100 */
52 | 0x38, /* 00111000 */
53 | 0x10, /* 00010000 */
54 | 0x00, /* 00000000 */
55 | 0x00, /* 00000000 */
56 | 0x00, /* 00000000 */
57 |
58 | /* 4 0x04 '^D' */
59 | 0x00, /* 00000000 */
60 | 0x00, /* 00000000 */
61 | 0x10, /* 00010000 */
62 | 0x38, /* 00111000 */
63 | 0x7C, /* 01111100 */
64 | 0x38, /* 00111000 */
65 | 0x10, /* 00010000 */
66 | 0x00, /* 00000000 */
67 | 0x00, /* 00000000 */
68 | 0x00, /* 00000000 */
69 |
70 | /* 5 0x05 '^E' */
71 | 0x00, /* 00000000 */
72 | 0x00, /* 00000000 */
73 | 0x38, /* 00111000 */
74 | 0x38, /* 00111000 */
75 | 0x6C, /* 01101100 */
76 | 0x6C, /* 01101100 */
77 | 0x10, /* 00010000 */
78 | 0x38, /* 00111000 */
79 | 0x00, /* 00000000 */
80 | 0x00, /* 00000000 */
81 |
82 | /* 6 0x06 '^F' */
83 | 0x00, /* 00000000 */
84 | 0x00, /* 00000000 */
85 | 0x10, /* 00010000 */
86 | 0x38, /* 00111000 */
87 | 0x7C, /* 01111100 */
88 | 0x7C, /* 01111100 */
89 | 0x10, /* 00010000 */
90 | 0x38, /* 00111000 */
91 | 0x00, /* 00000000 */
92 | 0x00, /* 00000000 */
93 |
94 | /* 7 0x07 '^G' */
95 | 0x00, /* 00000000 */
96 | 0x00, /* 00000000 */
97 | 0x00, /* 00000000 */
98 | 0x30, /* 00110000 */
99 | 0x78, /* 01111000 */
100 | 0x30, /* 00110000 */
101 | 0x00, /* 00000000 */
102 | 0x00, /* 00000000 */
103 | 0x00, /* 00000000 */
104 | 0x00, /* 00000000 */
105 |
106 | /* 8 0x08 '^H' */
107 | 0xFC, /* 11111100 */
108 | 0xFC, /* 11111100 */
109 | 0xFC, /* 11111100 */
110 | 0xCC, /* 11001100 */
111 | 0x84, /* 10000100 */
112 | 0xCC, /* 11001100 */
113 | 0xFC, /* 11111100 */
114 | 0xFC, /* 11111100 */
115 | 0xFC, /* 11111100 */
116 | 0xFC, /* 11111100 */
117 |
118 | /* 9 0x09 '^I' */
119 | 0x00, /* 00000000 */
120 | 0x00, /* 00000000 */
121 | 0x30, /* 00110000 */
122 | 0x48, /* 01001000 */
123 | 0x84, /* 10000100 */
124 | 0x48, /* 01001000 */
125 | 0x30, /* 00110000 */
126 | 0x00, /* 00000000 */
127 | 0x00, /* 00000000 */
128 | 0x00, /* 00000000 */
129 |
130 | /* 10 0x0A '^J' */
131 | 0xFC, /* 11111100 */
132 | 0xFC, /* 11111100 */
133 | 0xCC, /* 11001100 */
134 | 0xB4, /* 10110100 */
135 | 0x78, /* 01111000 */
136 | 0xB4, /* 10110100 */
137 | 0xCC, /* 11001100 */
138 | 0xFC, /* 11111100 */
139 | 0xFC, /* 11111100 */
140 | 0xFC, /* 11111100 */
141 |
142 | /* 11 0x0B '^K' */
143 | 0x00, /* 00000000 */
144 | 0x3C, /* 00111100 */
145 | 0x14, /* 00010100 */
146 | 0x20, /* 00100000 */
147 | 0x78, /* 01111000 */
148 | 0x44, /* 01000100 */
149 | 0x44, /* 01000100 */
150 | 0x38, /* 00111000 */
151 | 0x00, /* 00000000 */
152 | 0x00, /* 00000000 */
153 |
154 | /* 12 0x0C '^L' */
155 | 0x00, /* 00000000 */
156 | 0x38, /* 00111000 */
157 | 0x44, /* 01000100 */
158 | 0x44, /* 01000100 */
159 | 0x38, /* 00111000 */
160 | 0x10, /* 00010000 */
161 | 0x38, /* 00111000 */
162 | 0x10, /* 00010000 */
163 | 0x00, /* 00000000 */
164 | 0x00, /* 00000000 */
165 |
166 | /* 13 0x0D '^M' */
167 | 0x00, /* 00000000 */
168 | 0x18, /* 00011000 */
169 | 0x14, /* 00010100 */
170 | 0x14, /* 00010100 */
171 | 0x10, /* 00010000 */
172 | 0x10, /* 00010000 */
173 | 0x70, /* 01110000 */
174 | 0x60, /* 01100000 */
175 | 0x00, /* 00000000 */
176 | 0x00, /* 00000000 */
177 |
178 | /* 14 0x0E '^N' */
179 | 0x00, /* 00000000 */
180 | 0x3C, /* 00111100 */
181 | 0x24, /* 00100100 */
182 | 0x3C, /* 00111100 */
183 | 0x24, /* 00100100 */
184 | 0x24, /* 00100100 */
185 | 0x6C, /* 01101100 */
186 | 0x6C, /* 01101100 */
187 | 0x00, /* 00000000 */
188 | 0x00, /* 00000000 */
189 |
190 | /* 15 0x0F '^O' */
191 | 0x00, /* 00000000 */
192 | 0x10, /* 00010000 */
193 | 0x54, /* 01010100 */
194 | 0x38, /* 00111000 */
195 | 0x6C, /* 01101100 */
196 | 0x38, /* 00111000 */
197 | 0x54, /* 01010100 */
198 | 0x10, /* 00010000 */
199 | 0x00, /* 00000000 */
200 | 0x00, /* 00000000 */
201 |
202 | /* 16 0x10 '^P' */
203 | 0x00, /* 00000000 */
204 | 0x40, /* 01000000 */
205 | 0x60, /* 01100000 */
206 | 0x70, /* 01110000 */
207 | 0x78, /* 01111000 */
208 | 0x70, /* 01110000 */
209 | 0x60, /* 01100000 */
210 | 0x40, /* 01000000 */
211 | 0x00, /* 00000000 */
212 | 0x00, /* 00000000 */
213 |
214 | /* 17 0x11 '^Q' */
215 | 0x00, /* 00000000 */
216 | 0x04, /* 00000100 */
217 | 0x0C, /* 00001100 */
218 | 0x1C, /* 00011100 */
219 | 0x3C, /* 00111100 */
220 | 0x1C, /* 00011100 */
221 | 0x0C, /* 00001100 */
222 | 0x04, /* 00000100 */
223 | 0x00, /* 00000000 */
224 | 0x00, /* 00000000 */
225 |
226 | /* 18 0x12 '^R' */
227 | 0x00, /* 00000000 */
228 | 0x10, /* 00010000 */
229 | 0x38, /* 00111000 */
230 | 0x54, /* 01010100 */
231 | 0x10, /* 00010000 */
232 | 0x54, /* 01010100 */
233 | 0x38, /* 00111000 */
234 | 0x10, /* 00010000 */
235 | 0x00, /* 00000000 */
236 | 0x00, /* 00000000 */
237 |
238 | /* 19 0x13 '^S' */
239 | 0x00, /* 00000000 */
240 | 0x48, /* 01001000 */
241 | 0x48, /* 01001000 */
242 | 0x48, /* 01001000 */
243 | 0x48, /* 01001000 */
244 | 0x48, /* 01001000 */
245 | 0x00, /* 00000000 */
246 | 0x48, /* 01001000 */
247 | 0x00, /* 00000000 */
248 | 0x00, /* 00000000 */
249 |
250 | /* 20 0x14 '^T' */
251 | 0x3C, /* 00111100 */
252 | 0x54, /* 01010100 */
253 | 0x54, /* 01010100 */
254 | 0x54, /* 01010100 */
255 | 0x3C, /* 00111100 */
256 | 0x14, /* 00010100 */
257 | 0x14, /* 00010100 */
258 | 0x14, /* 00010100 */
259 | 0x00, /* 00000000 */
260 | 0x00, /* 00000000 */
261 |
262 | /* 21 0x15 '^U' */
263 | 0x38, /* 00111000 */
264 | 0x44, /* 01000100 */
265 | 0x20, /* 00100000 */
266 | 0x50, /* 01010000 */
267 | 0x48, /* 01001000 */
268 | 0x24, /* 00100100 */
269 | 0x14, /* 00010100 */
270 | 0x08, /* 00001000 */
271 | 0x44, /* 01000100 */
272 | 0x38, /* 00111000 */
273 |
274 | /* 22 0x16 '^V' */
275 | 0x00, /* 00000000 */
276 | 0x00, /* 00000000 */
277 | 0x00, /* 00000000 */
278 | 0x00, /* 00000000 */
279 | 0x00, /* 00000000 */
280 | 0xF8, /* 11111000 */
281 | 0xF8, /* 11111000 */
282 | 0xF8, /* 11111000 */
283 | 0x00, /* 00000000 */
284 | 0x00, /* 00000000 */
285 |
286 | /* 23 0x17 '^W' */
287 | 0x00, /* 00000000 */
288 | 0x10, /* 00010000 */
289 | 0x38, /* 00111000 */
290 | 0x54, /* 01010100 */
291 | 0x10, /* 00010000 */
292 | 0x54, /* 01010100 */
293 | 0x38, /* 00111000 */
294 | 0x10, /* 00010000 */
295 | 0x7C, /* 01111100 */
296 | 0x00, /* 00000000 */
297 |
298 | /* 24 0x18 '^X' */
299 | 0x00, /* 00000000 */
300 | 0x10, /* 00010000 */
301 | 0x38, /* 00111000 */
302 | 0x54, /* 01010100 */
303 | 0x10, /* 00010000 */
304 | 0x10, /* 00010000 */
305 | 0x10, /* 00010000 */
306 | 0x10, /* 00010000 */
307 | 0x00, /* 00000000 */
308 | 0x00, /* 00000000 */
309 |
310 | /* 25 0x19 '^Y' */
311 | 0x00, /* 00000000 */
312 | 0x10, /* 00010000 */
313 | 0x10, /* 00010000 */
314 | 0x10, /* 00010000 */
315 | 0x10, /* 00010000 */
316 | 0x54, /* 01010100 */
317 | 0x38, /* 00111000 */
318 | 0x10, /* 00010000 */
319 | 0x00, /* 00000000 */
320 | 0x00, /* 00000000 */
321 |
322 | /* 26 0x1A '^Z' */
323 | 0x00, /* 00000000 */
324 | 0x00, /* 00000000 */
325 | 0x10, /* 00010000 */
326 | 0x08, /* 00001000 */
327 | 0x7C, /* 01111100 */
328 | 0x08, /* 00001000 */
329 | 0x10, /* 00010000 */
330 | 0x00, /* 00000000 */
331 | 0x00, /* 00000000 */
332 | 0x00, /* 00000000 */
333 |
334 | /* 27 0x1B '^[' */
335 | 0x00, /* 00000000 */
336 | 0x00, /* 00000000 */
337 | 0x10, /* 00010000 */
338 | 0x20, /* 00100000 */
339 | 0x7C, /* 01111100 */
340 | 0x20, /* 00100000 */
341 | 0x10, /* 00010000 */
342 | 0x00, /* 00000000 */
343 | 0x00, /* 00000000 */
344 | 0x00, /* 00000000 */
345 |
346 | /* 28 0x1C '^\' */
347 | 0x00, /* 00000000 */
348 | 0x00, /* 00000000 */
349 | 0x00, /* 00000000 */
350 | 0x00, /* 00000000 */
351 | 0x40, /* 01000000 */
352 | 0x40, /* 01000000 */
353 | 0x40, /* 01000000 */
354 | 0x78, /* 01111000 */
355 | 0x00, /* 00000000 */
356 | 0x00, /* 00000000 */
357 |
358 | /* 29 0x1D '^]' */
359 | 0x00, /* 00000000 */
360 | 0x00, /* 00000000 */
361 | 0x48, /* 01001000 */
362 | 0x84, /* 10000100 */
363 | 0xFC, /* 11111100 */
364 | 0x84, /* 10000100 */
365 | 0x48, /* 01001000 */
366 | 0x00, /* 00000000 */
367 | 0x00, /* 00000000 */
368 | 0x00, /* 00000000 */
369 |
370 | /* 30 0x1E '^^' */
371 | 0x00, /* 00000000 */
372 | 0x00, /* 00000000 */
373 | 0x10, /* 00010000 */
374 | 0x10, /* 00010000 */
375 | 0x38, /* 00111000 */
376 | 0x38, /* 00111000 */
377 | 0x7C, /* 01111100 */
378 | 0x7C, /* 01111100 */
379 | 0x00, /* 00000000 */
380 | 0x00, /* 00000000 */
381 |
382 | /* 31 0x1F '^_' */
383 | 0x00, /* 00000000 */
384 | 0x00, /* 00000000 */
385 | 0x7C, /* 01111100 */
386 | 0x7C, /* 01111100 */
387 | 0x38, /* 00111000 */
388 | 0x38, /* 00111000 */
389 | 0x10, /* 00010000 */
390 | 0x10, /* 00010000 */
391 | 0x00, /* 00000000 */
392 | 0x00, /* 00000000 */
393 |
394 | /* 32 0x20 ' ' */
395 | 0x00, /* 00000000 */
396 | 0x00, /* 00000000 */
397 | 0x00, /* 00000000 */
398 | 0x00, /* 00000000 */
399 | 0x00, /* 00000000 */
400 | 0x00, /* 00000000 */
401 | 0x00, /* 00000000 */
402 | 0x00, /* 00000000 */
403 | 0x00, /* 00000000 */
404 | 0x00, /* 00000000 */
405 |
406 | /* 33 0x21 '!' */
407 | 0x00, /* 00000000 */
408 | 0x10, /* 00010000 */
409 | 0x10, /* 00010000 */
410 | 0x10, /* 00010000 */
411 | 0x10, /* 00010000 */
412 | 0x10, /* 00010000 */
413 | 0x00, /* 00000000 */
414 | 0x10, /* 00010000 */
415 | 0x00, /* 00000000 */
416 | 0x00, /* 00000000 */
417 |
418 | /* 34 0x22 '"' */
419 | 0x28, /* 00101000 */
420 | 0x28, /* 00101000 */
421 | 0x28, /* 00101000 */
422 | 0x00, /* 00000000 */
423 | 0x00, /* 00000000 */
424 | 0x00, /* 00000000 */
425 | 0x00, /* 00000000 */
426 | 0x00, /* 00000000 */
427 | 0x00, /* 00000000 */
428 | 0x00, /* 00000000 */
429 |
430 | /* 35 0x23 '#' */
431 | 0x00, /* 00000000 */
432 | 0x00, /* 00000000 */
433 | 0x28, /* 00101000 */
434 | 0x7C, /* 01111100 */
435 | 0x28, /* 00101000 */
436 | 0x28, /* 00101000 */
437 | 0x7C, /* 01111100 */
438 | 0x28, /* 00101000 */
439 | 0x00, /* 00000000 */
440 | 0x00, /* 00000000 */
441 |
442 | /* 36 0x24 '$' */
443 | 0x10, /* 00010000 */
444 | 0x38, /* 00111000 */
445 | 0x54, /* 01010100 */
446 | 0x50, /* 01010000 */
447 | 0x38, /* 00111000 */
448 | 0x14, /* 00010100 */
449 | 0x54, /* 01010100 */
450 | 0x38, /* 00111000 */
451 | 0x10, /* 00010000 */
452 | 0x00, /* 00000000 */
453 |
454 | /* 37 0x25 '%' */
455 | 0x00, /* 00000000 */
456 | 0x64, /* 01100100 */
457 | 0x64, /* 01100100 */
458 | 0x08, /* 00001000 */
459 | 0x10, /* 00010000 */
460 | 0x20, /* 00100000 */
461 | 0x4C, /* 01001100 */
462 | 0x4C, /* 01001100 */
463 | 0x00, /* 00000000 */
464 | 0x00, /* 00000000 */
465 |
466 | /* 38 0x26 '&' */
467 | 0x00, /* 00000000 */
468 | 0x30, /* 00110000 */
469 | 0x48, /* 01001000 */
470 | 0x50, /* 01010000 */
471 | 0x20, /* 00100000 */
472 | 0x54, /* 01010100 */
473 | 0x48, /* 01001000 */
474 | 0x34, /* 00110100 */
475 | 0x00, /* 00000000 */
476 | 0x00, /* 00000000 */
477 |
478 | /* 39 0x27 ''' */
479 | 0x10, /* 00010000 */
480 | 0x10, /* 00010000 */
481 | 0x10, /* 00010000 */
482 | 0x00, /* 00000000 */
483 | 0x00, /* 00000000 */
484 | 0x00, /* 00000000 */
485 | 0x00, /* 00000000 */
486 | 0x00, /* 00000000 */
487 | 0x00, /* 00000000 */
488 | 0x00, /* 00000000 */
489 |
490 | /* 40 0x28 '(' */
491 | 0x08, /* 00001000 */
492 | 0x10, /* 00010000 */
493 | 0x20, /* 00100000 */
494 | 0x20, /* 00100000 */
495 | 0x20, /* 00100000 */
496 | 0x20, /* 00100000 */
497 | 0x20, /* 00100000 */
498 | 0x10, /* 00010000 */
499 | 0x08, /* 00001000 */
500 | 0x00, /* 00000000 */
501 |
502 | /* 41 0x29 ')' */
503 | 0x20, /* 00100000 */
504 | 0x10, /* 00010000 */
505 | 0x08, /* 00001000 */
506 | 0x08, /* 00001000 */
507 | 0x08, /* 00001000 */
508 | 0x08, /* 00001000 */
509 | 0x08, /* 00001000 */
510 | 0x10, /* 00010000 */
511 | 0x20, /* 00100000 */
512 | 0x00, /* 00000000 */
513 |
514 | /* 42 0x2A '*' */
515 | 0x00, /* 00000000 */
516 | 0x10, /* 00010000 */
517 | 0x54, /* 01010100 */
518 | 0x38, /* 00111000 */
519 | 0x54, /* 01010100 */
520 | 0x10, /* 00010000 */
521 | 0x00, /* 00000000 */
522 | 0x00, /* 00000000 */
523 | 0x00, /* 00000000 */
524 | 0x00, /* 00000000 */
525 |
526 | /* 43 0x2B '+' */
527 | 0x00, /* 00000000 */
528 | 0x00, /* 00000000 */
529 | 0x10, /* 00010000 */
530 | 0x10, /* 00010000 */
531 | 0x7C, /* 01111100 */
532 | 0x10, /* 00010000 */
533 | 0x10, /* 00010000 */
534 | 0x00, /* 00000000 */
535 | 0x00, /* 00000000 */
536 | 0x00, /* 00000000 */
537 |
538 | /* 44 0x2C ',' */
539 | 0x00, /* 00000000 */
540 | 0x00, /* 00000000 */
541 | 0x00, /* 00000000 */
542 | 0x00, /* 00000000 */
543 | 0x00, /* 00000000 */
544 | 0x00, /* 00000000 */
545 | 0x30, /* 00110000 */
546 | 0x30, /* 00110000 */
547 | 0x10, /* 00010000 */
548 | 0x20, /* 00100000 */
549 |
550 | /* 45 0x2D '-' */
551 | 0x00, /* 00000000 */
552 | 0x00, /* 00000000 */
553 | 0x00, /* 00000000 */
554 | 0x00, /* 00000000 */
555 | 0x7C, /* 01111100 */
556 | 0x00, /* 00000000 */
557 | 0x00, /* 00000000 */
558 | 0x00, /* 00000000 */
559 | 0x00, /* 00000000 */
560 | 0x00, /* 00000000 */
561 |
562 | /* 46 0x2E '.' */
563 | 0x00, /* 00000000 */
564 | 0x00, /* 00000000 */
565 | 0x00, /* 00000000 */
566 | 0x00, /* 00000000 */
567 | 0x00, /* 00000000 */
568 | 0x00, /* 00000000 */
569 | 0x18, /* 00011000 */
570 | 0x18, /* 00011000 */
571 | 0x00, /* 00000000 */
572 | 0x00, /* 00000000 */
573 |
574 | /* 47 0x2F '/' */
575 | 0x04, /* 00000100 */
576 | 0x04, /* 00000100 */
577 | 0x08, /* 00001000 */
578 | 0x08, /* 00001000 */
579 | 0x10, /* 00010000 */
580 | 0x10, /* 00010000 */
581 | 0x20, /* 00100000 */
582 | 0x20, /* 00100000 */
583 | 0x40, /* 01000000 */
584 | 0x40, /* 01000000 */
585 |
586 | /* 48 0x30 '0' */
587 | 0x00, /* 00000000 */
588 | 0x38, /* 00111000 */
589 | 0x44, /* 01000100 */
590 | 0x4C, /* 01001100 */
591 | 0x54, /* 01010100 */
592 | 0x64, /* 01100100 */
593 | 0x44, /* 01000100 */
594 | 0x38, /* 00111000 */
595 | 0x00, /* 00000000 */
596 | 0x00, /* 00000000 */
597 |
598 | /* 49 0x31 '1' */
599 | 0x00, /* 00000000 */
600 | 0x10, /* 00010000 */
601 | 0x30, /* 00110000 */
602 | 0x50, /* 01010000 */
603 | 0x10, /* 00010000 */
604 | 0x10, /* 00010000 */
605 | 0x10, /* 00010000 */
606 | 0x7C, /* 01111100 */
607 | 0x00, /* 00000000 */
608 | 0x00, /* 00000000 */
609 |
610 | /* 50 0x32 '2' */
611 | 0x00, /* 00000000 */
612 | 0x38, /* 00111000 */
613 | 0x44, /* 01000100 */
614 | 0x04, /* 00000100 */
615 | 0x08, /* 00001000 */
616 | 0x10, /* 00010000 */
617 | 0x20, /* 00100000 */
618 | 0x7C, /* 01111100 */
619 | 0x00, /* 00000000 */
620 | 0x00, /* 00000000 */
621 |
622 | /* 51 0x33 '3' */
623 | 0x00, /* 00000000 */
624 | 0x38, /* 00111000 */
625 | 0x44, /* 01000100 */
626 | 0x04, /* 00000100 */
627 | 0x18, /* 00011000 */
628 | 0x04, /* 00000100 */
629 | 0x44, /* 01000100 */
630 | 0x38, /* 00111000 */
631 | 0x00, /* 00000000 */
632 | 0x00, /* 00000000 */
633 |
634 | /* 52 0x34 '4' */
635 | 0x00, /* 00000000 */
636 | 0x08, /* 00001000 */
637 | 0x18, /* 00011000 */
638 | 0x28, /* 00101000 */
639 | 0x48, /* 01001000 */
640 | 0x7C, /* 01111100 */
641 | 0x08, /* 00001000 */
642 | 0x08, /* 00001000 */
643 | 0x00, /* 00000000 */
644 | 0x00, /* 00000000 */
645 |
646 | /* 53 0x35 '5' */
647 | 0x00, /* 00000000 */
648 | 0x7C, /* 01111100 */
649 | 0x40, /* 01000000 */
650 | 0x78, /* 01111000 */
651 | 0x04, /* 00000100 */
652 | 0x04, /* 00000100 */
653 | 0x44, /* 01000100 */
654 | 0x38, /* 00111000 */
655 | 0x00, /* 00000000 */
656 | 0x00, /* 00000000 */
657 |
658 | /* 54 0x36 '6' */
659 | 0x00, /* 00000000 */
660 | 0x18, /* 00011000 */
661 | 0x20, /* 00100000 */
662 | 0x40, /* 01000000 */
663 | 0x78, /* 01111000 */
664 | 0x44, /* 01000100 */
665 | 0x44, /* 01000100 */
666 | 0x38, /* 00111000 */
667 | 0x00, /* 00000000 */
668 | 0x00, /* 00000000 */
669 |
670 | /* 55 0x37 '7' */
671 | 0x00, /* 00000000 */
672 | 0x7C, /* 01111100 */
673 | 0x04, /* 00000100 */
674 | 0x04, /* 00000100 */
675 | 0x08, /* 00001000 */
676 | 0x10, /* 00010000 */
677 | 0x10, /* 00010000 */
678 | 0x10, /* 00010000 */
679 | 0x00, /* 00000000 */
680 | 0x00, /* 00000000 */
681 |
682 | /* 56 0x38 '8' */
683 | 0x00, /* 00000000 */
684 | 0x38, /* 00111000 */
685 | 0x44, /* 01000100 */
686 | 0x44, /* 01000100 */
687 | 0x38, /* 00111000 */
688 | 0x44, /* 01000100 */
689 | 0x44, /* 01000100 */
690 | 0x38, /* 00111000 */
691 | 0x00, /* 00000000 */
692 | 0x00, /* 00000000 */
693 |
694 | /* 57 0x39 '9' */
695 | 0x00, /* 00000000 */
696 | 0x38, /* 00111000 */
697 | 0x44, /* 01000100 */
698 | 0x44, /* 01000100 */
699 | 0x3C, /* 00111100 */
700 | 0x04, /* 00000100 */
701 | 0x08, /* 00001000 */
702 | 0x30, /* 00110000 */
703 | 0x00, /* 00000000 */
704 | 0x00, /* 00000000 */
705 |
706 | /* 58 0x3A ':' */
707 | 0x00, /* 00000000 */
708 | 0x00, /* 00000000 */
709 | 0x00, /* 00000000 */
710 | 0x18, /* 00011000 */
711 | 0x18, /* 00011000 */
712 | 0x00, /* 00000000 */
713 | 0x18, /* 00011000 */
714 | 0x18, /* 00011000 */
715 | 0x00, /* 00000000 */
716 | 0x00, /* 00000000 */
717 |
718 | /* 59 0x3B ';' */
719 | 0x00, /* 00000000 */
720 | 0x00, /* 00000000 */
721 | 0x00, /* 00000000 */
722 | 0x30, /* 00110000 */
723 | 0x30, /* 00110000 */
724 | 0x00, /* 00000000 */
725 | 0x30, /* 00110000 */
726 | 0x30, /* 00110000 */
727 | 0x10, /* 00010000 */
728 | 0x20, /* 00100000 */
729 |
730 | /* 60 0x3C '<' */
731 | 0x00, /* 00000000 */
732 | 0x04, /* 00000100 */
733 | 0x08, /* 00001000 */
734 | 0x10, /* 00010000 */
735 | 0x20, /* 00100000 */
736 | 0x10, /* 00010000 */
737 | 0x08, /* 00001000 */
738 | 0x04, /* 00000100 */
739 | 0x00, /* 00000000 */
740 | 0x00, /* 00000000 */
741 |
742 | /* 61 0x3D '=' */
743 | 0x00, /* 00000000 */
744 | 0x00, /* 00000000 */
745 | 0x00, /* 00000000 */
746 | 0x7C, /* 01111100 */
747 | 0x00, /* 00000000 */
748 | 0x7C, /* 01111100 */
749 | 0x00, /* 00000000 */
750 | 0x00, /* 00000000 */
751 | 0x00, /* 00000000 */
752 | 0x00, /* 00000000 */
753 |
754 | /* 62 0x3E '>' */
755 | 0x00, /* 00000000 */
756 | 0x20, /* 00100000 */
757 | 0x10, /* 00010000 */
758 | 0x08, /* 00001000 */
759 | 0x04, /* 00000100 */
760 | 0x08, /* 00001000 */
761 | 0x10, /* 00010000 */
762 | 0x20, /* 00100000 */
763 | 0x00, /* 00000000 */
764 | 0x00, /* 00000000 */
765 |
766 | /* 63 0x3F '?' */
767 | 0x00, /* 00000000 */
768 | 0x38, /* 00111000 */
769 | 0x44, /* 01000100 */
770 | 0x04, /* 00000100 */
771 | 0x08, /* 00001000 */
772 | 0x10, /* 00010000 */
773 | 0x00, /* 00000000 */
774 | 0x10, /* 00010000 */
775 | 0x00, /* 00000000 */
776 | 0x00, /* 00000000 */
777 |
778 | /* 64 0x40 '@' */
779 | 0x00, /* 00000000 */
780 | 0x38, /* 00111000 */
781 | 0x44, /* 01000100 */
782 | 0x5C, /* 01011100 */
783 | 0x54, /* 01010100 */
784 | 0x5C, /* 01011100 */
785 | 0x40, /* 01000000 */
786 | 0x38, /* 00111000 */
787 | 0x00, /* 00000000 */
788 | 0x00, /* 00000000 */
789 |
790 | /* 65 0x41 'A' */
791 | 0x00, /* 00000000 */
792 | 0x10, /* 00010000 */
793 | 0x28, /* 00101000 */
794 | 0x44, /* 01000100 */
795 | 0x44, /* 01000100 */
796 | 0x7C, /* 01111100 */
797 | 0x44, /* 01000100 */
798 | 0x44, /* 01000100 */
799 | 0x00, /* 00000000 */
800 | 0x00, /* 00000000 */
801 |
802 | /* 66 0x42 'B' */
803 | 0x00, /* 00000000 */
804 | 0x78, /* 01111000 */
805 | 0x24, /* 00100100 */
806 | 0x24, /* 00100100 */
807 | 0x38, /* 00111000 */
808 | 0x24, /* 00100100 */
809 | 0x24, /* 00100100 */
810 | 0x78, /* 01111000 */
811 | 0x00, /* 00000000 */
812 | 0x00, /* 00000000 */
813 |
814 | /* 67 0x43 'C' */
815 | 0x00, /* 00000000 */
816 | 0x38, /* 00111000 */
817 | 0x44, /* 01000100 */
818 | 0x40, /* 01000000 */
819 | 0x40, /* 01000000 */
820 | 0x40, /* 01000000 */
821 | 0x44, /* 01000100 */
822 | 0x38, /* 00111000 */
823 | 0x00, /* 00000000 */
824 | 0x00, /* 00000000 */
825 |
826 | /* 68 0x44 'D' */
827 | 0x00, /* 00000000 */
828 | 0x78, /* 01111000 */
829 | 0x24, /* 00100100 */
830 | 0x24, /* 00100100 */
831 | 0x24, /* 00100100 */
832 | 0x24, /* 00100100 */
833 | 0x24, /* 00100100 */
834 | 0x78, /* 01111000 */
835 | 0x00, /* 00000000 */
836 | 0x00, /* 00000000 */
837 |
838 | /* 69 0x45 'E' */
839 | 0x00, /* 00000000 */
840 | 0x7C, /* 01111100 */
841 | 0x40, /* 01000000 */
842 | 0x40, /* 01000000 */
843 | 0x78, /* 01111000 */
844 | 0x40, /* 01000000 */
845 | 0x40, /* 01000000 */
846 | 0x7C, /* 01111100 */
847 | 0x00, /* 00000000 */
848 | 0x00, /* 00000000 */
849 |
850 | /* 70 0x46 'F' */
851 | 0x00, /* 00000000 */
852 | 0x7C, /* 01111100 */
853 | 0x40, /* 01000000 */
854 | 0x40, /* 01000000 */
855 | 0x78, /* 01111000 */
856 | 0x40, /* 01000000 */
857 | 0x40, /* 01000000 */
858 | 0x40, /* 01000000 */
859 | 0x00, /* 00000000 */
860 | 0x00, /* 00000000 */
861 |
862 | /* 71 0x47 'G' */
863 | 0x00, /* 00000000 */
864 | 0x38, /* 00111000 */
865 | 0x44, /* 01000100 */
866 | 0x40, /* 01000000 */
867 | 0x5C, /* 01011100 */
868 | 0x44, /* 01000100 */
869 | 0x44, /* 01000100 */
870 | 0x38, /* 00111000 */
871 | 0x00, /* 00000000 */
872 | 0x00, /* 00000000 */
873 |
874 | /* 72 0x48 'H' */
875 | 0x00, /* 00000000 */
876 | 0x44, /* 01000100 */
877 | 0x44, /* 01000100 */
878 | 0x44, /* 01000100 */
879 | 0x7C, /* 01111100 */
880 | 0x44, /* 01000100 */
881 | 0x44, /* 01000100 */
882 | 0x44, /* 01000100 */
883 | 0x00, /* 00000000 */
884 | 0x00, /* 00000000 */
885 |
886 | /* 73 0x49 'I' */
887 | 0x00, /* 00000000 */
888 | 0x38, /* 00111000 */
889 | 0x10, /* 00010000 */
890 | 0x10, /* 00010000 */
891 | 0x10, /* 00010000 */
892 | 0x10, /* 00010000 */
893 | 0x10, /* 00010000 */
894 | 0x38, /* 00111000 */
895 | 0x00, /* 00000000 */
896 | 0x00, /* 00000000 */
897 |
898 | /* 74 0x4A 'J' */
899 | 0x00, /* 00000000 */
900 | 0x1C, /* 00011100 */
901 | 0x08, /* 00001000 */
902 | 0x08, /* 00001000 */
903 | 0x08, /* 00001000 */
904 | 0x48, /* 01001000 */
905 | 0x48, /* 01001000 */
906 | 0x30, /* 00110000 */
907 | 0x00, /* 00000000 */
908 | 0x00, /* 00000000 */
909 |
910 | /* 75 0x4B 'K' */
911 | 0x00, /* 00000000 */
912 | 0x44, /* 01000100 */
913 | 0x48, /* 01001000 */
914 | 0x50, /* 01010000 */
915 | 0x60, /* 01100000 */
916 | 0x50, /* 01010000 */
917 | 0x48, /* 01001000 */
918 | 0x44, /* 01000100 */
919 | 0x00, /* 00000000 */
920 | 0x00, /* 00000000 */
921 |
922 | /* 76 0x4C 'L' */
923 | 0x00, /* 00000000 */
924 | 0x40, /* 01000000 */
925 | 0x40, /* 01000000 */
926 | 0x40, /* 01000000 */
927 | 0x40, /* 01000000 */
928 | 0x40, /* 01000000 */
929 | 0x40, /* 01000000 */
930 | 0x7C, /* 01111100 */
931 | 0x00, /* 00000000 */
932 | 0x00, /* 00000000 */
933 |
934 | /* 77 0x4D 'M' */
935 | 0x00, /* 00000000 */
936 | 0x44, /* 01000100 */
937 | 0x6C, /* 01101100 */
938 | 0x54, /* 01010100 */
939 | 0x54, /* 01010100 */
940 | 0x44, /* 01000100 */
941 | 0x44, /* 01000100 */
942 | 0x44, /* 01000100 */
943 | 0x00, /* 00000000 */
944 | 0x00, /* 00000000 */
945 |
946 | /* 78 0x4E 'N' */
947 | 0x00, /* 00000000 */
948 | 0x44, /* 01000100 */
949 | 0x64, /* 01100100 */
950 | 0x54, /* 01010100 */
951 | 0x4C, /* 01001100 */
952 | 0x44, /* 01000100 */
953 | 0x44, /* 01000100 */
954 | 0x44, /* 01000100 */
955 | 0x00, /* 00000000 */
956 | 0x00, /* 00000000 */
957 |
958 | /* 79 0x4F 'O' */
959 | 0x00, /* 00000000 */
960 | 0x38, /* 00111000 */
961 | 0x44, /* 01000100 */
962 | 0x44, /* 01000100 */
963 | 0x44, /* 01000100 */
964 | 0x44, /* 01000100 */
965 | 0x44, /* 01000100 */
966 | 0x38, /* 00111000 */
967 | 0x00, /* 00000000 */
968 | 0x00, /* 00000000 */
969 |
970 | /* 80 0x50 'P' */
971 | 0x00, /* 00000000 */
972 | 0x78, /* 01111000 */
973 | 0x44, /* 01000100 */
974 | 0x44, /* 01000100 */
975 | 0x78, /* 01111000 */
976 | 0x40, /* 01000000 */
977 | 0x40, /* 01000000 */
978 | 0x40, /* 01000000 */
979 | 0x00, /* 00000000 */
980 | 0x00, /* 00000000 */
981 |
982 | /* 81 0x51 'Q' */
983 | 0x00, /* 00000000 */
984 | 0x38, /* 00111000 */
985 | 0x44, /* 01000100 */
986 | 0x44, /* 01000100 */
987 | 0x44, /* 01000100 */
988 | 0x54, /* 01010100 */
989 | 0x48, /* 01001000 */
990 | 0x34, /* 00110100 */
991 | 0x00, /* 00000000 */
992 | 0x00, /* 00000000 */
993 |
994 | /* 82 0x52 'R' */
995 | 0x00, /* 00000000 */
996 | 0x78, /* 01111000 */
997 | 0x44, /* 01000100 */
998 | 0x44, /* 01000100 */
999 | 0x78, /* 01111000 */
1000 | 0x50, /* 01010000 */
1001 | 0x48, /* 01001000 */
1002 | 0x44, /* 01000100 */
1003 | 0x00, /* 00000000 */
1004 | 0x00, /* 00000000 */
1005 |
1006 | /* 83 0x53 'S' */
1007 | 0x00, /* 00000000 */
1008 | 0x38, /* 00111000 */
1009 | 0x44, /* 01000100 */
1010 | 0x40, /* 01000000 */
1011 | 0x38, /* 00111000 */
1012 | 0x04, /* 00000100 */
1013 | 0x44, /* 01000100 */
1014 | 0x38, /* 00111000 */
1015 | 0x00, /* 00000000 */
1016 | 0x00, /* 00000000 */
1017 |
1018 | /* 84 0x54 'T' */
1019 | 0x00, /* 00000000 */
1020 | 0x7C, /* 01111100 */
1021 | 0x10, /* 00010000 */
1022 | 0x10, /* 00010000 */
1023 | 0x10, /* 00010000 */
1024 | 0x10, /* 00010000 */
1025 | 0x10, /* 00010000 */
1026 | 0x10, /* 00010000 */
1027 | 0x00, /* 00000000 */
1028 | 0x00, /* 00000000 */
1029 |
1030 | /* 85 0x55 'U' */
1031 | 0x00, /* 00000000 */
1032 | 0x44, /* 01000100 */
1033 | 0x44, /* 01000100 */
1034 | 0x44, /* 01000100 */
1035 | 0x44, /* 01000100 */
1036 | 0x44, /* 01000100 */
1037 | 0x44, /* 01000100 */
1038 | 0x38, /* 00111000 */
1039 | 0x00, /* 00000000 */
1040 | 0x00, /* 00000000 */
1041 |
1042 | /* 86 0x56 'V' */
1043 | 0x00, /* 00000000 */
1044 | 0x44, /* 01000100 */
1045 | 0x44, /* 01000100 */
1046 | 0x44, /* 01000100 */
1047 | 0x44, /* 01000100 */
1048 | 0x44, /* 01000100 */
1049 | 0x28, /* 00101000 */
1050 | 0x10, /* 00010000 */
1051 | 0x00, /* 00000000 */
1052 | 0x00, /* 00000000 */
1053 |
1054 | /* 87 0x57 'W' */
1055 | 0x00, /* 00000000 */
1056 | 0x44, /* 01000100 */
1057 | 0x44, /* 01000100 */
1058 | 0x44, /* 01000100 */
1059 | 0x54, /* 01010100 */
1060 | 0x54, /* 01010100 */
1061 | 0x6C, /* 01101100 */
1062 | 0x44, /* 01000100 */
1063 | 0x00, /* 00000000 */
1064 | 0x00, /* 00000000 */
1065 |
1066 | /* 88 0x58 'X' */
1067 | 0x00, /* 00000000 */
1068 | 0x44, /* 01000100 */
1069 | 0x44, /* 01000100 */
1070 | 0x28, /* 00101000 */
1071 | 0x10, /* 00010000 */
1072 | 0x28, /* 00101000 */
1073 | 0x44, /* 01000100 */
1074 | 0x44, /* 01000100 */
1075 | 0x00, /* 00000000 */
1076 | 0x00, /* 00000000 */
1077 |
1078 | /* 89 0x59 'Y' */
1079 | 0x00, /* 00000000 */
1080 | 0x44, /* 01000100 */
1081 | 0x44, /* 01000100 */
1082 | 0x44, /* 01000100 */
1083 | 0x28, /* 00101000 */
1084 | 0x10, /* 00010000 */
1085 | 0x10, /* 00010000 */
1086 | 0x10, /* 00010000 */
1087 | 0x00, /* 00000000 */
1088 | 0x00, /* 00000000 */
1089 |
1090 | /* 90 0x5A 'Z' */
1091 | 0x00, /* 00000000 */
1092 | 0x7C, /* 01111100 */
1093 | 0x04, /* 00000100 */
1094 | 0x08, /* 00001000 */
1095 | 0x10, /* 00010000 */
1096 | 0x20, /* 00100000 */
1097 | 0x40, /* 01000000 */
1098 | 0x7C, /* 01111100 */
1099 | 0x00, /* 00000000 */
1100 | 0x00, /* 00000000 */
1101 |
1102 | /* 91 0x5B '[' */
1103 | 0x18, /* 00011000 */
1104 | 0x10, /* 00010000 */
1105 | 0x10, /* 00010000 */
1106 | 0x10, /* 00010000 */
1107 | 0x10, /* 00010000 */
1108 | 0x10, /* 00010000 */
1109 | 0x10, /* 00010000 */
1110 | 0x10, /* 00010000 */
1111 | 0x18, /* 00011000 */
1112 | 0x00, /* 00000000 */
1113 |
1114 | /* 92 0x5C '\' */
1115 | 0x40, /* 01000000 */
1116 | 0x40, /* 01000000 */
1117 | 0x20, /* 00100000 */
1118 | 0x20, /* 00100000 */
1119 | 0x10, /* 00010000 */
1120 | 0x10, /* 00010000 */
1121 | 0x08, /* 00001000 */
1122 | 0x08, /* 00001000 */
1123 | 0x04, /* 00000100 */
1124 | 0x04, /* 00000100 */
1125 |
1126 | /* 93 0x5D ']' */
1127 | 0x30, /* 00110000 */
1128 | 0x10, /* 00010000 */
1129 | 0x10, /* 00010000 */
1130 | 0x10, /* 00010000 */
1131 | 0x10, /* 00010000 */
1132 | 0x10, /* 00010000 */
1133 | 0x10, /* 00010000 */
1134 | 0x10, /* 00010000 */
1135 | 0x30, /* 00110000 */
1136 | 0x00, /* 00000000 */
1137 |
1138 | /* 94 0x5E '^' */
1139 | 0x00, /* 00000000 */
1140 | 0x10, /* 00010000 */
1141 | 0x28, /* 00101000 */
1142 | 0x44, /* 01000100 */
1143 | 0x00, /* 00000000 */
1144 | 0x00, /* 00000000 */
1145 | 0x00, /* 00000000 */
1146 | 0x00, /* 00000000 */
1147 | 0x00, /* 00000000 */
1148 | 0x00, /* 00000000 */
1149 |
1150 | /* 95 0x5F '_' */
1151 | 0x00, /* 00000000 */
1152 | 0x00, /* 00000000 */
1153 | 0x00, /* 00000000 */
1154 | 0x00, /* 00000000 */
1155 | 0x00, /* 00000000 */
1156 | 0x00, /* 00000000 */
1157 | 0x00, /* 00000000 */
1158 | 0x00, /* 00000000 */
1159 | 0x7C, /* 01111100 */
1160 | 0x00, /* 00000000 */
1161 |
1162 | /* 96 0x60 '`' */
1163 | 0x20, /* 00100000 */
1164 | 0x10, /* 00010000 */
1165 | 0x08, /* 00001000 */
1166 | 0x00, /* 00000000 */
1167 | 0x00, /* 00000000 */
1168 | 0x00, /* 00000000 */
1169 | 0x00, /* 00000000 */
1170 | 0x00, /* 00000000 */
1171 | 0x00, /* 00000000 */
1172 | 0x00, /* 00000000 */
1173 |
1174 | /* 97 0x61 'a' */
1175 | 0x00, /* 00000000 */
1176 | 0x00, /* 00000000 */
1177 | 0x00, /* 00000000 */
1178 | 0x38, /* 00111000 */
1179 | 0x04, /* 00000100 */
1180 | 0x3C, /* 00111100 */
1181 | 0x44, /* 01000100 */
1182 | 0x3C, /* 00111100 */
1183 | 0x00, /* 00000000 */
1184 | 0x00, /* 00000000 */
1185 |
1186 | /* 98 0x62 'b' */
1187 | 0x00, /* 00000000 */
1188 | 0x40, /* 01000000 */
1189 | 0x40, /* 01000000 */
1190 | 0x58, /* 01011000 */
1191 | 0x64, /* 01100100 */
1192 | 0x44, /* 01000100 */
1193 | 0x64, /* 01100100 */
1194 | 0x58, /* 01011000 */
1195 | 0x00, /* 00000000 */
1196 | 0x00, /* 00000000 */
1197 |
1198 | /* 99 0x63 'c' */
1199 | 0x00, /* 00000000 */
1200 | 0x00, /* 00000000 */
1201 | 0x00, /* 00000000 */
1202 | 0x38, /* 00111000 */
1203 | 0x44, /* 01000100 */
1204 | 0x40, /* 01000000 */
1205 | 0x44, /* 01000100 */
1206 | 0x38, /* 00111000 */
1207 | 0x00, /* 00000000 */
1208 | 0x00, /* 00000000 */
1209 |
1210 | /* 100 0x64 'd' */
1211 | 0x00, /* 00000000 */
1212 | 0x04, /* 00000100 */
1213 | 0x04, /* 00000100 */
1214 | 0x34, /* 00110100 */
1215 | 0x4C, /* 01001100 */
1216 | 0x44, /* 01000100 */
1217 | 0x4C, /* 01001100 */
1218 | 0x34, /* 00110100 */
1219 | 0x00, /* 00000000 */
1220 | 0x00, /* 00000000 */
1221 |
1222 | /* 101 0x65 'e' */
1223 | 0x00, /* 00000000 */
1224 | 0x00, /* 00000000 */
1225 | 0x00, /* 00000000 */
1226 | 0x38, /* 00111000 */
1227 | 0x44, /* 01000100 */
1228 | 0x7C, /* 01111100 */
1229 | 0x40, /* 01000000 */
1230 | 0x3C, /* 00111100 */
1231 | 0x00, /* 00000000 */
1232 | 0x00, /* 00000000 */
1233 |
1234 | /* 102 0x66 'f' */
1235 | 0x00, /* 00000000 */
1236 | 0x0C, /* 00001100 */
1237 | 0x10, /* 00010000 */
1238 | 0x10, /* 00010000 */
1239 | 0x38, /* 00111000 */
1240 | 0x10, /* 00010000 */
1241 | 0x10, /* 00010000 */
1242 | 0x10, /* 00010000 */
1243 | 0x00, /* 00000000 */
1244 | 0x00, /* 00000000 */
1245 |
1246 | /* 103 0x67 'g' */
1247 | 0x00, /* 00000000 */
1248 | 0x00, /* 00000000 */
1249 | 0x00, /* 00000000 */
1250 | 0x34, /* 00110100 */
1251 | 0x4C, /* 01001100 */
1252 | 0x44, /* 01000100 */
1253 | 0x4C, /* 01001100 */
1254 | 0x34, /* 00110100 */
1255 | 0x04, /* 00000100 */
1256 | 0x38, /* 00111000 */
1257 |
1258 | /* 104 0x68 'h' */
1259 | 0x00, /* 00000000 */
1260 | 0x40, /* 01000000 */
1261 | 0x40, /* 01000000 */
1262 | 0x78, /* 01111000 */
1263 | 0x44, /* 01000100 */
1264 | 0x44, /* 01000100 */
1265 | 0x44, /* 01000100 */
1266 | 0x44, /* 01000100 */
1267 | 0x00, /* 00000000 */
1268 | 0x00, /* 00000000 */
1269 |
1270 | /* 105 0x69 'i' */
1271 | 0x00, /* 00000000 */
1272 | 0x10, /* 00010000 */
1273 | 0x00, /* 00000000 */
1274 | 0x30, /* 00110000 */
1275 | 0x10, /* 00010000 */
1276 | 0x10, /* 00010000 */
1277 | 0x10, /* 00010000 */
1278 | 0x38, /* 00111000 */
1279 | 0x00, /* 00000000 */
1280 | 0x00, /* 00000000 */
1281 |
1282 | /* 106 0x6A 'j' */
1283 | 0x00, /* 00000000 */
1284 | 0x10, /* 00010000 */
1285 | 0x00, /* 00000000 */
1286 | 0x30, /* 00110000 */
1287 | 0x10, /* 00010000 */
1288 | 0x10, /* 00010000 */
1289 | 0x10, /* 00010000 */
1290 | 0x10, /* 00010000 */
1291 | 0x10, /* 00010000 */
1292 | 0x60, /* 01100000 */
1293 |
1294 | /* 107 0x6B 'k' */
1295 | 0x00, /* 00000000 */
1296 | 0x40, /* 01000000 */
1297 | 0x40, /* 01000000 */
1298 | 0x48, /* 01001000 */
1299 | 0x50, /* 01010000 */
1300 | 0x70, /* 01110000 */
1301 | 0x48, /* 01001000 */
1302 | 0x44, /* 01000100 */
1303 | 0x00, /* 00000000 */
1304 | 0x00, /* 00000000 */
1305 |
1306 | /* 108 0x6C 'l' */
1307 | 0x00, /* 00000000 */
1308 | 0x30, /* 00110000 */
1309 | 0x10, /* 00010000 */
1310 | 0x10, /* 00010000 */
1311 | 0x10, /* 00010000 */
1312 | 0x10, /* 00010000 */
1313 | 0x10, /* 00010000 */
1314 | 0x38, /* 00111000 */
1315 | 0x00, /* 00000000 */
1316 | 0x00, /* 00000000 */
1317 |
1318 | /* 109 0x6D 'm' */
1319 | 0x00, /* 00000000 */
1320 | 0x00, /* 00000000 */
1321 | 0x00, /* 00000000 */
1322 | 0x68, /* 01101000 */
1323 | 0x54, /* 01010100 */
1324 | 0x54, /* 01010100 */
1325 | 0x54, /* 01010100 */
1326 | 0x54, /* 01010100 */
1327 | 0x00, /* 00000000 */
1328 | 0x00, /* 00000000 */
1329 |
1330 | /* 110 0x6E 'n' */
1331 | 0x00, /* 00000000 */
1332 | 0x00, /* 00000000 */
1333 | 0x00, /* 00000000 */
1334 | 0x58, /* 01011000 */
1335 | 0x64, /* 01100100 */
1336 | 0x44, /* 01000100 */
1337 | 0x44, /* 01000100 */
1338 | 0x44, /* 01000100 */
1339 | 0x00, /* 00000000 */
1340 | 0x00, /* 00000000 */
1341 |
1342 | /* 111 0x6F 'o' */
1343 | 0x00, /* 00000000 */
1344 | 0x00, /* 00000000 */
1345 | 0x00, /* 00000000 */
1346 | 0x38, /* 00111000 */
1347 | 0x44, /* 01000100 */
1348 | 0x44, /* 01000100 */
1349 | 0x44, /* 01000100 */
1350 | 0x38, /* 00111000 */
1351 | 0x00, /* 00000000 */
1352 | 0x00, /* 00000000 */
1353 |
1354 | /* 112 0x70 'p' */
1355 | 0x00, /* 00000000 */
1356 | 0x00, /* 00000000 */
1357 | 0x00, /* 00000000 */
1358 | 0x58, /* 01011000 */
1359 | 0x64, /* 01100100 */
1360 | 0x44, /* 01000100 */
1361 | 0x64, /* 01100100 */
1362 | 0x58, /* 01011000 */
1363 | 0x40, /* 01000000 */
1364 | 0x40, /* 01000000 */
1365 |
1366 | /* 113 0x71 'q' */
1367 | 0x00, /* 00000000 */
1368 | 0x00, /* 00000000 */
1369 | 0x00, /* 00000000 */
1370 | 0x34, /* 00110100 */
1371 | 0x4C, /* 01001100 */
1372 | 0x44, /* 01000100 */
1373 | 0x4C, /* 01001100 */
1374 | 0x34, /* 00110100 */
1375 | 0x04, /* 00000100 */
1376 | 0x04, /* 00000100 */
1377 |
1378 | /* 114 0x72 'r' */
1379 | 0x00, /* 00000000 */
1380 | 0x00, /* 00000000 */
1381 | 0x00, /* 00000000 */
1382 | 0x58, /* 01011000 */
1383 | 0x64, /* 01100100 */
1384 | 0x40, /* 01000000 */
1385 | 0x40, /* 01000000 */
1386 | 0x40, /* 01000000 */
1387 | 0x00, /* 00000000 */
1388 | 0x00, /* 00000000 */
1389 |
1390 | /* 115 0x73 's' */
1391 | 0x00, /* 00000000 */
1392 | 0x00, /* 00000000 */
1393 | 0x00, /* 00000000 */
1394 | 0x3C, /* 00111100 */
1395 | 0x40, /* 01000000 */
1396 | 0x38, /* 00111000 */
1397 | 0x04, /* 00000100 */
1398 | 0x78, /* 01111000 */
1399 | 0x00, /* 00000000 */
1400 | 0x00, /* 00000000 */
1401 |
1402 | /* 116 0x74 't' */
1403 | 0x00, /* 00000000 */
1404 | 0x10, /* 00010000 */
1405 | 0x10, /* 00010000 */
1406 | 0x38, /* 00111000 */
1407 | 0x10, /* 00010000 */
1408 | 0x10, /* 00010000 */
1409 | 0x10, /* 00010000 */
1410 | 0x0C, /* 00001100 */
1411 | 0x00, /* 00000000 */
1412 | 0x00, /* 00000000 */
1413 |
1414 | /* 117 0x75 'u' */
1415 | 0x00, /* 00000000 */
1416 | 0x00, /* 00000000 */
1417 | 0x00, /* 00000000 */
1418 | 0x44, /* 01000100 */
1419 | 0x44, /* 01000100 */
1420 | 0x44, /* 01000100 */
1421 | 0x4C, /* 01001100 */
1422 | 0x34, /* 00110100 */
1423 | 0x00, /* 00000000 */
1424 | 0x00, /* 00000000 */
1425 |
1426 | /* 118 0x76 'v' */
1427 | 0x00, /* 00000000 */
1428 | 0x00, /* 00000000 */
1429 | 0x00, /* 00000000 */
1430 | 0x44, /* 01000100 */
1431 | 0x44, /* 01000100 */
1432 | 0x44, /* 01000100 */
1433 | 0x28, /* 00101000 */
1434 | 0x10, /* 00010000 */
1435 | 0x00, /* 00000000 */
1436 | 0x00, /* 00000000 */
1437 |
1438 | /* 119 0x77 'w' */
1439 | 0x00, /* 00000000 */
1440 | 0x00, /* 00000000 */
1441 | 0x00, /* 00000000 */
1442 | 0x54, /* 01010100 */
1443 | 0x54, /* 01010100 */
1444 | 0x54, /* 01010100 */
1445 | 0x54, /* 01010100 */
1446 | 0x28, /* 00101000 */
1447 | 0x00, /* 00000000 */
1448 | 0x00, /* 00000000 */
1449 |
1450 | /* 120 0x78 'x' */
1451 | 0x00, /* 00000000 */
1452 | 0x00, /* 00000000 */
1453 | 0x00, /* 00000000 */
1454 | 0x44, /* 01000100 */
1455 | 0x28, /* 00101000 */
1456 | 0x10, /* 00010000 */
1457 | 0x28, /* 00101000 */
1458 | 0x44, /* 01000100 */
1459 | 0x00, /* 00000000 */
1460 | 0x00, /* 00000000 */
1461 |
1462 | /* 121 0x79 'y' */
1463 | 0x00, /* 00000000 */
1464 | 0x00, /* 00000000 */
1465 | 0x00, /* 00000000 */
1466 | 0x44, /* 01000100 */
1467 | 0x44, /* 01000100 */
1468 | 0x44, /* 01000100 */
1469 | 0x44, /* 01000100 */
1470 | 0x3C, /* 00111100 */
1471 | 0x04, /* 00000100 */
1472 | 0x38, /* 00111000 */
1473 |
1474 | /* 122 0x7A 'z' */
1475 | 0x00, /* 00000000 */
1476 | 0x00, /* 00000000 */
1477 | 0x00, /* 00000000 */
1478 | 0x7C, /* 01111100 */
1479 | 0x08, /* 00001000 */
1480 | 0x10, /* 00010000 */
1481 | 0x20, /* 00100000 */
1482 | 0x7C, /* 01111100 */
1483 | 0x00, /* 00000000 */
1484 | 0x00, /* 00000000 */
1485 |
1486 | /* 123 0x7B '{' */
1487 | 0x08, /* 00001000 */
1488 | 0x10, /* 00010000 */
1489 | 0x10, /* 00010000 */
1490 | 0x10, /* 00010000 */
1491 | 0x20, /* 00100000 */
1492 | 0x10, /* 00010000 */
1493 | 0x10, /* 00010000 */
1494 | 0x10, /* 00010000 */
1495 | 0x08, /* 00001000 */
1496 | 0x00, /* 00000000 */
1497 |
1498 | /* 124 0x7C '|' */
1499 | 0x10, /* 00010000 */
1500 | 0x10, /* 00010000 */
1501 | 0x10, /* 00010000 */
1502 | 0x10, /* 00010000 */
1503 | 0x00, /* 00000000 */
1504 | 0x10, /* 00010000 */
1505 | 0x10, /* 00010000 */
1506 | 0x10, /* 00010000 */
1507 | 0x10, /* 00010000 */
1508 | 0x00, /* 00000000 */
1509 |
1510 | /* 125 0x7D '}' */
1511 | 0x20, /* 00100000 */
1512 | 0x10, /* 00010000 */
1513 | 0x10, /* 00010000 */
1514 | 0x10, /* 00010000 */
1515 | 0x08, /* 00001000 */
1516 | 0x10, /* 00010000 */
1517 | 0x10, /* 00010000 */
1518 | 0x10, /* 00010000 */
1519 | 0x20, /* 00100000 */
1520 | 0x00, /* 00000000 */
1521 |
1522 | /* 126 0x7E '~' */
1523 | 0x00, /* 00000000 */
1524 | 0x00, /* 00000000 */
1525 | 0x00, /* 00000000 */
1526 | 0x00, /* 00000000 */
1527 | 0x20, /* 00100000 */
1528 | 0x54, /* 01010100 */
1529 | 0x08, /* 00001000 */
1530 | 0x00, /* 00000000 */
1531 | 0x00, /* 00000000 */
1532 | 0x00, /* 00000000 */
1533 |
1534 | /* 127 0x7F '' */
1535 | 0x00, /* 00000000 */
1536 | 0x00, /* 00000000 */
1537 | 0x00, /* 00000000 */
1538 | 0x10, /* 00010000 */
1539 | 0x28, /* 00101000 */
1540 | 0x44, /* 01000100 */
1541 | 0x44, /* 01000100 */
1542 | 0x7C, /* 01111100 */
1543 | 0x00, /* 00000000 */
1544 | 0x00, /* 00000000 */
1545 |
1546 | /* 128 0x80 '\200' */
1547 | 0x00, /* 00000000 */
1548 | 0x38, /* 00111000 */
1549 | 0x44, /* 01000100 */
1550 | 0x40, /* 01000000 */
1551 | 0x40, /* 01000000 */
1552 | 0x40, /* 01000000 */
1553 | 0x44, /* 01000100 */
1554 | 0x38, /* 00111000 */
1555 | 0x10, /* 00010000 */
1556 | 0x20, /* 00100000 */
1557 |
1558 | /* 129 0x81 '\201' */
1559 | 0x00, /* 00000000 */
1560 | 0x28, /* 00101000 */
1561 | 0x00, /* 00000000 */
1562 | 0x44, /* 01000100 */
1563 | 0x44, /* 01000100 */
1564 | 0x44, /* 01000100 */
1565 | 0x4C, /* 01001100 */
1566 | 0x34, /* 00110100 */
1567 | 0x00, /* 00000000 */
1568 | 0x00, /* 00000000 */
1569 |
1570 | /* 130 0x82 '\202' */
1571 | 0x08, /* 00001000 */
1572 | 0x10, /* 00010000 */
1573 | 0x00, /* 00000000 */
1574 | 0x38, /* 00111000 */
1575 | 0x44, /* 01000100 */
1576 | 0x7C, /* 01111100 */
1577 | 0x40, /* 01000000 */
1578 | 0x3C, /* 00111100 */
1579 | 0x00, /* 00000000 */
1580 | 0x00, /* 00000000 */
1581 |
1582 | /* 131 0x83 '\203' */
1583 | 0x10, /* 00010000 */
1584 | 0x28, /* 00101000 */
1585 | 0x00, /* 00000000 */
1586 | 0x38, /* 00111000 */
1587 | 0x04, /* 00000100 */
1588 | 0x3C, /* 00111100 */
1589 | 0x44, /* 01000100 */
1590 | 0x3C, /* 00111100 */
1591 | 0x00, /* 00000000 */
1592 | 0x00, /* 00000000 */
1593 |
1594 | /* 132 0x84 '\204' */
1595 | 0x00, /* 00000000 */
1596 | 0x28, /* 00101000 */
1597 | 0x00, /* 00000000 */
1598 | 0x38, /* 00111000 */
1599 | 0x04, /* 00000100 */
1600 | 0x3C, /* 00111100 */
1601 | 0x44, /* 01000100 */
1602 | 0x3C, /* 00111100 */
1603 | 0x00, /* 00000000 */
1604 | 0x00, /* 00000000 */
1605 |
1606 | /* 133 0x85 '\205' */
1607 | 0x10, /* 00010000 */
1608 | 0x08, /* 00001000 */
1609 | 0x00, /* 00000000 */
1610 | 0x38, /* 00111000 */
1611 | 0x04, /* 00000100 */
1612 | 0x3C, /* 00111100 */
1613 | 0x44, /* 01000100 */
1614 | 0x3C, /* 00111100 */
1615 | 0x00, /* 00000000 */
1616 | 0x00, /* 00000000 */
1617 |
1618 | /* 134 0x86 '\206' */
1619 | 0x18, /* 00011000 */
1620 | 0x24, /* 00100100 */
1621 | 0x18, /* 00011000 */
1622 | 0x38, /* 00111000 */
1623 | 0x04, /* 00000100 */
1624 | 0x3C, /* 00111100 */
1625 | 0x44, /* 01000100 */
1626 | 0x3C, /* 00111100 */
1627 | 0x00, /* 00000000 */
1628 | 0x00, /* 00000000 */
1629 |
1630 | /* 135 0x87 '\207' */
1631 | 0x00, /* 00000000 */
1632 | 0x00, /* 00000000 */
1633 | 0x00, /* 00000000 */
1634 | 0x38, /* 00111000 */
1635 | 0x44, /* 01000100 */
1636 | 0x40, /* 01000000 */
1637 | 0x44, /* 01000100 */
1638 | 0x38, /* 00111000 */
1639 | 0x10, /* 00010000 */
1640 | 0x20, /* 00100000 */
1641 |
1642 | /* 136 0x88 '\210' */
1643 | 0x10, /* 00010000 */
1644 | 0x28, /* 00101000 */
1645 | 0x00, /* 00000000 */
1646 | 0x38, /* 00111000 */
1647 | 0x44, /* 01000100 */
1648 | 0x7C, /* 01111100 */
1649 | 0x40, /* 01000000 */
1650 | 0x3C, /* 00111100 */
1651 | 0x00, /* 00000000 */
1652 | 0x00, /* 00000000 */
1653 |
1654 | /* 137 0x89 '\211' */
1655 | 0x00, /* 00000000 */
1656 | 0x28, /* 00101000 */
1657 | 0x00, /* 00000000 */
1658 | 0x38, /* 00111000 */
1659 | 0x44, /* 01000100 */
1660 | 0x7C, /* 01111100 */
1661 | 0x40, /* 01000000 */
1662 | 0x3C, /* 00111100 */
1663 | 0x00, /* 00000000 */
1664 | 0x00, /* 00000000 */
1665 |
1666 | /* 138 0x8A '\212' */
1667 | 0x20, /* 00100000 */
1668 | 0x10, /* 00010000 */
1669 | 0x00, /* 00000000 */
1670 | 0x38, /* 00111000 */
1671 | 0x44, /* 01000100 */
1672 | 0x7C, /* 01111100 */
1673 | 0x40, /* 01000000 */
1674 | 0x3C, /* 00111100 */
1675 | 0x00, /* 00000000 */
1676 | 0x00, /* 00000000 */
1677 |
1678 | /* 139 0x8B '\213' */
1679 | 0x00, /* 00000000 */
1680 | 0x28, /* 00101000 */
1681 | 0x00, /* 00000000 */
1682 | 0x30, /* 00110000 */
1683 | 0x10, /* 00010000 */
1684 | 0x10, /* 00010000 */
1685 | 0x10, /* 00010000 */
1686 | 0x38, /* 00111000 */
1687 | 0x00, /* 00000000 */
1688 | 0x00, /* 00000000 */
1689 |
1690 | /* 140 0x8C '\214' */
1691 | 0x10, /* 00010000 */
1692 | 0x28, /* 00101000 */
1693 | 0x00, /* 00000000 */
1694 | 0x30, /* 00110000 */
1695 | 0x10, /* 00010000 */
1696 | 0x10, /* 00010000 */
1697 | 0x10, /* 00010000 */
1698 | 0x38, /* 00111000 */
1699 | 0x00, /* 00000000 */
1700 | 0x00, /* 00000000 */
1701 |
1702 | /* 141 0x8D '\215' */
1703 | 0x20, /* 00100000 */
1704 | 0x10, /* 00010000 */
1705 | 0x00, /* 00000000 */
1706 | 0x30, /* 00110000 */
1707 | 0x10, /* 00010000 */
1708 | 0x10, /* 00010000 */
1709 | 0x10, /* 00010000 */
1710 | 0x38, /* 00111000 */
1711 | 0x00, /* 00000000 */
1712 | 0x00, /* 00000000 */
1713 |
1714 | /* 142 0x8E '\216' */
1715 | 0x44, /* 01000100 */
1716 | 0x10, /* 00010000 */
1717 | 0x28, /* 00101000 */
1718 | 0x44, /* 01000100 */
1719 | 0x44, /* 01000100 */
1720 | 0x7C, /* 01111100 */
1721 | 0x44, /* 01000100 */
1722 | 0x44, /* 01000100 */
1723 | 0x00, /* 00000000 */
1724 | 0x00, /* 00000000 */
1725 |
1726 | /* 143 0x8F '\217' */
1727 | 0x30, /* 00110000 */
1728 | 0x48, /* 01001000 */
1729 | 0x38, /* 00111000 */
1730 | 0x44, /* 01000100 */
1731 | 0x44, /* 01000100 */
1732 | 0x7C, /* 01111100 */
1733 | 0x44, /* 01000100 */
1734 | 0x44, /* 01000100 */
1735 | 0x00, /* 00000000 */
1736 | 0x00, /* 00000000 */
1737 |
1738 | /* 144 0x90 '\220' */
1739 | 0x10, /* 00010000 */
1740 | 0x7C, /* 01111100 */
1741 | 0x40, /* 01000000 */
1742 | 0x40, /* 01000000 */
1743 | 0x78, /* 01111000 */
1744 | 0x40, /* 01000000 */
1745 | 0x40, /* 01000000 */
1746 | 0x7C, /* 01111100 */
1747 | 0x00, /* 00000000 */
1748 | 0x00, /* 00000000 */
1749 |
1750 | /* 145 0x91 '\221' */
1751 | 0x00, /* 00000000 */
1752 | 0x00, /* 00000000 */
1753 | 0x00, /* 00000000 */
1754 | 0x78, /* 01111000 */
1755 | 0x14, /* 00010100 */
1756 | 0x7C, /* 01111100 */
1757 | 0x50, /* 01010000 */
1758 | 0x3C, /* 00111100 */
1759 | 0x00, /* 00000000 */
1760 | 0x00, /* 00000000 */
1761 |
1762 | /* 146 0x92 '\222' */
1763 | 0x00, /* 00000000 */
1764 | 0x3C, /* 00111100 */
1765 | 0x50, /* 01010000 */
1766 | 0x50, /* 01010000 */
1767 | 0x78, /* 01111000 */
1768 | 0x50, /* 01010000 */
1769 | 0x50, /* 01010000 */
1770 | 0x5C, /* 01011100 */
1771 | 0x00, /* 00000000 */
1772 | 0x00, /* 00000000 */
1773 |
1774 | /* 147 0x93 '\223' */
1775 | 0x10, /* 00010000 */
1776 | 0x28, /* 00101000 */
1777 | 0x00, /* 00000000 */
1778 | 0x38, /* 00111000 */
1779 | 0x44, /* 01000100 */
1780 | 0x44, /* 01000100 */
1781 | 0x44, /* 01000100 */
1782 | 0x38, /* 00111000 */
1783 | 0x00, /* 00000000 */
1784 | 0x00, /* 00000000 */
1785 |
1786 | /* 148 0x94 '\224' */
1787 | 0x00, /* 00000000 */
1788 | 0x28, /* 00101000 */
1789 | 0x00, /* 00000000 */
1790 | 0x38, /* 00111000 */
1791 | 0x44, /* 01000100 */
1792 | 0x44, /* 01000100 */
1793 | 0x44, /* 01000100 */
1794 | 0x38, /* 00111000 */
1795 | 0x00, /* 00000000 */
1796 | 0x00, /* 00000000 */
1797 |
1798 | /* 149 0x95 '\225' */
1799 | 0x20, /* 00100000 */
1800 | 0x10, /* 00010000 */
1801 | 0x00, /* 00000000 */
1802 | 0x38, /* 00111000 */
1803 | 0x44, /* 01000100 */
1804 | 0x44, /* 01000100 */
1805 | 0x44, /* 01000100 */
1806 | 0x38, /* 00111000 */
1807 | 0x00, /* 00000000 */
1808 | 0x00, /* 00000000 */
1809 |
1810 | /* 150 0x96 '\226' */
1811 | 0x10, /* 00010000 */
1812 | 0x28, /* 00101000 */
1813 | 0x00, /* 00000000 */
1814 | 0x44, /* 01000100 */
1815 | 0x44, /* 01000100 */
1816 | 0x44, /* 01000100 */
1817 | 0x4C, /* 01001100 */
1818 | 0x34, /* 00110100 */
1819 | 0x00, /* 00000000 */
1820 | 0x00, /* 00000000 */
1821 |
1822 | /* 151 0x97 '\227' */
1823 | 0x20, /* 00100000 */
1824 | 0x10, /* 00010000 */
1825 | 0x00, /* 00000000 */
1826 | 0x44, /* 01000100 */
1827 | 0x44, /* 01000100 */
1828 | 0x44, /* 01000100 */
1829 | 0x4C, /* 01001100 */
1830 | 0x34, /* 00110100 */
1831 | 0x00, /* 00000000 */
1832 | 0x00, /* 00000000 */
1833 |
1834 | /* 152 0x98 '\230' */
1835 | 0x00, /* 00000000 */
1836 | 0x28, /* 00101000 */
1837 | 0x00, /* 00000000 */
1838 | 0x44, /* 01000100 */
1839 | 0x44, /* 01000100 */
1840 | 0x44, /* 01000100 */
1841 | 0x44, /* 01000100 */
1842 | 0x3C, /* 00111100 */
1843 | 0x04, /* 00000100 */
1844 | 0x38, /* 00111000 */
1845 |
1846 | /* 153 0x99 '\231' */
1847 | 0x84, /* 10000100 */
1848 | 0x38, /* 00111000 */
1849 | 0x44, /* 01000100 */
1850 | 0x44, /* 01000100 */
1851 | 0x44, /* 01000100 */
1852 | 0x44, /* 01000100 */
1853 | 0x44, /* 01000100 */
1854 | 0x38, /* 00111000 */
1855 | 0x00, /* 00000000 */
1856 | 0x00, /* 00000000 */
1857 |
1858 | /* 154 0x9A '\232' */
1859 | 0x88, /* 10001000 */
1860 | 0x44, /* 01000100 */
1861 | 0x44, /* 01000100 */
1862 | 0x44, /* 01000100 */
1863 | 0x44, /* 01000100 */
1864 | 0x44, /* 01000100 */
1865 | 0x44, /* 01000100 */
1866 | 0x38, /* 00111000 */
1867 | 0x00, /* 00000000 */
1868 | 0x00, /* 00000000 */
1869 |
1870 | /* 155 0x9B '\233' */
1871 | 0x00, /* 00000000 */
1872 | 0x00, /* 00000000 */
1873 | 0x10, /* 00010000 */
1874 | 0x38, /* 00111000 */
1875 | 0x54, /* 01010100 */
1876 | 0x50, /* 01010000 */
1877 | 0x54, /* 01010100 */
1878 | 0x38, /* 00111000 */
1879 | 0x10, /* 00010000 */
1880 | 0x00, /* 00000000 */
1881 |
1882 | /* 156 0x9C '\234' */
1883 | 0x30, /* 00110000 */
1884 | 0x48, /* 01001000 */
1885 | 0x40, /* 01000000 */
1886 | 0x70, /* 01110000 */
1887 | 0x40, /* 01000000 */
1888 | 0x40, /* 01000000 */
1889 | 0x44, /* 01000100 */
1890 | 0x78, /* 01111000 */
1891 | 0x00, /* 00000000 */
1892 | 0x00, /* 00000000 */
1893 |
1894 | /* 157 0x9D '\235' */
1895 | 0x00, /* 00000000 */
1896 | 0x44, /* 01000100 */
1897 | 0x28, /* 00101000 */
1898 | 0x7C, /* 01111100 */
1899 | 0x10, /* 00010000 */
1900 | 0x7C, /* 01111100 */
1901 | 0x10, /* 00010000 */
1902 | 0x10, /* 00010000 */
1903 | 0x00, /* 00000000 */
1904 | 0x00, /* 00000000 */
1905 |
1906 | /* 158 0x9E '\236' */
1907 | 0x00, /* 00000000 */
1908 | 0x70, /* 01110000 */
1909 | 0x48, /* 01001000 */
1910 | 0x70, /* 01110000 */
1911 | 0x48, /* 01001000 */
1912 | 0x5C, /* 01011100 */
1913 | 0x48, /* 01001000 */
1914 | 0x44, /* 01000100 */
1915 | 0x00, /* 00000000 */
1916 | 0x00, /* 00000000 */
1917 |
1918 | /* 159 0x9F '\237' */
1919 | 0x00, /* 00000000 */
1920 | 0x0C, /* 00001100 */
1921 | 0x10, /* 00010000 */
1922 | 0x10, /* 00010000 */
1923 | 0x38, /* 00111000 */
1924 | 0x10, /* 00010000 */
1925 | 0x10, /* 00010000 */
1926 | 0x60, /* 01100000 */
1927 | 0x00, /* 00000000 */
1928 | 0x00, /* 00000000 */
1929 |
1930 | /* 160 0xA0 '\240' */
1931 | 0x08, /* 00001000 */
1932 | 0x10, /* 00010000 */
1933 | 0x00, /* 00000000 */
1934 | 0x38, /* 00111000 */
1935 | 0x04, /* 00000100 */
1936 | 0x3C, /* 00111100 */
1937 | 0x44, /* 01000100 */
1938 | 0x3C, /* 00111100 */
1939 | 0x00, /* 00000000 */
1940 | 0x00, /* 00000000 */
1941 |
1942 | /* 161 0xA1 '\241' */
1943 | 0x08, /* 00001000 */
1944 | 0x10, /* 00010000 */
1945 | 0x00, /* 00000000 */
1946 | 0x30, /* 00110000 */
1947 | 0x10, /* 00010000 */
1948 | 0x10, /* 00010000 */
1949 | 0x10, /* 00010000 */
1950 | 0x38, /* 00111000 */
1951 | 0x00, /* 00000000 */
1952 | 0x00, /* 00000000 */
1953 |
1954 | /* 162 0xA2 '\242' */
1955 | 0x08, /* 00001000 */
1956 | 0x10, /* 00010000 */
1957 | 0x00, /* 00000000 */
1958 | 0x38, /* 00111000 */
1959 | 0x44, /* 01000100 */
1960 | 0x44, /* 01000100 */
1961 | 0x44, /* 01000100 */
1962 | 0x38, /* 00111000 */
1963 | 0x00, /* 00000000 */
1964 | 0x00, /* 00000000 */
1965 |
1966 | /* 163 0xA3 '\243' */
1967 | 0x08, /* 00001000 */
1968 | 0x10, /* 00010000 */
1969 | 0x00, /* 00000000 */
1970 | 0x44, /* 01000100 */
1971 | 0x44, /* 01000100 */
1972 | 0x44, /* 01000100 */
1973 | 0x4C, /* 01001100 */
1974 | 0x34, /* 00110100 */
1975 | 0x00, /* 00000000 */
1976 | 0x00, /* 00000000 */
1977 |
1978 | /* 164 0xA4 '\244' */
1979 | 0x34, /* 00110100 */
1980 | 0x58, /* 01011000 */
1981 | 0x00, /* 00000000 */
1982 | 0x58, /* 01011000 */
1983 | 0x64, /* 01100100 */
1984 | 0x44, /* 01000100 */
1985 | 0x44, /* 01000100 */
1986 | 0x44, /* 01000100 */
1987 | 0x00, /* 00000000 */
1988 | 0x00, /* 00000000 */
1989 |
1990 | /* 165 0xA5 '\245' */
1991 | 0x58, /* 01011000 */
1992 | 0x44, /* 01000100 */
1993 | 0x64, /* 01100100 */
1994 | 0x54, /* 01010100 */
1995 | 0x4C, /* 01001100 */
1996 | 0x44, /* 01000100 */
1997 | 0x44, /* 01000100 */
1998 | 0x44, /* 01000100 */
1999 | 0x00, /* 00000000 */
2000 | 0x00, /* 00000000 */
2001 |
2002 | /* 166 0xA6 '\246' */
2003 | 0x00, /* 00000000 */
2004 | 0x38, /* 00111000 */
2005 | 0x04, /* 00000100 */
2006 | 0x3C, /* 00111100 */
2007 | 0x44, /* 01000100 */
2008 | 0x3C, /* 00111100 */
2009 | 0x00, /* 00000000 */
2010 | 0x7C, /* 01111100 */
2011 | 0x00, /* 00000000 */
2012 | 0x00, /* 00000000 */
2013 |
2014 | /* 167 0xA7 '\247' */
2015 | 0x00, /* 00000000 */
2016 | 0x38, /* 00111000 */
2017 | 0x44, /* 01000100 */
2018 | 0x44, /* 01000100 */
2019 | 0x44, /* 01000100 */
2020 | 0x38, /* 00111000 */
2021 | 0x00, /* 00000000 */
2022 | 0x7C, /* 01111100 */
2023 | 0x00, /* 00000000 */
2024 | 0x00, /* 00000000 */
2025 |
2026 | /* 168 0xA8 '\250' */
2027 | 0x00, /* 00000000 */
2028 | 0x10, /* 00010000 */
2029 | 0x00, /* 00000000 */
2030 | 0x10, /* 00010000 */
2031 | 0x20, /* 00100000 */
2032 | 0x40, /* 01000000 */
2033 | 0x44, /* 01000100 */
2034 | 0x38, /* 00111000 */
2035 | 0x00, /* 00000000 */
2036 | 0x00, /* 00000000 */
2037 |
2038 | /* 169 0xA9 '\251' */
2039 | 0x00, /* 00000000 */
2040 | 0x00, /* 00000000 */
2041 | 0x00, /* 00000000 */
2042 | 0x00, /* 00000000 */
2043 | 0x7C, /* 01111100 */
2044 | 0x40, /* 01000000 */
2045 | 0x40, /* 01000000 */
2046 | 0x00, /* 00000000 */
2047 | 0x00, /* 00000000 */
2048 | 0x00, /* 00000000 */
2049 |
2050 | /* 170 0xAA '\252' */
2051 | 0x00, /* 00000000 */
2052 | 0x00, /* 00000000 */
2053 | 0x00, /* 00000000 */
2054 | 0x00, /* 00000000 */
2055 | 0x7C, /* 01111100 */
2056 | 0x04, /* 00000100 */
2057 | 0x04, /* 00000100 */
2058 | 0x00, /* 00000000 */
2059 | 0x00, /* 00000000 */
2060 | 0x00, /* 00000000 */
2061 |
2062 | /* 171 0xAB '\253' */
2063 | 0x20, /* 00100000 */
2064 | 0x60, /* 01100000 */
2065 | 0x24, /* 00100100 */
2066 | 0x28, /* 00101000 */
2067 | 0x10, /* 00010000 */
2068 | 0x28, /* 00101000 */
2069 | 0x44, /* 01000100 */
2070 | 0x08, /* 00001000 */
2071 | 0x1C, /* 00011100 */
2072 | 0x00, /* 00000000 */
2073 |
2074 | /* 172 0xAC '\254' */
2075 | 0x20, /* 00100000 */
2076 | 0x60, /* 01100000 */
2077 | 0x24, /* 00100100 */
2078 | 0x28, /* 00101000 */
2079 | 0x10, /* 00010000 */
2080 | 0x28, /* 00101000 */
2081 | 0x58, /* 01011000 */
2082 | 0x3C, /* 00111100 */
2083 | 0x08, /* 00001000 */
2084 | 0x00, /* 00000000 */
2085 |
2086 | /* 173 0xAD '\255' */
2087 | 0x00, /* 00000000 */
2088 | 0x10, /* 00010000 */
2089 | 0x00, /* 00000000 */
2090 | 0x10, /* 00010000 */
2091 | 0x10, /* 00010000 */
2092 | 0x10, /* 00010000 */
2093 | 0x10, /* 00010000 */
2094 | 0x10, /* 00010000 */
2095 | 0x00, /* 00000000 */
2096 | 0x00, /* 00000000 */
2097 |
2098 | /* 174 0xAE '\256' */
2099 | 0x00, /* 00000000 */
2100 | 0x00, /* 00000000 */
2101 | 0x00, /* 00000000 */
2102 | 0x24, /* 00100100 */
2103 | 0x48, /* 01001000 */
2104 | 0x90, /* 10010000 */
2105 | 0x48, /* 01001000 */
2106 | 0x24, /* 00100100 */
2107 | 0x00, /* 00000000 */
2108 | 0x00, /* 00000000 */
2109 |
2110 | /* 175 0xAF '\257' */
2111 | 0x00, /* 00000000 */
2112 | 0x00, /* 00000000 */
2113 | 0x00, /* 00000000 */
2114 | 0x90, /* 10010000 */
2115 | 0x48, /* 01001000 */
2116 | 0x24, /* 00100100 */
2117 | 0x48, /* 01001000 */
2118 | 0x90, /* 10010000 */
2119 | 0x00, /* 00000000 */
2120 | 0x00, /* 00000000 */
2121 |
2122 | /* 176 0xB0 '\260' */
2123 | 0x10, /* 00010000 */
2124 | 0x44, /* 01000100 */
2125 | 0x10, /* 00010000 */
2126 | 0x44, /* 01000100 */
2127 | 0x10, /* 00010000 */
2128 | 0x44, /* 01000100 */
2129 | 0x10, /* 00010000 */
2130 | 0x44, /* 01000100 */
2131 | 0x10, /* 00010000 */
2132 | 0x44, /* 01000100 */
2133 |
2134 | /* 177 0xB1 '\261' */
2135 | 0xA8, /* 10101000 */
2136 | 0x54, /* 01010100 */
2137 | 0xA8, /* 10101000 */
2138 | 0x54, /* 01010100 */
2139 | 0xA8, /* 10101000 */
2140 | 0x54, /* 01010100 */
2141 | 0xA8, /* 10101000 */
2142 | 0x54, /* 01010100 */
2143 | 0xA8, /* 10101000 */
2144 | 0x54, /* 01010100 */
2145 |
2146 | /* 178 0xB2 '\262' */
2147 | 0xDC, /* 11011100 */
2148 | 0x74, /* 01110100 */
2149 | 0xDC, /* 11011100 */
2150 | 0x74, /* 01110100 */
2151 | 0xDC, /* 11011100 */
2152 | 0x74, /* 01110100 */
2153 | 0xDC, /* 11011100 */
2154 | 0x74, /* 01110100 */
2155 | 0xDC, /* 11011100 */
2156 | 0x74, /* 01110100 */
2157 |
2158 | /* 179 0xB3 '\263' */
2159 | 0x10, /* 00010000 */
2160 | 0x10, /* 00010000 */
2161 | 0x10, /* 00010000 */
2162 | 0x10, /* 00010000 */
2163 | 0x10, /* 00010000 */
2164 | 0x10, /* 00010000 */
2165 | 0x10, /* 00010000 */
2166 | 0x10, /* 00010000 */
2167 | 0x10, /* 00010000 */
2168 | 0x10, /* 00010000 */
2169 |
2170 | /* 180 0xB4 '\264' */
2171 | 0x10, /* 00010000 */
2172 | 0x10, /* 00010000 */
2173 | 0x10, /* 00010000 */
2174 | 0x10, /* 00010000 */
2175 | 0xF0, /* 11110000 */
2176 | 0x10, /* 00010000 */
2177 | 0x10, /* 00010000 */
2178 | 0x10, /* 00010000 */
2179 | 0x10, /* 00010000 */
2180 | 0x10, /* 00010000 */
2181 |
2182 | /* 181 0xB5 '\265' */
2183 | 0x10, /* 00010000 */
2184 | 0x10, /* 00010000 */
2185 | 0x10, /* 00010000 */
2186 | 0xF0, /* 11110000 */
2187 | 0x10, /* 00010000 */
2188 | 0xF0, /* 11110000 */
2189 | 0x10, /* 00010000 */
2190 | 0x10, /* 00010000 */
2191 | 0x10, /* 00010000 */
2192 | 0x10, /* 00010000 */
2193 |
2194 | /* 182 0xB6 '\266' */
2195 | 0x28, /* 00101000 */
2196 | 0x28, /* 00101000 */
2197 | 0x28, /* 00101000 */
2198 | 0x28, /* 00101000 */
2199 | 0xE8, /* 11101000 */
2200 | 0x28, /* 00101000 */
2201 | 0x28, /* 00101000 */
2202 | 0x28, /* 00101000 */
2203 | 0x28, /* 00101000 */
2204 | 0x28, /* 00101000 */
2205 |
2206 | /* 183 0xB7 '\267' */
2207 | 0x00, /* 00000000 */
2208 | 0x00, /* 00000000 */
2209 | 0x00, /* 00000000 */
2210 | 0x00, /* 00000000 */
2211 | 0xF8, /* 11111000 */
2212 | 0x28, /* 00101000 */
2213 | 0x28, /* 00101000 */
2214 | 0x28, /* 00101000 */
2215 | 0x28, /* 00101000 */
2216 | 0x28, /* 00101000 */
2217 |
2218 | /* 184 0xB8 '\270' */
2219 | 0x00, /* 00000000 */
2220 | 0x00, /* 00000000 */
2221 | 0x00, /* 00000000 */
2222 | 0xF0, /* 11110000 */
2223 | 0x10, /* 00010000 */
2224 | 0xF0, /* 11110000 */
2225 | 0x10, /* 00010000 */
2226 | 0x10, /* 00010000 */
2227 | 0x10, /* 00010000 */
2228 | 0x10, /* 00010000 */
2229 |
2230 | /* 185 0xB9 '\271' */
2231 | 0x28, /* 00101000 */
2232 | 0x28, /* 00101000 */
2233 | 0x28, /* 00101000 */
2234 | 0xE8, /* 11101000 */
2235 | 0x08, /* 00001000 */
2236 | 0xE8, /* 11101000 */
2237 | 0x28, /* 00101000 */
2238 | 0x28, /* 00101000 */
2239 | 0x28, /* 00101000 */
2240 | 0x28, /* 00101000 */
2241 |
2242 | /* 186 0xBA '\272' */
2243 | 0x28, /* 00101000 */
2244 | 0x28, /* 00101000 */
2245 | 0x28, /* 00101000 */
2246 | 0x28, /* 00101000 */
2247 | 0x28, /* 00101000 */
2248 | 0x28, /* 00101000 */
2249 | 0x28, /* 00101000 */
2250 | 0x28, /* 00101000 */
2251 | 0x28, /* 00101000 */
2252 | 0x28, /* 00101000 */
2253 |
2254 | /* 187 0xBB '\273' */
2255 | 0x00, /* 00000000 */
2256 | 0x00, /* 00000000 */
2257 | 0x00, /* 00000000 */
2258 | 0xF8, /* 11111000 */
2259 | 0x08, /* 00001000 */
2260 | 0xE8, /* 11101000 */
2261 | 0x28, /* 00101000 */
2262 | 0x28, /* 00101000 */
2263 | 0x28, /* 00101000 */
2264 | 0x28, /* 00101000 */
2265 |
2266 | /* 188 0xBC '\274' */
2267 | 0x28, /* 00101000 */
2268 | 0x28, /* 00101000 */
2269 | 0x28, /* 00101000 */
2270 | 0xE8, /* 11101000 */
2271 | 0x08, /* 00001000 */
2272 | 0xF8, /* 11111000 */
2273 | 0x00, /* 00000000 */
2274 | 0x00, /* 00000000 */
2275 | 0x00, /* 00000000 */
2276 | 0x00, /* 00000000 */
2277 |
2278 | /* 189 0xBD '\275' */
2279 | 0x28, /* 00101000 */
2280 | 0x28, /* 00101000 */
2281 | 0x28, /* 00101000 */
2282 | 0x28, /* 00101000 */
2283 | 0xF8, /* 11111000 */
2284 | 0x00, /* 00000000 */
2285 | 0x00, /* 00000000 */
2286 | 0x00, /* 00000000 */
2287 | 0x00, /* 00000000 */
2288 | 0x00, /* 00000000 */
2289 |
2290 | /* 190 0xBE '\276' */
2291 | 0x10, /* 00010000 */
2292 | 0x10, /* 00010000 */
2293 | 0x10, /* 00010000 */
2294 | 0xF0, /* 11110000 */
2295 | 0x10, /* 00010000 */
2296 | 0xF0, /* 11110000 */
2297 | 0x00, /* 00000000 */
2298 | 0x00, /* 00000000 */
2299 | 0x00, /* 00000000 */
2300 | 0x00, /* 00000000 */
2301 |
2302 | /* 191 0xBF '\277' */
2303 | 0x00, /* 00000000 */
2304 | 0x00, /* 00000000 */
2305 | 0x00, /* 00000000 */
2306 | 0x00, /* 00000000 */
2307 | 0xF0, /* 11110000 */
2308 | 0x10, /* 00010000 */
2309 | 0x10, /* 00010000 */
2310 | 0x10, /* 00010000 */
2311 | 0x10, /* 00010000 */
2312 | 0x10, /* 00010000 */
2313 |
2314 | /* 192 0xC0 '\300' */
2315 | 0x10, /* 00010000 */
2316 | 0x10, /* 00010000 */
2317 | 0x10, /* 00010000 */
2318 | 0x10, /* 00010000 */
2319 | 0x1C, /* 00011100 */
2320 | 0x00, /* 00000000 */
2321 | 0x00, /* 00000000 */
2322 | 0x00, /* 00000000 */
2323 | 0x00, /* 00000000 */
2324 | 0x00, /* 00000000 */
2325 |
2326 | /* 193 0xC1 '\301' */
2327 | 0x10, /* 00010000 */
2328 | 0x10, /* 00010000 */
2329 | 0x10, /* 00010000 */
2330 | 0x10, /* 00010000 */
2331 | 0xFC, /* 11111100 */
2332 | 0x00, /* 00000000 */
2333 | 0x00, /* 00000000 */
2334 | 0x00, /* 00000000 */
2335 | 0x00, /* 00000000 */
2336 | 0x00, /* 00000000 */
2337 |
2338 | /* 194 0xC2 '\302' */
2339 | 0x00, /* 00000000 */
2340 | 0x00, /* 00000000 */
2341 | 0x00, /* 00000000 */
2342 | 0x00, /* 00000000 */
2343 | 0xFC, /* 11111100 */
2344 | 0x10, /* 00010000 */
2345 | 0x10, /* 00010000 */
2346 | 0x10, /* 00010000 */
2347 | 0x10, /* 00010000 */
2348 | 0x10, /* 00010000 */
2349 |
2350 | /* 195 0xC3 '\303' */
2351 | 0x10, /* 00010000 */
2352 | 0x10, /* 00010000 */
2353 | 0x10, /* 00010000 */
2354 | 0x10, /* 00010000 */
2355 | 0x1C, /* 00011100 */
2356 | 0x10, /* 00010000 */
2357 | 0x10, /* 00010000 */
2358 | 0x10, /* 00010000 */
2359 | 0x10, /* 00010000 */
2360 | 0x10, /* 00010000 */
2361 |
2362 | /* 196 0xC4 '\304' */
2363 | 0x00, /* 00000000 */
2364 | 0x00, /* 00000000 */
2365 | 0x00, /* 00000000 */
2366 | 0x00, /* 00000000 */
2367 | 0xFC, /* 11111100 */
2368 | 0x00, /* 00000000 */
2369 | 0x00, /* 00000000 */
2370 | 0x00, /* 00000000 */
2371 | 0x00, /* 00000000 */
2372 | 0x00, /* 00000000 */
2373 |
2374 | /* 197 0xC5 '\305' */
2375 | 0x10, /* 00010000 */
2376 | 0x10, /* 00010000 */
2377 | 0x10, /* 00010000 */
2378 | 0x10, /* 00010000 */
2379 | 0xFC, /* 11111100 */
2380 | 0x10, /* 00010000 */
2381 | 0x10, /* 00010000 */
2382 | 0x10, /* 00010000 */
2383 | 0x10, /* 00010000 */
2384 | 0x10, /* 00010000 */
2385 |
2386 | /* 198 0xC6 '\306' */
2387 | 0x10, /* 00010000 */
2388 | 0x10, /* 00010000 */
2389 | 0x10, /* 00010000 */
2390 | 0x1C, /* 00011100 */
2391 | 0x10, /* 00010000 */
2392 | 0x1C, /* 00011100 */
2393 | 0x10, /* 00010000 */
2394 | 0x10, /* 00010000 */
2395 | 0x10, /* 00010000 */
2396 | 0x10, /* 00010000 */
2397 |
2398 | /* 199 0xC7 '\307' */
2399 | 0x28, /* 00101000 */
2400 | 0x28, /* 00101000 */
2401 | 0x28, /* 00101000 */
2402 | 0x28, /* 00101000 */
2403 | 0x2C, /* 00101100 */
2404 | 0x28, /* 00101000 */
2405 | 0x28, /* 00101000 */
2406 | 0x28, /* 00101000 */
2407 | 0x28, /* 00101000 */
2408 | 0x28, /* 00101000 */
2409 |
2410 | /* 200 0xC8 '\310' */
2411 | 0x28, /* 00101000 */
2412 | 0x28, /* 00101000 */
2413 | 0x28, /* 00101000 */
2414 | 0x2C, /* 00101100 */
2415 | 0x20, /* 00100000 */
2416 | 0x3C, /* 00111100 */
2417 | 0x00, /* 00000000 */
2418 | 0x00, /* 00000000 */
2419 | 0x00, /* 00000000 */
2420 | 0x00, /* 00000000 */
2421 |
2422 | /* 201 0xC9 '\311' */
2423 | 0x00, /* 00000000 */
2424 | 0x00, /* 00000000 */
2425 | 0x00, /* 00000000 */
2426 | 0x3C, /* 00111100 */
2427 | 0x20, /* 00100000 */
2428 | 0x2C, /* 00101100 */
2429 | 0x28, /* 00101000 */
2430 | 0x28, /* 00101000 */
2431 | 0x28, /* 00101000 */
2432 | 0x28, /* 00101000 */
2433 |
2434 | /* 202 0xCA '\312' */
2435 | 0x28, /* 00101000 */
2436 | 0x28, /* 00101000 */
2437 | 0x28, /* 00101000 */
2438 | 0xEC, /* 11101100 */
2439 | 0x00, /* 00000000 */
2440 | 0xFC, /* 11111100 */
2441 | 0x00, /* 00000000 */
2442 | 0x00, /* 00000000 */
2443 | 0x00, /* 00000000 */
2444 | 0x00, /* 00000000 */
2445 |
2446 | /* 203 0xCB '\313' */
2447 | 0x00, /* 00000000 */
2448 | 0x00, /* 00000000 */
2449 | 0x00, /* 00000000 */
2450 | 0xFC, /* 11111100 */
2451 | 0x00, /* 00000000 */
2452 | 0xEC, /* 11101100 */
2453 | 0x28, /* 00101000 */
2454 | 0x28, /* 00101000 */
2455 | 0x28, /* 00101000 */
2456 | 0x28, /* 00101000 */
2457 |
2458 | /* 204 0xCC '\314' */
2459 | 0x28, /* 00101000 */
2460 | 0x28, /* 00101000 */
2461 | 0x28, /* 00101000 */
2462 | 0x2C, /* 00101100 */
2463 | 0x20, /* 00100000 */
2464 | 0x2C, /* 00101100 */
2465 | 0x28, /* 00101000 */
2466 | 0x28, /* 00101000 */
2467 | 0x28, /* 00101000 */
2468 | 0x28, /* 00101000 */
2469 |
2470 | /* 205 0xCD '\315' */
2471 | 0x00, /* 00000000 */
2472 | 0x00, /* 00000000 */
2473 | 0x00, /* 00000000 */
2474 | 0xFC, /* 11111100 */
2475 | 0x00, /* 00000000 */
2476 | 0xFC, /* 11111100 */
2477 | 0x00, /* 00000000 */
2478 | 0x00, /* 00000000 */
2479 | 0x00, /* 00000000 */
2480 | 0x00, /* 00000000 */
2481 |
2482 | /* 206 0xCE '\316' */
2483 | 0x28, /* 00101000 */
2484 | 0x28, /* 00101000 */
2485 | 0x28, /* 00101000 */
2486 | 0xEC, /* 11101100 */
2487 | 0x00, /* 00000000 */
2488 | 0xEC, /* 11101100 */
2489 | 0x28, /* 00101000 */
2490 | 0x28, /* 00101000 */
2491 | 0x28, /* 00101000 */
2492 | 0x28, /* 00101000 */
2493 |
2494 | /* 207 0xCF '\317' */
2495 | 0x10, /* 00010000 */
2496 | 0x10, /* 00010000 */
2497 | 0x10, /* 00010000 */
2498 | 0xFC, /* 11111100 */
2499 | 0x00, /* 00000000 */
2500 | 0xFC, /* 11111100 */
2501 | 0x00, /* 00000000 */
2502 | 0x00, /* 00000000 */
2503 | 0x00, /* 00000000 */
2504 | 0x00, /* 00000000 */
2505 |
2506 | /* 208 0xD0 '\320' */
2507 | 0x28, /* 00101000 */
2508 | 0x28, /* 00101000 */
2509 | 0x28, /* 00101000 */
2510 | 0x28, /* 00101000 */
2511 | 0xFC, /* 11111100 */
2512 | 0x00, /* 00000000 */
2513 | 0x00, /* 00000000 */
2514 | 0x00, /* 00000000 */
2515 | 0x00, /* 00000000 */
2516 | 0x00, /* 00000000 */
2517 |
2518 | /* 209 0xD1 '\321' */
2519 | 0x00, /* 00000000 */
2520 | 0x00, /* 00000000 */
2521 | 0x00, /* 00000000 */
2522 | 0xFC, /* 11111100 */
2523 | 0x00, /* 00000000 */
2524 | 0xFC, /* 11111100 */
2525 | 0x10, /* 00010000 */
2526 | 0x10, /* 00010000 */
2527 | 0x10, /* 00010000 */
2528 | 0x10, /* 00010000 */
2529 |
2530 | /* 210 0xD2 '\322' */
2531 | 0x00, /* 00000000 */
2532 | 0x00, /* 00000000 */
2533 | 0x00, /* 00000000 */
2534 | 0x00, /* 00000000 */
2535 | 0xFC, /* 11111100 */
2536 | 0x28, /* 00101000 */
2537 | 0x28, /* 00101000 */
2538 | 0x28, /* 00101000 */
2539 | 0x28, /* 00101000 */
2540 | 0x28, /* 00101000 */
2541 |
2542 | /* 211 0xD3 '\323' */
2543 | 0x28, /* 00101000 */
2544 | 0x28, /* 00101000 */
2545 | 0x28, /* 00101000 */
2546 | 0x28, /* 00101000 */
2547 | 0x3C, /* 00111100 */
2548 | 0x00, /* 00000000 */
2549 | 0x00, /* 00000000 */
2550 | 0x00, /* 00000000 */
2551 | 0x00, /* 00000000 */
2552 | 0x00, /* 00000000 */
2553 |
2554 | /* 212 0xD4 '\324' */
2555 | 0x10, /* 00010000 */
2556 | 0x10, /* 00010000 */
2557 | 0x10, /* 00010000 */
2558 | 0x1C, /* 00011100 */
2559 | 0x10, /* 00010000 */
2560 | 0x1C, /* 00011100 */
2561 | 0x00, /* 00000000 */
2562 | 0x00, /* 00000000 */
2563 | 0x00, /* 00000000 */
2564 | 0x00, /* 00000000 */
2565 |
2566 | /* 213 0xD5 '\325' */
2567 | 0x00, /* 00000000 */
2568 | 0x00, /* 00000000 */
2569 | 0x00, /* 00000000 */
2570 | 0x1C, /* 00011100 */
2571 | 0x10, /* 00010000 */
2572 | 0x1C, /* 00011100 */
2573 | 0x10, /* 00010000 */
2574 | 0x10, /* 00010000 */
2575 | 0x10, /* 00010000 */
2576 | 0x10, /* 00010000 */
2577 |
2578 | /* 214 0xD6 '\326' */
2579 | 0x00, /* 00000000 */
2580 | 0x00, /* 00000000 */
2581 | 0x00, /* 00000000 */
2582 | 0x00, /* 00000000 */
2583 | 0x3C, /* 00111100 */
2584 | 0x28, /* 00101000 */
2585 | 0x28, /* 00101000 */
2586 | 0x28, /* 00101000 */
2587 | 0x28, /* 00101000 */
2588 | 0x28, /* 00101000 */
2589 |
2590 | /* 215 0xD7 '\327' */
2591 | 0x28, /* 00101000 */
2592 | 0x28, /* 00101000 */
2593 | 0x28, /* 00101000 */
2594 | 0x28, /* 00101000 */
2595 | 0xFC, /* 11111100 */
2596 | 0x28, /* 00101000 */
2597 | 0x28, /* 00101000 */
2598 | 0x28, /* 00101000 */
2599 | 0x28, /* 00101000 */
2600 | 0x28, /* 00101000 */
2601 |
2602 | /* 216 0xD8 '\330' */
2603 | 0x10, /* 00010000 */
2604 | 0x10, /* 00010000 */
2605 | 0x10, /* 00010000 */
2606 | 0xFC, /* 11111100 */
2607 | 0x10, /* 00010000 */
2608 | 0xFC, /* 11111100 */
2609 | 0x10, /* 00010000 */
2610 | 0x10, /* 00010000 */
2611 | 0x10, /* 00010000 */
2612 | 0x10, /* 00010000 */
2613 |
2614 | /* 217 0xD9 '\331' */
2615 | 0x10, /* 00010000 */
2616 | 0x10, /* 00010000 */
2617 | 0x10, /* 00010000 */
2618 | 0x10, /* 00010000 */
2619 | 0xF0, /* 11110000 */
2620 | 0x00, /* 00000000 */
2621 | 0x00, /* 00000000 */
2622 | 0x00, /* 00000000 */
2623 | 0x00, /* 00000000 */
2624 | 0x00, /* 00000000 */
2625 |
2626 | /* 218 0xDA '\332' */
2627 | 0x00, /* 00000000 */
2628 | 0x00, /* 00000000 */
2629 | 0x00, /* 00000000 */
2630 | 0x00, /* 00000000 */
2631 | 0x1C, /* 00011100 */
2632 | 0x10, /* 00010000 */
2633 | 0x10, /* 00010000 */
2634 | 0x10, /* 00010000 */
2635 | 0x10, /* 00010000 */
2636 | 0x10, /* 00010000 */
2637 |
2638 | /* 219 0xDB '\333' */
2639 | 0xFC, /* 11111100 */
2640 | 0xFC, /* 11111100 */
2641 | 0xFC, /* 11111100 */
2642 | 0xFC, /* 11111100 */
2643 | 0xFC, /* 11111100 */
2644 | 0xFC, /* 11111100 */
2645 | 0xFC, /* 11111100 */
2646 | 0xFC, /* 11111100 */
2647 | 0xFC, /* 11111100 */
2648 | 0xFC, /* 11111100 */
2649 |
2650 | /* 220 0xDC '\334' */
2651 | 0x00, /* 00000000 */
2652 | 0x00, /* 00000000 */
2653 | 0x00, /* 00000000 */
2654 | 0x00, /* 00000000 */
2655 | 0x00, /* 00000000 */
2656 | 0xFC, /* 11111100 */
2657 | 0xFC, /* 11111100 */
2658 | 0xFC, /* 11111100 */
2659 | 0xFC, /* 11111100 */
2660 | 0xFC, /* 11111100 */
2661 |
2662 | /* 221 0xDD '\335' */
2663 | 0xE0, /* 11100000 */
2664 | 0xE0, /* 11100000 */
2665 | 0xE0, /* 11100000 */
2666 | 0xE0, /* 11100000 */
2667 | 0xE0, /* 11100000 */
2668 | 0xE0, /* 11100000 */
2669 | 0xE0, /* 11100000 */
2670 | 0xE0, /* 11100000 */
2671 | 0xE0, /* 11100000 */
2672 | 0xE0, /* 11100000 */
2673 |
2674 | /* 222 0xDE '\336' */
2675 | 0x1C, /* 00011100 */
2676 | 0x1C, /* 00011100 */
2677 | 0x1C, /* 00011100 */
2678 | 0x1C, /* 00011100 */
2679 | 0x1C, /* 00011100 */
2680 | 0x1C, /* 00011100 */
2681 | 0x1C, /* 00011100 */
2682 | 0x1C, /* 00011100 */
2683 | 0x1C, /* 00011100 */
2684 | 0x1C, /* 00011100 */
2685 |
2686 | /* 223 0xDF '\337' */
2687 | 0xFC, /* 11111100 */
2688 | 0xFC, /* 11111100 */
2689 | 0xFC, /* 11111100 */
2690 | 0xFC, /* 11111100 */
2691 | 0xFC, /* 11111100 */
2692 | 0x00, /* 00000000 */
2693 | 0x00, /* 00000000 */
2694 | 0x00, /* 00000000 */
2695 | 0x00, /* 00000000 */
2696 | 0x00, /* 00000000 */
2697 |
2698 | /* 224 0xE0 '\340' */
2699 | 0x00, /* 00000000 */
2700 | 0x00, /* 00000000 */
2701 | 0x00, /* 00000000 */
2702 | 0x34, /* 00110100 */
2703 | 0x48, /* 01001000 */
2704 | 0x48, /* 01001000 */
2705 | 0x48, /* 01001000 */
2706 | 0x34, /* 00110100 */
2707 | 0x00, /* 00000000 */
2708 | 0x00, /* 00000000 */
2709 |
2710 | /* 225 0xE1 '\341' */
2711 | 0x18, /* 00011000 */
2712 | 0x24, /* 00100100 */
2713 | 0x44, /* 01000100 */
2714 | 0x48, /* 01001000 */
2715 | 0x48, /* 01001000 */
2716 | 0x44, /* 01000100 */
2717 | 0x44, /* 01000100 */
2718 | 0x58, /* 01011000 */
2719 | 0x40, /* 01000000 */
2720 | 0x00, /* 00000000 */
2721 |
2722 | /* 226 0xE2 '\342' */
2723 | 0x00, /* 00000000 */
2724 | 0x7C, /* 01111100 */
2725 | 0x44, /* 01000100 */
2726 | 0x44, /* 01000100 */
2727 | 0x40, /* 01000000 */
2728 | 0x40, /* 01000000 */
2729 | 0x40, /* 01000000 */
2730 | 0x40, /* 01000000 */
2731 | 0x00, /* 00000000 */
2732 | 0x00, /* 00000000 */
2733 |
2734 | /* 227 0xE3 '\343' */
2735 | 0x00, /* 00000000 */
2736 | 0x00, /* 00000000 */
2737 | 0x00, /* 00000000 */
2738 | 0x7C, /* 01111100 */
2739 | 0x28, /* 00101000 */
2740 | 0x28, /* 00101000 */
2741 | 0x28, /* 00101000 */
2742 | 0x28, /* 00101000 */
2743 | 0x00, /* 00000000 */
2744 | 0x00, /* 00000000 */
2745 |
2746 | /* 228 0xE4 '\344' */
2747 | 0x00, /* 00000000 */
2748 | 0x7C, /* 01111100 */
2749 | 0x24, /* 00100100 */
2750 | 0x10, /* 00010000 */
2751 | 0x08, /* 00001000 */
2752 | 0x10, /* 00010000 */
2753 | 0x24, /* 00100100 */
2754 | 0x7C, /* 01111100 */
2755 | 0x00, /* 00000000 */
2756 | 0x00, /* 00000000 */
2757 |
2758 | /* 229 0xE5 '\345' */
2759 | 0x00, /* 00000000 */
2760 | 0x00, /* 00000000 */
2761 | 0x00, /* 00000000 */
2762 | 0x3C, /* 00111100 */
2763 | 0x48, /* 01001000 */
2764 | 0x48, /* 01001000 */
2765 | 0x48, /* 01001000 */
2766 | 0x30, /* 00110000 */
2767 | 0x00, /* 00000000 */
2768 | 0x00, /* 00000000 */
2769 |
2770 | /* 230 0xE6 '\346' */
2771 | 0x00, /* 00000000 */
2772 | 0x00, /* 00000000 */
2773 | 0x00, /* 00000000 */
2774 | 0x48, /* 01001000 */
2775 | 0x48, /* 01001000 */
2776 | 0x48, /* 01001000 */
2777 | 0x48, /* 01001000 */
2778 | 0x74, /* 01110100 */
2779 | 0x40, /* 01000000 */
2780 | 0x40, /* 01000000 */
2781 |
2782 | /* 231 0xE7 '\347' */
2783 | 0x00, /* 00000000 */
2784 | 0x00, /* 00000000 */
2785 | 0x00, /* 00000000 */
2786 | 0x7C, /* 01111100 */
2787 | 0x10, /* 00010000 */
2788 | 0x10, /* 00010000 */
2789 | 0x10, /* 00010000 */
2790 | 0x0C, /* 00001100 */
2791 | 0x00, /* 00000000 */
2792 | 0x00, /* 00000000 */
2793 |
2794 | /* 232 0xE8 '\350' */
2795 | 0x38, /* 00111000 */
2796 | 0x10, /* 00010000 */
2797 | 0x38, /* 00111000 */
2798 | 0x44, /* 01000100 */
2799 | 0x44, /* 01000100 */
2800 | 0x38, /* 00111000 */
2801 | 0x10, /* 00010000 */
2802 | 0x38, /* 00111000 */
2803 | 0x00, /* 00000000 */
2804 | 0x00, /* 00000000 */
2805 |
2806 | /* 233 0xE9 '\351' */
2807 | 0x00, /* 00000000 */
2808 | 0x38, /* 00111000 */
2809 | 0x44, /* 01000100 */
2810 | 0x44, /* 01000100 */
2811 | 0x7C, /* 01111100 */
2812 | 0x44, /* 01000100 */
2813 | 0x44, /* 01000100 */
2814 | 0x38, /* 00111000 */
2815 | 0x00, /* 00000000 */
2816 | 0x00, /* 00000000 */
2817 |
2818 | /* 234 0xEA '\352' */
2819 | 0x00, /* 00000000 */
2820 | 0x38, /* 00111000 */
2821 | 0x44, /* 01000100 */
2822 | 0x44, /* 01000100 */
2823 | 0x44, /* 01000100 */
2824 | 0x44, /* 01000100 */
2825 | 0x28, /* 00101000 */
2826 | 0x6C, /* 01101100 */
2827 | 0x00, /* 00000000 */
2828 | 0x00, /* 00000000 */
2829 |
2830 | /* 235 0xEB '\353' */
2831 | 0x00, /* 00000000 */
2832 | 0x18, /* 00011000 */
2833 | 0x20, /* 00100000 */
2834 | 0x18, /* 00011000 */
2835 | 0x24, /* 00100100 */
2836 | 0x24, /* 00100100 */
2837 | 0x24, /* 00100100 */
2838 | 0x18, /* 00011000 */
2839 | 0x00, /* 00000000 */
2840 | 0x00, /* 00000000 */
2841 |
2842 | /* 236 0xEC '\354' */
2843 | 0x00, /* 00000000 */
2844 | 0x00, /* 00000000 */
2845 | 0x00, /* 00000000 */
2846 | 0x38, /* 00111000 */
2847 | 0x54, /* 01010100 */
2848 | 0x54, /* 01010100 */
2849 | 0x54, /* 01010100 */
2850 | 0x38, /* 00111000 */
2851 | 0x00, /* 00000000 */
2852 | 0x00, /* 00000000 */
2853 |
2854 | /* 237 0xED '\355' */
2855 | 0x00, /* 00000000 */
2856 | 0x00, /* 00000000 */
2857 | 0x04, /* 00000100 */
2858 | 0x38, /* 00111000 */
2859 | 0x54, /* 01010100 */
2860 | 0x54, /* 01010100 */
2861 | 0x38, /* 00111000 */
2862 | 0x40, /* 01000000 */
2863 | 0x00, /* 00000000 */
2864 | 0x00, /* 00000000 */
2865 |
2866 | /* 238 0xEE '\356' */
2867 | 0x00, /* 00000000 */
2868 | 0x3C, /* 00111100 */
2869 | 0x40, /* 01000000 */
2870 | 0x40, /* 01000000 */
2871 | 0x38, /* 00111000 */
2872 | 0x40, /* 01000000 */
2873 | 0x40, /* 01000000 */
2874 | 0x3C, /* 00111100 */
2875 | 0x00, /* 00000000 */
2876 | 0x00, /* 00000000 */
2877 |
2878 | /* 239 0xEF '\357' */
2879 | 0x00, /* 00000000 */
2880 | 0x38, /* 00111000 */
2881 | 0x44, /* 01000100 */
2882 | 0x44, /* 01000100 */
2883 | 0x44, /* 01000100 */
2884 | 0x44, /* 01000100 */
2885 | 0x44, /* 01000100 */
2886 | 0x44, /* 01000100 */
2887 | 0x00, /* 00000000 */
2888 | 0x00, /* 00000000 */
2889 |
2890 | /* 240 0xF0 '\360' */
2891 | 0x00, /* 00000000 */
2892 | 0x00, /* 00000000 */
2893 | 0xFC, /* 11111100 */
2894 | 0x00, /* 00000000 */
2895 | 0xFC, /* 11111100 */
2896 | 0x00, /* 00000000 */
2897 | 0xFC, /* 11111100 */
2898 | 0x00, /* 00000000 */
2899 | 0x00, /* 00000000 */
2900 | 0x00, /* 00000000 */
2901 |
2902 | /* 241 0xF1 '\361' */
2903 | 0x00, /* 00000000 */
2904 | 0x10, /* 00010000 */
2905 | 0x10, /* 00010000 */
2906 | 0x7C, /* 01111100 */
2907 | 0x10, /* 00010000 */
2908 | 0x10, /* 00010000 */
2909 | 0x00, /* 00000000 */
2910 | 0x7C, /* 01111100 */
2911 | 0x00, /* 00000000 */
2912 | 0x00, /* 00000000 */
2913 |
2914 | /* 242 0xF2 '\362' */
2915 | 0x00, /* 00000000 */
2916 | 0x20, /* 00100000 */
2917 | 0x10, /* 00010000 */
2918 | 0x08, /* 00001000 */
2919 | 0x10, /* 00010000 */
2920 | 0x20, /* 00100000 */
2921 | 0x00, /* 00000000 */
2922 | 0x38, /* 00111000 */
2923 | 0x00, /* 00000000 */
2924 | 0x00, /* 00000000 */
2925 |
2926 | /* 243 0xF3 '\363' */
2927 | 0x00, /* 00000000 */
2928 | 0x08, /* 00001000 */
2929 | 0x10, /* 00010000 */
2930 | 0x20, /* 00100000 */
2931 | 0x10, /* 00010000 */
2932 | 0x08, /* 00001000 */
2933 | 0x00, /* 00000000 */
2934 | 0x38, /* 00111000 */
2935 | 0x00, /* 00000000 */
2936 | 0x00, /* 00000000 */
2937 |
2938 | /* 244 0xF4 '\364' */
2939 | 0x00, /* 00000000 */
2940 | 0x0C, /* 00001100 */
2941 | 0x10, /* 00010000 */
2942 | 0x10, /* 00010000 */
2943 | 0x10, /* 00010000 */
2944 | 0x10, /* 00010000 */
2945 | 0x10, /* 00010000 */
2946 | 0x10, /* 00010000 */
2947 | 0x10, /* 00010000 */
2948 | 0x10, /* 00010000 */
2949 |
2950 | /* 245 0xF5 '\365' */
2951 | 0x10, /* 00010000 */
2952 | 0x10, /* 00010000 */
2953 | 0x10, /* 00010000 */
2954 | 0x10, /* 00010000 */
2955 | 0x10, /* 00010000 */
2956 | 0x10, /* 00010000 */
2957 | 0x10, /* 00010000 */
2958 | 0x10, /* 00010000 */
2959 | 0x60, /* 01100000 */
2960 | 0x00, /* 00000000 */
2961 |
2962 | /* 246 0xF6 '\366' */
2963 | 0x00, /* 00000000 */
2964 | 0x00, /* 00000000 */
2965 | 0x10, /* 00010000 */
2966 | 0x00, /* 00000000 */
2967 | 0x7C, /* 01111100 */
2968 | 0x00, /* 00000000 */
2969 | 0x10, /* 00010000 */
2970 | 0x00, /* 00000000 */
2971 | 0x00, /* 00000000 */
2972 | 0x00, /* 00000000 */
2973 |
2974 | /* 247 0xF7 '\367' */
2975 | 0x00, /* 00000000 */
2976 | 0x00, /* 00000000 */
2977 | 0x20, /* 00100000 */
2978 | 0x54, /* 01010100 */
2979 | 0x08, /* 00001000 */
2980 | 0x20, /* 00100000 */
2981 | 0x54, /* 01010100 */
2982 | 0x08, /* 00001000 */
2983 | 0x00, /* 00000000 */
2984 | 0x00, /* 00000000 */
2985 |
2986 | /* 248 0xF8 '\370' */
2987 | 0x30, /* 00110000 */
2988 | 0x48, /* 01001000 */
2989 | 0x48, /* 01001000 */
2990 | 0x30, /* 00110000 */
2991 | 0x00, /* 00000000 */
2992 | 0x00, /* 00000000 */
2993 | 0x00, /* 00000000 */
2994 | 0x00, /* 00000000 */
2995 | 0x00, /* 00000000 */
2996 | 0x00, /* 00000000 */
2997 |
2998 | /* 249 0xF9 '\371' */
2999 | 0x00, /* 00000000 */
3000 | 0x00, /* 00000000 */
3001 | 0x00, /* 00000000 */
3002 | 0x10, /* 00010000 */
3003 | 0x38, /* 00111000 */
3004 | 0x10, /* 00010000 */
3005 | 0x00, /* 00000000 */
3006 | 0x00, /* 00000000 */
3007 | 0x00, /* 00000000 */
3008 | 0x00, /* 00000000 */
3009 |
3010 | /* 250 0xFA '\372' */
3011 | 0x00, /* 00000000 */
3012 | 0x00, /* 00000000 */
3013 | 0x00, /* 00000000 */
3014 | 0x00, /* 00000000 */
3015 | 0x10, /* 00010000 */
3016 | 0x00, /* 00000000 */
3017 | 0x00, /* 00000000 */
3018 | 0x00, /* 00000000 */
3019 | 0x00, /* 00000000 */
3020 | 0x00, /* 00000000 */
3021 |
3022 | /* 251 0xFB '\373' */
3023 | 0x00, /* 00000000 */
3024 | 0x04, /* 00000100 */
3025 | 0x08, /* 00001000 */
3026 | 0x08, /* 00001000 */
3027 | 0x50, /* 01010000 */
3028 | 0x50, /* 01010000 */
3029 | 0x20, /* 00100000 */
3030 | 0x20, /* 00100000 */
3031 | 0x00, /* 00000000 */
3032 | 0x00, /* 00000000 */
3033 |
3034 | /* 252 0xFC '\374' */
3035 | 0x60, /* 01100000 */
3036 | 0x50, /* 01010000 */
3037 | 0x50, /* 01010000 */
3038 | 0x50, /* 01010000 */
3039 | 0x00, /* 00000000 */
3040 | 0x00, /* 00000000 */
3041 | 0x00, /* 00000000 */
3042 | 0x00, /* 00000000 */
3043 | 0x00, /* 00000000 */
3044 | 0x00, /* 00000000 */
3045 |
3046 | /* 253 0xFD '\375' */
3047 | 0x60, /* 01100000 */
3048 | 0x10, /* 00010000 */
3049 | 0x20, /* 00100000 */
3050 | 0x70, /* 01110000 */
3051 | 0x00, /* 00000000 */
3052 | 0x00, /* 00000000 */
3053 | 0x00, /* 00000000 */
3054 | 0x00, /* 00000000 */
3055 | 0x00, /* 00000000 */
3056 | 0x00, /* 00000000 */
3057 |
3058 | /* 254 0xFE '\376' */
3059 | 0x00, /* 00000000 */
3060 | 0x00, /* 00000000 */
3061 | 0x38, /* 00111000 */
3062 | 0x38, /* 00111000 */
3063 | 0x38, /* 00111000 */
3064 | 0x38, /* 00111000 */
3065 | 0x38, /* 00111000 */
3066 | 0x38, /* 00111000 */
3067 | 0x00, /* 00000000 */
3068 | 0x00, /* 00000000 */
3069 |
3070 | /* 255 0xFF '\377' */
3071 | 0x00, /* 00000000 */
3072 | 0x00, /* 00000000 */
3073 | 0x00, /* 00000000 */
3074 | 0x00, /* 00000000 */
3075 | 0x00, /* 00000000 */
3076 | 0x00, /* 00000000 */
3077 | 0x00, /* 00000000 */
3078 | 0x00, /* 00000000 */
3079 | 0x00, /* 00000000 */
3080 | 0x00, /* 00000000 */
3081 | };
3082 | const int font_size = sizeof(font);
3083 |
--------------------------------------------------------------------------------
/main.c:
--------------------------------------------------------------------------------
1 | #include
2 | #include
3 | #include
4 | #include
5 | #include
6 | #include "math_utils.h"
7 | #include "renderer.h"
8 |
9 | #include "shaders/texture2d_f.h"
10 | #include "shaders/texture2d_v.h"
11 | #include "shaders/lcd3x_f.h"
12 | #include "shaders/lcd3x_v.h"
13 | #include "shaders/sharp_bilinear_f.h"
14 | #include "shaders/sharp_bilinear_v.h"
15 | #include "shaders/sharp_bilinear_simple_f.h"
16 | #include "shaders/sharp_bilinear_simple_v.h"
17 |
18 | #define ALIGN(x, a) (((x) + ((a) - 1)) & ~((a) - 1))
19 |
20 | #define HOOKS_NUM 5 // Hooked functions num
21 | #define MODES_NUM 5 // Available rescaling modes
22 |
23 | #define HEAP_SIZE 0x3200000
24 |
25 | static uint8_t current_hook;
26 | static SceUID hooks[HOOKS_NUM];
27 | static tai_hook_ref_t refs[HOOKS_NUM];
28 |
29 | void *fb = NULL;
30 | void *src_fb = NULL;
31 | int dst_x, dst_y, src_w, src_h, src_p, src_s;
32 |
33 | static const SceGxmProgram *const gxm_program_texture2d_v = (SceGxmProgram*)&texture2d_v;
34 | static const SceGxmProgram *const gxm_program_texture2d_f = (SceGxmProgram*)&texture2d_f;
35 | SceGxmProgram *complex_vshaders[] = {
36 | (SceGxmProgram*)&sharp_bilinear_v,
37 | (SceGxmProgram*)&sharp_bilinear_simple_v,
38 | (SceGxmProgram*)&lcd3x_v
39 | };
40 | SceGxmProgram *complex_fshaders[] = {
41 | (SceGxmProgram*)&sharp_bilinear_f,
42 | (SceGxmProgram*)&sharp_bilinear_simple_f,
43 | (SceGxmProgram*)&lcd3x_f
44 | };
45 | const SceGxmProgramParameter *shader_params[4];
46 |
47 | SceGxmVertexProgram *vertex_program_patched = NULL;
48 | SceGxmFragmentProgram *fragment_program_patched = NULL;
49 |
50 | static SceGxmRenderTarget *gxm_render_target;
51 | static SceGxmColorSurface gxm_color_surface;
52 | static SceGxmTexture gxm_texture;
53 | static SceGxmContext *gxm_context;
54 | static SceGxmShaderPatcher *gxm_shader_patcher;
55 | static SceGxmShaderPatcherId fragment_id, vertex_id;
56 | static const SceGxmProgramParameter *position;
57 | static const SceGxmProgramParameter *texcoord;
58 | static const SceGxmProgramParameter *wvp;
59 |
60 | static matrix4x4 mvp;
61 | static vector3f *vertices = NULL;
62 | static vector4f *vertices_big = NULL;
63 | static uint16_t *indices = NULL;
64 | static vector2f *texcoords = NULL;
65 | uint8_t *gpu_buffer = NULL;
66 | void *vertex_buffer, *fragment_buffer;
67 |
68 | static uint64_t tick = 0;
69 | static uint64_t tick2 = 0;
70 | static uint64_t tick3 = 0;
71 | static uint64_t lock_tick = 0;
72 |
73 | vector2f *orig_res = NULL;
74 | vector2f *target_res = NULL;
75 |
76 | int renderer_ready = 0;
77 | int lock = 0;
78 | int bilinear = 1;
79 |
80 | uint8_t *cdram_heap = NULL;
81 | uint32_t cdram_size = 0;
82 |
83 | char cfg_fname[256];
84 |
85 | // Available modes
86 | enum {
87 | RESCALER_OFF,
88 | ORIGINAL,
89 | SHARP_BILINEAR,
90 | SHARP_BILINEAR_SIMPLE,
91 | LCD_3X
92 | };
93 |
94 | // Lock screen modes
95 | enum {
96 | UNLOCKED,
97 | MODE_CHANGE,
98 | LOCK_CHANGE,
99 | STARTUP_INFO
100 | };
101 |
102 | char *str_mode[MODES_NUM] = {
103 | "No Rescaler",
104 | "Original",
105 | "Sharp Bilinear",
106 | "Sharp Bilinear Simple",
107 | "LCD x3"
108 | };
109 |
110 | int mode = ORIGINAL;
111 | int lock_screen = STARTUP_INFO;
112 |
113 | void saveConfig() {
114 |
115 | // Saving the new config file
116 | SceUID fd = sceIoOpen(cfg_fname, SCE_O_CREAT | SCE_O_TRUNC | SCE_O_WRONLY, 0777);
117 | if (fd >= 0) {
118 | char cfg[32];
119 | sprintf(cfg, "%i;%i;%i", mode, bilinear, lock);
120 | sceIoWrite(fd, cfg, strlen(cfg));
121 | sceIoClose(fd);
122 | }
123 |
124 | // Locking screen for a second to show info about changed mode
125 | }
126 |
127 | void releaseOldShader() {
128 | if (vertex_program_patched != NULL) {
129 | renderer_ready = 0;
130 | sceGxmShaderPatcherReleaseFragmentProgram(gxm_shader_patcher, fragment_program_patched);
131 | sceGxmShaderPatcherReleaseVertexProgram(gxm_shader_patcher, vertex_program_patched);
132 | sceGxmShaderPatcherForceUnregisterProgram(gxm_shader_patcher, fragment_id);
133 | sceGxmShaderPatcherForceUnregisterProgram(gxm_shader_patcher, vertex_id);
134 | }
135 | }
136 |
137 | void setupGenericAttribs() {
138 | if (gpu_buffer == NULL) {
139 |
140 | // Setting up default modelviewprojection matrix
141 | matrix4x4 projection, modelview;
142 | matrix4x4_identity(modelview);
143 | matrix4x4_init_orthographic(projection, 0, 960, 544, 0, -1, 1);
144 | matrix4x4_multiply(mvp, projection, modelview);
145 |
146 | // Allocating a generic buffer to use for our stuffs
147 | uint32_t gpu_buffer_size = 4 * 1024;
148 | SceUID memblock = sceKernelAllocMemBlock("reRescaler gpu buffer", SCE_KERNEL_MEMBLOCK_TYPE_USER_RW, gpu_buffer_size, NULL);
149 | sceKernelGetMemBlockBase(memblock, (void*)&gpu_buffer);
150 | sceGxmMapMemory(gpu_buffer, 4 * 1024, SCE_GXM_MEMORY_ATTRIB_RW);
151 | vertices = (vector3f*)gpu_buffer;
152 | indices = (uint16_t*)(&gpu_buffer[sizeof(vector3f) * 4]);
153 | texcoords = (vector2f*)(&gpu_buffer[(sizeof(vector3f) + sizeof(uint16_t)) * 4]);
154 | vertices_big = (vector4f*)(&gpu_buffer[(sizeof(vector3f) + sizeof(uint16_t) + sizeof(vector2f)) * 4]);
155 | orig_res = (vector2f*)(&gpu_buffer[(sizeof(vector3f) + sizeof(uint16_t) + sizeof(vector2f) + sizeof(vector4f)) * 4]);
156 | target_res = (vector2f*)(&gpu_buffer[(sizeof(vector3f) + sizeof(uint16_t) + sizeof(vector2f) + sizeof(vector4f)) * 4 + sizeof(vector2f)]);
157 |
158 | orig_res[0].x = src_w * 1.0f;
159 | orig_res[0].y = src_h * 1.0f;
160 | target_res[0].x = 960.0f;
161 | target_res[0].y = 544.0f;
162 |
163 | // Setting up default vertices
164 | vertices[0].x = 0.0f;
165 | vertices[0].y = 0.0f;
166 | vertices[0].z = 1.0f;
167 | vertices[1].x = 0.0f;
168 | vertices[1].y = 544.0f;
169 | vertices[1].z = 1.0f;
170 | vertices[2].x = 960.0f;
171 | vertices[2].y = 544.0f;
172 | vertices[2].z = 1.0f;
173 | vertices[3].x = 960.0f;
174 | vertices[3].y = 0.0f;
175 | vertices[3].z = 1.0f;
176 | vertices_big[0].x = 0.0f;
177 | vertices_big[0].y = 0.0f;
178 | vertices_big[0].z = 0.0f;
179 | vertices_big[0].w = 1.0f;
180 | vertices_big[1].x = 0.0f;
181 | vertices_big[1].y = 544.0f;
182 | vertices_big[1].z = 0.0f;
183 | vertices_big[1].w = 1.0f;
184 | vertices_big[2].x = 960.0f;
185 | vertices_big[2].y = 544.0f;
186 | vertices_big[2].z = 0.0f;
187 | vertices_big[2].w = 1.0f;
188 | vertices_big[3].x = 960.0f;
189 | vertices_big[3].y = 0.0f;
190 | vertices_big[3].z = 0.0f;
191 | vertices_big[3].w = 1.0f;
192 |
193 | // Setting up default indices
194 | int i;
195 | for (i=0;i<4;i++){
196 | indices[i] = i;
197 | }
198 |
199 | // Setting up default texcoords
200 | float w = (src_w * 1.0f) / (src_s * 1.0f);
201 | texcoords[0].x = 0.0f;
202 | texcoords[0].y = 0.0f;
203 | texcoords[1].x = 0.0f;
204 | texcoords[1].y = 1.0f;
205 | texcoords[2].x = w;
206 | texcoords[2].y = 1.0f;
207 | texcoords[3].x = w;
208 | texcoords[3].y = 0.0f;
209 | }
210 | renderer_ready = 1;
211 | }
212 |
213 | void setupStandardShaders() {
214 |
215 | // Registering our shaders
216 | sceGxmShaderPatcherRegisterProgram(
217 | gxm_shader_patcher,
218 | gxm_program_texture2d_v,
219 | &vertex_id);
220 | sceGxmShaderPatcherRegisterProgram(
221 | gxm_shader_patcher,
222 | gxm_program_texture2d_f,
223 | &fragment_id);
224 |
225 | // Getting references to our vertex streams/uniforms
226 | position = sceGxmProgramFindParameterByName(gxm_program_texture2d_v, "position");
227 | texcoord = sceGxmProgramFindParameterByName(gxm_program_texture2d_v, "texcoord");
228 | wvp = sceGxmProgramFindParameterByName(gxm_program_texture2d_v, "wvp");
229 |
230 | // Setting up our vertex stream attributes
231 | SceGxmVertexAttribute vertex_attribute[2];
232 | SceGxmVertexStream vertex_stream[2];
233 | vertex_attribute[0].streamIndex = 0;
234 | vertex_attribute[0].offset = 0;
235 | vertex_attribute[0].format = SCE_GXM_ATTRIBUTE_FORMAT_F32;
236 | vertex_attribute[0].componentCount = 3;
237 | vertex_attribute[0].regIndex = sceGxmProgramParameterGetResourceIndex(position);
238 | vertex_attribute[1].streamIndex = 1;
239 | vertex_attribute[1].offset = 0;
240 | vertex_attribute[1].format = SCE_GXM_ATTRIBUTE_FORMAT_F32;
241 | vertex_attribute[1].componentCount = 2;
242 | vertex_attribute[1].regIndex = sceGxmProgramParameterGetResourceIndex(texcoord);
243 | vertex_stream[0].stride = sizeof(vector3f);
244 | vertex_stream[0].indexSource = SCE_GXM_INDEX_SOURCE_INDEX_16BIT;
245 | vertex_stream[1].stride = sizeof(vector2f);
246 | vertex_stream[1].indexSource = SCE_GXM_INDEX_SOURCE_INDEX_16BIT;
247 |
248 | // Creating our shader programs
249 | sceGxmShaderPatcherCreateVertexProgram(gxm_shader_patcher,
250 | vertex_id, vertex_attribute,
251 | 2, vertex_stream, 2, &vertex_program_patched);
252 |
253 | sceGxmShaderPatcherCreateFragmentProgram(gxm_shader_patcher,
254 | fragment_id, SCE_GXM_OUTPUT_REGISTER_FORMAT_UCHAR4,
255 | SCE_GXM_MULTISAMPLE_NONE, NULL, gxm_program_texture2d_v,
256 | &fragment_program_patched);
257 |
258 | setupGenericAttribs();
259 | }
260 |
261 | void setupComplexShader(int i) {
262 |
263 | // Registering our shaders
264 | sceGxmShaderPatcherRegisterProgram(
265 | gxm_shader_patcher,
266 | complex_vshaders[i],
267 | &vertex_id);
268 | sceGxmShaderPatcherRegisterProgram(
269 | gxm_shader_patcher,
270 | complex_fshaders[i],
271 | &fragment_id);
272 |
273 | // Getting references to our vertex streams/uniforms
274 | position = sceGxmProgramFindParameterByName(complex_vshaders[i], "aPosition");
275 | texcoord = sceGxmProgramFindParameterByName(complex_vshaders[i], "aTexcoord");
276 | wvp = sceGxmProgramFindParameterByName(complex_vshaders[i], "wvp");
277 |
278 | // Setting up our vertex stream attributes
279 | SceGxmVertexAttribute vertex_attribute[2];
280 | SceGxmVertexStream vertex_stream[2];
281 | vertex_attribute[0].streamIndex = 0;
282 | vertex_attribute[0].offset = 0;
283 | vertex_attribute[0].format = SCE_GXM_ATTRIBUTE_FORMAT_F32;
284 | vertex_attribute[0].componentCount = 4;
285 | vertex_attribute[0].regIndex = sceGxmProgramParameterGetResourceIndex(position);
286 | vertex_attribute[1].streamIndex = 1;
287 | vertex_attribute[1].offset = 0;
288 | vertex_attribute[1].format = SCE_GXM_ATTRIBUTE_FORMAT_F32;
289 | vertex_attribute[1].componentCount = 2;
290 | vertex_attribute[1].regIndex = sceGxmProgramParameterGetResourceIndex(texcoord);
291 | vertex_stream[0].stride = sizeof(vector4f);
292 | vertex_stream[0].indexSource = SCE_GXM_INDEX_SOURCE_INDEX_16BIT;
293 | vertex_stream[1].stride = sizeof(vector2f);
294 | vertex_stream[1].indexSource = SCE_GXM_INDEX_SOURCE_INDEX_16BIT;
295 |
296 | shader_params[0] = sceGxmProgramFindParameterByName(complex_vshaders[i], "texture_size");
297 | shader_params[1] = sceGxmProgramFindParameterByName(complex_vshaders[i], "output_size");
298 | shader_params[2] = sceGxmProgramFindParameterByName(complex_fshaders[i], "texture_size");
299 | shader_params[3] = sceGxmProgramFindParameterByName(complex_fshaders[i], "output_size");
300 |
301 | // Creating our shader programs
302 | sceGxmShaderPatcherCreateVertexProgram(gxm_shader_patcher,
303 | vertex_id, vertex_attribute,
304 | 2, vertex_stream, 2, &vertex_program_patched);
305 |
306 | sceGxmShaderPatcherCreateFragmentProgram(gxm_shader_patcher,
307 | fragment_id, SCE_GXM_OUTPUT_REGISTER_FORMAT_UCHAR4,
308 | SCE_GXM_MULTISAMPLE_NONE, NULL, complex_vshaders[i],
309 | &fragment_program_patched);
310 |
311 | setupGenericAttribs();
312 | }
313 |
314 | // Simplified generic hooking function
315 | void hookFunction(uint32_t nid, const void *func){
316 | hooks[current_hook] = taiHookFunctionImport(&refs[current_hook],TAI_MAIN_MODULE,TAI_ANY_LIBRARY,nid,func);
317 | current_hook++;
318 | }
319 |
320 | int sceGxmShaderPatcherCreate_patched(const SceGxmShaderPatcherParams *params, SceGxmShaderPatcher **shaderPatcher){
321 | int res = TAI_CONTINUE(int, refs[3], params, shaderPatcher);
322 |
323 | // Grabbing a reference to used shader patcher
324 | gxm_shader_patcher = *shaderPatcher;
325 |
326 | return res;
327 | }
328 |
329 | int sceGxmCreateContext_patched(const SceGxmContextParams *params, SceGxmContext **context) {
330 | int res = TAI_CONTINUE(int, refs[2], params, context);
331 |
332 | // Grabbing a reference to the created sceGxm context
333 | gxm_context = *context;
334 |
335 | return res;
336 | }
337 |
338 | int sceGxmDisplayQueueAddEntry_patched(SceGxmSyncObject *oldBuffer, SceGxmSyncObject *newBuffer, const void *callbackData) {
339 |
340 | if (fb != NULL) {
341 |
342 | SceCtrlData pad;
343 | sceCtrlPeekBufferPositive(0, &pad, 1);
344 | if ((!lock) && (pad.buttons & SCE_CTRL_LTRIGGER)) {
345 | if (tick == 0) tick = sceKernelGetProcessTimeWide();
346 | else if (sceKernelGetProcessTimeWide() - tick > 4000000) {
347 | tick = 0;
348 | mode = (mode + 1) % MODES_NUM;
349 | lock_screen = MODE_CHANGE;
350 | lock_tick = sceKernelGetProcessTimeWide();
351 | saveConfig();
352 | if (mode > RESCALER_OFF && gxm_render_target != NULL) {
353 |
354 | // Setting up required shaders
355 | releaseOldShader();
356 | if (mode <= ORIGINAL) setupStandardShaders();
357 | else setupComplexShader(mode - 2);
358 |
359 | }
360 | }
361 | } else tick = 0;
362 | if ((!lock) && (pad.buttons & SCE_CTRL_RTRIGGER)) {
363 | if (tick2 == 0) tick2 = sceKernelGetProcessTimeWide();
364 | else if (sceKernelGetProcessTimeWide() - tick2 > 4000000) {
365 | tick2 = 0;
366 | lock_screen = MODE_CHANGE;
367 | lock_tick = sceKernelGetProcessTimeWide();
368 | bilinear = (bilinear + 1) % 2;
369 | saveConfig();
370 | }
371 | } else tick2 = 0;
372 | if (pad.buttons & SCE_CTRL_START) {
373 | if (tick3 == 0) tick3 = sceKernelGetProcessTimeWide();
374 | else if (sceKernelGetProcessTimeWide() - tick3 > 2000000) {
375 | lock = (lock + 1) % 2;
376 | lock_screen = LOCK_CHANGE;
377 | lock_tick = sceKernelGetProcessTimeWide();
378 | tick3 = 0;
379 | saveConfig();
380 | }
381 | } else tick3 = 0;
382 |
383 | updateFramebuf(fb, 960, 544, 960);
384 | switch (mode){
385 |
386 | // Performing a data transfer with sceGxmTransfer if a new framebuffer got allocated
387 | case RESCALER_OFF:
388 | sceGxmTransferCopy(
389 | src_w, src_h,
390 | 0x00000000, 0x00000000, SCE_GXM_TRANSFER_COLORKEY_NONE,
391 | SCE_GXM_TRANSFER_FORMAT_U8U8U8U8_ABGR,
392 | SCE_GXM_TRANSFER_LINEAR,
393 | src_fb, 0, 0, src_p,
394 | SCE_GXM_TRANSFER_FORMAT_U8U8U8U8_ABGR,
395 | SCE_GXM_TRANSFER_LINEAR,
396 | fb, dst_x, dst_y, 960 * sizeof(uint32_t),
397 | NULL, SCE_GXM_TRANSFER_FRAGMENT_SYNC, NULL);
398 | break;
399 |
400 | // Performing a rescale with standard sceGxm without a display queue
401 | case ORIGINAL:
402 | if (!renderer_ready) break;
403 | if (lock_screen) break;
404 | sceGxmTextureInitLinear(&gxm_texture, src_fb, SCE_GXM_TEXTURE_FORMAT_U8U8U8U8_ABGR, src_s, src_h, 0);
405 | sceGxmTextureSetMagFilter(&gxm_texture, bilinear ? SCE_GXM_TEXTURE_FILTER_LINEAR : SCE_GXM_TEXTURE_FILTER_POINT);
406 | sceGxmTextureSetMinFilter(&gxm_texture, bilinear ? SCE_GXM_TEXTURE_FILTER_LINEAR : SCE_GXM_TEXTURE_FILTER_POINT);
407 | sceGxmSetFrontFragmentProgramEnable(gxm_context, SCE_GXM_FRAGMENT_PROGRAM_ENABLED);
408 | sceGxmSetBackFragmentProgramEnable(gxm_context, SCE_GXM_FRAGMENT_PROGRAM_ENABLED);
409 | sceGxmSetFrontPolygonMode(gxm_context, SCE_GXM_POLYGON_MODE_TRIANGLE_FILL);
410 | sceGxmSetBackPolygonMode(gxm_context, SCE_GXM_POLYGON_MODE_TRIANGLE_FILL);
411 | sceGxmSetTwoSidedEnable(gxm_context, SCE_GXM_TWO_SIDED_DISABLED);
412 | sceGxmSetCullMode(gxm_context, SCE_GXM_CULL_NONE);
413 | sceGxmSetFrontVisibilityTestEnable(gxm_context,SCE_GXM_VISIBILITY_TEST_DISABLED);
414 | sceGxmSetBackVisibilityTestEnable(gxm_context,SCE_GXM_VISIBILITY_TEST_DISABLED);
415 | sceGxmBeginScene(gxm_context, 0, gxm_render_target,
416 | NULL, NULL, NULL, &gxm_color_surface, NULL);
417 | sceGxmSetFrontStencilFunc(gxm_context,SCE_GXM_STENCIL_FUNC_ALWAYS,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,0,0);
418 | sceGxmSetBackStencilFunc(gxm_context,SCE_GXM_STENCIL_FUNC_ALWAYS,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,0,0);
419 | sceGxmSetFrontDepthFunc(gxm_context, SCE_GXM_DEPTH_FUNC_ALWAYS);
420 | sceGxmSetBackDepthFunc(gxm_context, SCE_GXM_DEPTH_FUNC_ALWAYS);
421 | sceGxmSetVertexProgram(gxm_context, vertex_program_patched);
422 | sceGxmSetFragmentProgram(gxm_context, fragment_program_patched);
423 | sceGxmReserveVertexDefaultUniformBuffer(gxm_context, &vertex_buffer);
424 | sceGxmSetUniformDataF(vertex_buffer, wvp, 0, 16, (const float*)mvp);
425 | sceGxmSetFragmentTexture(gxm_context, 0, &gxm_texture);
426 | sceGxmSetVertexStream(gxm_context, 0, vertices);
427 | sceGxmSetVertexStream(gxm_context, 1, texcoords);
428 | sceGxmDraw(gxm_context, SCE_GXM_PRIMITIVE_TRIANGLE_FAN, SCE_GXM_INDEX_FORMAT_U16, indices, 4);
429 | sceGxmEndScene(gxm_context, NULL, NULL);
430 | break;
431 |
432 | // Performing a rescale with standard sceGxm without a display queue and custom shaders
433 | case SHARP_BILINEAR:
434 | case SHARP_BILINEAR_SIMPLE:
435 | case LCD_3X:
436 | if (!renderer_ready) break;
437 | if (lock_screen) break;
438 | sceGxmTextureInitLinear(&gxm_texture, src_fb, SCE_GXM_TEXTURE_FORMAT_U8U8U8U8_ABGR, src_s, src_h, 0);
439 | sceGxmTextureSetMagFilter(&gxm_texture, bilinear ? SCE_GXM_TEXTURE_FILTER_LINEAR : SCE_GXM_TEXTURE_FILTER_POINT);
440 | sceGxmTextureSetMinFilter(&gxm_texture, bilinear ? SCE_GXM_TEXTURE_FILTER_LINEAR : SCE_GXM_TEXTURE_FILTER_POINT);
441 | sceGxmSetFrontFragmentProgramEnable(gxm_context, SCE_GXM_FRAGMENT_PROGRAM_ENABLED);
442 | sceGxmSetBackFragmentProgramEnable(gxm_context, SCE_GXM_FRAGMENT_PROGRAM_ENABLED);
443 | sceGxmSetFrontPolygonMode(gxm_context, SCE_GXM_POLYGON_MODE_TRIANGLE_FILL);
444 | sceGxmSetBackPolygonMode(gxm_context, SCE_GXM_POLYGON_MODE_TRIANGLE_FILL);
445 | sceGxmSetTwoSidedEnable(gxm_context, SCE_GXM_TWO_SIDED_DISABLED);
446 | sceGxmSetCullMode(gxm_context, SCE_GXM_CULL_NONE);
447 | sceGxmSetFrontVisibilityTestEnable(gxm_context,SCE_GXM_VISIBILITY_TEST_DISABLED);
448 | sceGxmSetBackVisibilityTestEnable(gxm_context,SCE_GXM_VISIBILITY_TEST_DISABLED);
449 | sceGxmBeginScene(gxm_context, 0, gxm_render_target,
450 | NULL, NULL, NULL, &gxm_color_surface, NULL);
451 | sceGxmSetFrontStencilFunc(gxm_context,SCE_GXM_STENCIL_FUNC_ALWAYS,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,0,0);
452 | sceGxmSetBackStencilFunc(gxm_context,SCE_GXM_STENCIL_FUNC_ALWAYS,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,SCE_GXM_STENCIL_OP_KEEP,0,0);
453 | sceGxmSetFrontDepthFunc(gxm_context, SCE_GXM_DEPTH_FUNC_ALWAYS);
454 | sceGxmSetBackDepthFunc(gxm_context, SCE_GXM_DEPTH_FUNC_ALWAYS);
455 | sceGxmSetVertexProgram(gxm_context, vertex_program_patched);
456 | sceGxmSetFragmentProgram(gxm_context, fragment_program_patched);
457 | sceGxmReserveVertexDefaultUniformBuffer(gxm_context, &vertex_buffer);
458 | sceGxmReserveFragmentDefaultUniformBuffer(gxm_context, &fragment_buffer);
459 | sceGxmSetUniformDataF(vertex_buffer, wvp, 0, 16, (const float*)mvp);
460 | if (shader_params[0]) sceGxmSetUniformDataF(vertex_buffer, shader_params[0], 0, 2, (const float*)orig_res);
461 | if (shader_params[1]) sceGxmSetUniformDataF(vertex_buffer, shader_params[1], 0, 2, (const float*)target_res);
462 | if (shader_params[2]) sceGxmSetUniformDataF(fragment_buffer, shader_params[2], 0, 2, (const float*)orig_res);
463 | if (shader_params[3]) sceGxmSetUniformDataF(fragment_buffer, shader_params[3], 0, 2, (const float*)target_res);
464 | sceGxmSetFragmentTexture(gxm_context, 0, &gxm_texture);
465 | sceGxmSetVertexStream(gxm_context, 0, vertices_big);
466 | sceGxmSetVertexStream(gxm_context, 1, texcoords);
467 | sceGxmDraw(gxm_context, SCE_GXM_PRIMITIVE_TRIANGLE_FAN, SCE_GXM_INDEX_FORMAT_U16, indices, 4);
468 | sceGxmEndScene(gxm_context, NULL, NULL);
469 | break;
470 | default:
471 | break;
472 | }
473 | if (lock_screen) {
474 | switch (lock_screen) {
475 | case MODE_CHANGE:
476 | drawStringF(5, 20, "reRescaler: %ix%i -> 960x544 (%s - %s)", src_w, src_h, str_mode[mode], bilinear ? "Bilinear ON" : "Bilinear OFF");
477 | if (sceKernelGetProcessTimeWide() - lock_tick > 1000000) lock_screen = UNLOCKED;
478 | break;
479 | case LOCK_CHANGE:
480 | drawStringF(5, 20, "reRescaler: Mode Switching %s!", lock ? "locked" : "unlocked");
481 | if (sceKernelGetProcessTimeWide() - lock_tick > 1000000) lock_screen = UNLOCKED;
482 | break;
483 | case STARTUP_INFO:
484 | drawStringF(5, 20, "reRescaler: %ix%i -> 960x544 (%s - %s)", src_w, src_h, str_mode[mode], bilinear ? "Bilinear ON" : "Bilinear OFF");
485 | if (lock_tick == 0) lock_tick = sceKernelGetProcessTimeWide();
486 | if (sceKernelGetProcessTimeWide() - lock_tick > 2500000) lock_screen = UNLOCKED;
487 | break;
488 | default:
489 | break;
490 | }
491 |
492 | }
493 | }
494 |
495 | return TAI_CONTINUE(int, refs[1], oldBuffer, newBuffer, callbackData);
496 | }
497 |
498 | int sceDisplaySetFrameBuf_patched(const SceDisplayFrameBuf *pParam, int sync) {
499 |
500 | // For 960x544 games, the plugin is useless
501 | if (pParam->width != 960) {
502 |
503 | // Discarding constantness of pParam
504 | SceDisplayFrameBuf *p = (SceDisplayFrameBuf*)pParam;
505 |
506 | // Setup code
507 | if (fb == NULL) {
508 |
509 | // Allocating our 960x544 framebuffer
510 | uint32_t fb_size = ALIGN(960 * 544 * 4, 0x40000);
511 | SceUID memblock = sceKernelAllocMemBlock("reRescaler fb", SCE_KERNEL_MEMBLOCK_TYPE_USER_CDRAM_RW, fb_size, NULL);
512 | sceKernelGetMemBlockBase(memblock, &fb);
513 |
514 | // Not enough CDRAM memory, checking if game uses an heap implementation
515 | if (fb == NULL){
516 | if (cdram_heap == NULL) return TAI_CONTINUE(int, refs[0], pParam, sync);
517 | else fb = &cdram_heap[cdram_size - fb_size];
518 | }
519 |
520 | // Mapping framebuffer into sceGxm and saving constant values for later usage
521 | sceGxmMapMemory(fb, fb_size, SCE_GXM_MEMORY_ATTRIB_RW);
522 | src_w = p->width;
523 | src_h = p->height;
524 | dst_x = (960 - src_w) / 2;
525 | dst_y = (544 - src_h) / 2;
526 | src_p = p->pitch * sizeof(uint32_t);
527 | src_s = p->pitch;
528 |
529 | // Creating a render target for our patched framebuffer
530 | SceGxmRenderTargetParams render_target_params;
531 | memset(&render_target_params, 0, sizeof(SceGxmRenderTargetParams));
532 | render_target_params.flags = 0;
533 | render_target_params.width = 960;
534 | render_target_params.height = 544;
535 | render_target_params.scenesPerFrame = 1;
536 | render_target_params.multisampleMode = SCE_GXM_MULTISAMPLE_NONE;
537 | render_target_params.multisampleLocations = 0;
538 | render_target_params.driverMemBlock = -1;
539 | sceGxmCreateRenderTarget(&render_target_params, &gxm_render_target);
540 |
541 | // Initializing a color surface for our framebuffer
542 | sceGxmColorSurfaceInit(&gxm_color_surface,
543 | SCE_GXM_COLOR_FORMAT_A8B8G8R8,
544 | SCE_GXM_COLOR_SURFACE_LINEAR,
545 | SCE_GXM_COLOR_SURFACE_SCALE_NONE,
546 | SCE_GXM_OUTPUT_REGISTER_SIZE_32BIT,
547 | 960, 544, 960, fb);
548 |
549 | if (mode > RESCALER_OFF) {
550 |
551 | // Setting up required shaders
552 | if (mode <= ORIGINAL) setupStandardShaders();
553 | else setupComplexShader(mode - 2);
554 |
555 | }
556 |
557 | }
558 |
559 | // Patching pParam and grabbing current framebuffer data address
560 | src_fb = p->base;
561 | p->pitch = p->width = 960;
562 | p->height = 544;
563 | p->base = fb;
564 | }
565 |
566 | return TAI_CONTINUE(int, refs[0], pParam, sync);
567 | }
568 |
569 | int sceKernelAllocMemBlock_patched(const char *name, SceKernelMemBlockType type, int size, void *optp) {
570 | int res = TAI_CONTINUE(SceUID, refs[4], name, type, size, optp);
571 |
572 | // The game seems to use an heap implementation, saving CDRAM heap info
573 | if ((type == SCE_KERNEL_MEMBLOCK_TYPE_USER_CDRAM_RW) && (size > HEAP_SIZE)){
574 | sceKernelGetMemBlockBase(res, &cdram_heap);
575 | cdram_size = size;
576 | }
577 |
578 | return res;
579 | }
580 |
581 | void _start() __attribute__ ((weak, alias ("module_start")));
582 | int module_start(SceSize argc, const void *args) {
583 |
584 | // Getting titleid
585 | char titleid[16];
586 | sceAppMgrAppParamGetString(0, 12, titleid , 256);
587 |
588 | // Blacklisted games
589 | if (strcmp(titleid, "PCSE00051") == 0) { // Urban Trial Freestyle (GPU Crash)
590 | return SCE_KERNEL_START_SUCCESS;
591 | }
592 |
593 | // Reading config file if existing
594 | sceIoMkdir("ux0:data/reRescaler", 0777);
595 | sprintf(cfg_fname, "ux0:data/reRescaler/%s.txt", titleid);
596 | SceUID fd = sceIoOpen(cfg_fname, SCE_O_RDONLY, 0777);
597 | if (fd >= 0) {
598 | char cfg[32];
599 | sceIoRead(fd, cfg, 32);
600 | sscanf(cfg, "%i;%i;%i", &mode, &bilinear, &lock);
601 | sceIoClose(fd);
602 | }
603 |
604 | // Hooking functions
605 | hookFunction(0x7A410B64, sceDisplaySetFrameBuf_patched);
606 | hookFunction(0xEC5C26B5, sceGxmDisplayQueueAddEntry_patched);
607 | hookFunction(0xE84CE5B4, sceGxmCreateContext_patched);
608 | hookFunction(0x05032658, sceGxmShaderPatcherCreate_patched);
609 | hookFunction(0xB9D5EBDE, sceKernelAllocMemBlock_patched);
610 |
611 | return SCE_KERNEL_START_SUCCESS;
612 | }
613 |
614 | int module_stop(SceSize argc, const void *args) {
615 |
616 | // Freeing hooks
617 | while (current_hook-- > 0){
618 | taiHookRelease(hooks[current_hook], refs[current_hook]);
619 | }
620 |
621 | return SCE_KERNEL_STOP_SUCCESS;
622 | }
--------------------------------------------------------------------------------
/math_utils.c:
--------------------------------------------------------------------------------
1 | #include
2 | #include
3 | #include "math_utils.h"
4 |
5 | /*
6 | * Note: matrices are row-major.
7 | */
8 |
9 | static inline float sgn(float a)
10 | {
11 | if (a > 0.0f)
12 | return 1.0f;
13 | if (a < 0.0f)
14 | return -1.0f;
15 | return 0.0f;
16 | }
17 |
18 | void vector3f_init(vector3f *v, float x, float y, float z)
19 | {
20 | v->x = x;
21 | v->y = y;
22 | v->z = z;
23 | }
24 |
25 | void vector3f_copy(vector3f *dst, const vector3f *src)
26 | {
27 | dst->x = src->x;
28 | dst->y = src->y;
29 | dst->z = src->z;
30 | }
31 |
32 | void vector3f_add(vector3f *v1, const vector3f *v2)
33 | {
34 | v1->x += v2->x;
35 | v1->y += v2->y;
36 | v1->z += v2->z;
37 | }
38 |
39 | void vector3f_scalar_mult(vector3f *v, float a)
40 | {
41 | v->x *= a;
42 | v->y *= a;
43 | v->z *= a;
44 | }
45 |
46 | void vector3f_add_mult(vector3f *v, const vector3f *u, float a)
47 | {
48 | v->x += u->x * a;
49 | v->y += u->y * a;
50 | v->z += u->z * a;
51 | }
52 |
53 | void vector3f_opposite(vector3f *v1, const vector3f *v0)
54 | {
55 | v1->x = -v0->x;
56 | v1->y = -v0->y;
57 | v1->z = -v0->z;
58 | }
59 |
60 | float vector3f_dot_product(const vector3f *v1, const vector3f *v2)
61 | {
62 | return v1->x * v2->x + v1->y * v2->y + v1->z * v2->z;
63 | }
64 |
65 | void vector3f_cross_product(vector3f *w, const vector3f *u, const vector3f *v)
66 | {
67 | w->x = u->y * v->z - u->z * v->y;
68 | w->y = u->z * v->x - u->x * v->z;
69 | w->z = u->x * v->y - u->y * v->x;
70 | }
71 |
72 | void vector3f_matrix4x4_mult(vector3f *u, const matrix4x4 m, const vector3f *v, float w)
73 | {
74 | u->x = m[0][0] * v->x + m[0][1] * v->y + m[0][2] * v->z + m[0][3] * w;
75 | u->y = m[1][0] * v->x + m[1][1] * v->y + m[1][2] * v->z + m[1][3] * w;
76 | u->z = m[2][0] * v->x + m[2][1] * v->y + m[2][2] * v->z + m[2][3] * w;
77 | }
78 |
79 | void vector4f_init(vector4f *v, float x, float y, float z, float w)
80 | {
81 | v->x = x;
82 | v->y = y;
83 | v->z = z;
84 | v->w = w;
85 | }
86 |
87 | void vector4f_scalar_mult_dest(vector4f *u, const vector4f *v, float a)
88 | {
89 | u->x = v->x * a;
90 | u->y = v->y * a;
91 | u->z = v->z * a;
92 | u->w = v->w * a;
93 | }
94 |
95 | float vector4f_dot_product(const vector4f *v1, const vector4f *v2)
96 | {
97 | return v1->x * v2->x + v1->y * v2->y + v1->z * v2->z + v1->w * v2->w;
98 | }
99 |
100 | void vector4f_matrix4x4_mult(vector4f *u, const matrix4x4 m, const vector4f *v)
101 | {
102 | u->x = m[0][0] * v->x + m[0][1] * v->y + m[0][2] * v->z + m[0][3] * v->w;
103 | u->y = m[1][0] * v->x + m[1][1] * v->y + m[1][2] * v->z + m[1][3] * v->w;
104 | u->z = m[2][0] * v->x + m[2][1] * v->y + m[2][2] * v->z + m[2][3] * v->w;
105 | u->w = m[3][0] * v->x + m[3][1] * v->y + m[3][2] * v->z + m[3][3] * v->w;
106 | }
107 |
108 | void matrix3x3_identity(matrix3x3 m)
109 | {
110 | m[0][1] = m[0][2] = 0.0f;
111 | m[1][0] = m[1][2] = 0.0f;
112 | m[2][0] = m[2][1] = 0.0f;
113 | m[0][0] = m[1][1] = m[2][2] = 1.0f;
114 | }
115 |
116 | void matrix3x3_from_matrix4x4(matrix3x3 dst, const matrix4x4 src)
117 | {
118 | int i, j;
119 |
120 | for (i = 0; i < 3; i++) {
121 | for (j = 0; j < 3; j++)
122 | dst[i][j] = src[i][j];
123 | }
124 | }
125 |
126 | void matrix4x4_identity(matrix4x4 m)
127 | {
128 | m[0][1] = m[0][2] = m[0][3] = 0.0f;
129 | m[1][0] = m[1][2] = m[1][3] = 0.0f;
130 | m[2][0] = m[2][1] = m[2][3] = 0.0f;
131 | m[3][0] = m[3][1] = m[3][2] = 0.0f;
132 | m[0][0] = m[1][1] = m[2][2] = m[3][3] = 1.0f;
133 | }
134 |
135 | void matrix4x4_copy(matrix4x4 dst, const matrix4x4 src)
136 | {
137 | memcpy(dst, src, sizeof(matrix4x4));
138 | }
139 |
140 | void matrix4x4_multiply(matrix4x4 dst, const matrix4x4 src1, const matrix4x4 src2)
141 | {
142 | int i, j, k;
143 |
144 | for (i = 0; i < 4; i++) {
145 | for (j = 0; j < 4; j++) {
146 | dst[i][j] = 0.0f;
147 | for (k = 0; k < 4; k++)
148 | dst[i][j] += src1[i][k] * src2[k][j];
149 | }
150 | }
151 | }
152 |
153 | void matrix4x4_init_translation(matrix4x4 m, float x, float y, float z)
154 | {
155 | matrix4x4_identity(m);
156 |
157 | m[0][3] = x;
158 | m[1][3] = y;
159 | m[2][3] = z;
160 | }
161 |
162 | void matrix4x4_init_translation_vector3f(matrix4x4 m, const vector3f *v)
163 | {
164 | matrix4x4_identity(m);
165 |
166 | m[0][3] = v->x;
167 | m[1][3] = v->y;
168 | m[2][3] = v->z;
169 | }
170 |
171 | void matrix4x4_translate(matrix4x4 m, float x, float y, float z)
172 | {
173 | matrix4x4 m1, m2;
174 |
175 | matrix4x4_init_translation(m1, x, y, z);
176 | matrix4x4_multiply(m2, m, m1);
177 | matrix4x4_copy(m, m2);
178 | }
179 |
180 | void matrix4x4_init_scaling(matrix4x4 m, float scale_x, float scale_y, float scale_z)
181 | {
182 | matrix4x4_identity(m);
183 |
184 | m[0][0] = scale_x;
185 | m[1][1] = scale_y;
186 | m[2][2] = scale_z;
187 | }
188 |
189 | void matrix4x4_scale(matrix4x4 m, float scale_x, float scale_y, float scale_z)
190 | {
191 | matrix4x4 m1, m2;
192 |
193 | matrix4x4_init_scaling(m1, scale_x, scale_y, scale_z);
194 | matrix4x4_multiply(m2, m, m1);
195 | matrix4x4_copy(m, m2);
196 | }
197 |
198 | void matrix4x4_reflect_origin(matrix4x4 m)
199 | {
200 | matrix4x4_scale(m, -1.0f, -1.0f, -1.0f);
201 | }
202 |
203 | void matrix4x4_transpose(matrix4x4 out, const matrix4x4 m)
204 | {
205 | int i, j;
206 |
207 | for (i = 0; i < 4; i++) {
208 | for (j = 0; j < 4; j++)
209 | out[i][j] = m[j][i];
210 | }
211 | }
212 |
213 | int matrix4x4_invert(matrix4x4 out, const matrix4x4 m)
214 | {
215 | int i, j;
216 | float det;
217 | matrix4x4 inv;
218 |
219 | inv[0][0] = m[1][1] * m[2][2] * m[3][3] -
220 | m[1][1] * m[3][2] * m[2][3] -
221 | m[1][2] * m[2][1] * m[3][3] +
222 | m[1][2] * m[3][1] * m[2][3] +
223 | m[1][3] * m[2][1] * m[3][2] -
224 | m[1][3] * m[3][1] * m[2][2];
225 |
226 | inv[0][1] = -m[0][1] * m[2][2] * m[3][3] +
227 | m[0][1] * m[3][2] * m[2][3] +
228 | m[0][2] * m[2][1] * m[3][3] -
229 | m[0][2] * m[3][1] * m[2][3] -
230 | m[0][3] * m[2][1] * m[3][2] +
231 | m[0][3] * m[3][1] * m[2][2];
232 |
233 | inv[0][2] = m[0][1] * m[1][2] * m[3][3] -
234 | m[0][1] * m[3][2] * m[1][3] -
235 | m[0][2] * m[1][1] * m[3][3] +
236 | m[0][2] * m[3][1] * m[1][3] +
237 | m[0][3] * m[1][1] * m[3][2] -
238 | m[0][3] * m[3][1] * m[1][2];
239 |
240 | inv[0][3] = -m[0][1] * m[1][2] * m[2][3] +
241 | m[0][1] * m[2][2] * m[1][3] +
242 | m[0][2] * m[1][1] * m[2][3] -
243 | m[0][2] * m[2][1] * m[1][3] -
244 | m[0][3] * m[1][1] * m[2][2] +
245 | m[0][3] * m[2][1] * m[1][2];
246 |
247 | inv[1][0] = -m[1][0] * m[2][2] * m[3][3] +
248 | m[1][0] * m[3][2] * m[2][3] +
249 | m[1][2] * m[2][0] * m[3][3] -
250 | m[1][2] * m[3][0] * m[2][3] -
251 | m[1][3] * m[2][0] * m[3][2] +
252 | m[1][3] * m[3][0] * m[2][2];
253 |
254 | inv[1][1] = m[0][0] * m[2][2] * m[3][3] -
255 | m[0][0] * m[3][2] * m[2][3] -
256 | m[0][2] * m[2][0] * m[3][3] +
257 | m[0][2] * m[3][0] * m[2][3] +
258 | m[0][3] * m[2][0] * m[3][2] -
259 | m[0][3] * m[3][0] * m[2][2];
260 |
261 | inv[1][2] = -m[0][0] * m[1][2] * m[3][3] +
262 | m[0][0] * m[3][2] * m[1][3] +
263 | m[0][2] * m[1][0] * m[3][3] -
264 | m[0][2] * m[3][0] * m[1][3] -
265 | m[0][3] * m[1][0] * m[3][2] +
266 | m[0][3] * m[3][0] * m[1][2];
267 |
268 | inv[1][3] = m[0][0] * m[1][2] * m[2][3] -
269 | m[0][0] * m[2][2] * m[1][3] -
270 | m[0][2] * m[1][0] * m[2][3] +
271 | m[0][2] * m[2][0] * m[1][3] +
272 | m[0][3] * m[1][0] * m[2][2] -
273 | m[0][3] * m[2][0] * m[1][2];
274 |
275 | inv[2][0] = m[1][0] * m[2][1] * m[3][3] -
276 | m[1][0] * m[3][1] * m[2][3] -
277 | m[1][1] * m[2][0] * m[3][3] +
278 | m[1][1] * m[3][0] * m[2][3] +
279 | m[1][3] * m[2][0] * m[3][1] -
280 | m[1][3] * m[3][0] * m[2][1];
281 |
282 | inv[2][1] = -m[0][0] * m[2][1] * m[3][3] +
283 | m[0][0] * m[3][1] * m[2][3] +
284 | m[0][1] * m[2][0] * m[3][3] -
285 | m[0][1] * m[3][0] * m[2][3] -
286 | m[0][3] * m[2][0] * m[3][1] +
287 | m[0][3] * m[3][0] * m[2][1];
288 |
289 | inv[2][2] = m[0][0] * m[1][1] * m[3][3] -
290 | m[0][0] * m[3][1] * m[1][3] -
291 | m[0][1] * m[1][0] * m[3][3] +
292 | m[0][1] * m[3][0] * m[1][3] +
293 | m[0][3] * m[1][0] * m[3][1] -
294 | m[0][3] * m[3][0] * m[1][1];
295 |
296 | inv[2][3] = -m[0][0] * m[1][1] * m[2][3] +
297 | m[0][0] * m[2][1] * m[1][3] +
298 | m[0][1] * m[1][0] * m[2][3] -
299 | m[0][1] * m[2][0] * m[1][3] -
300 | m[0][3] * m[1][0] * m[2][1] +
301 | m[0][3] * m[2][0] * m[1][1];
302 |
303 | inv[3][0] = -m[1][0] * m[2][1] * m[3][2] +
304 | m[1][0] * m[3][1] * m[2][2] +
305 | m[1][1] * m[2][0] * m[3][2] -
306 | m[1][1] * m[3][0] * m[2][2] -
307 | m[1][2] * m[2][0] * m[3][1] +
308 | m[1][2] * m[3][0] * m[2][1];
309 |
310 | inv[3][1] = m[0][0] * m[2][1] * m[3][2] -
311 | m[0][0] * m[3][1] * m[2][2] -
312 | m[0][1] * m[2][0] * m[3][2] +
313 | m[0][1] * m[3][0] * m[2][2] +
314 | m[0][2] * m[2][0] * m[3][1] -
315 | m[0][2] * m[3][0] * m[2][1];
316 |
317 | inv[3][2] = -m[0][0] * m[1][1] * m[3][2] +
318 | m[0][0] * m[3][1] * m[1][2] +
319 | m[0][1] * m[1][0] * m[3][2] -
320 | m[0][1] * m[3][0] * m[1][2] -
321 | m[0][2] * m[1][0] * m[3][1] +
322 | m[0][2] * m[3][0] * m[1][1];
323 |
324 | inv[3][3] = m[0][0] * m[1][1] * m[2][2] -
325 | m[0][0] * m[2][1] * m[1][2] -
326 | m[0][1] * m[1][0] * m[2][2] +
327 | m[0][1] * m[2][0] * m[1][2] +
328 | m[0][2] * m[1][0] * m[2][1] -
329 | m[0][2] * m[2][0] * m[1][1];
330 |
331 | det = m[0][0] * inv[0][0] + m[1][0] * inv[0][1] + m[2][0] * inv[0][2] + m[3][0] * inv[0][3];
332 |
333 | if (det == 0)
334 | return 0;
335 |
336 | det = 1.0 / det;
337 |
338 | for (i = 0; i < 4; i++) {
339 | for (j = 0; j < 4; j++)
340 | out[i][j] = inv[i][j] * det;
341 | }
342 |
343 | return 1;
344 | }
345 |
346 | void matrix4x4_get_x_axis(const matrix4x4 m, vector3f *x_axis)
347 | {
348 | x_axis->x = m[0][0];
349 | x_axis->y = m[0][1];
350 | x_axis->z = m[0][2];
351 | }
352 |
353 | void matrix4x4_get_y_axis(const matrix4x4 m, vector3f *y_axis)
354 | {
355 | y_axis->x = m[1][0];
356 | y_axis->y = m[1][1];
357 | y_axis->z = m[1][2];
358 | }
359 |
360 | void matrix4x4_get_z_axis(const matrix4x4 m, vector3f *z_axis)
361 | {
362 | z_axis->x = m[2][0];
363 | z_axis->y = m[2][1];
364 | z_axis->z = m[2][2];
365 | }
366 |
367 | void matrix4x4_init_orthographic(matrix4x4 m, float left, float right, float bottom, float top, float near, float far)
368 | {
369 | m[0][0] = 2.0f / (right - left);
370 | m[0][1] = 0.0f;
371 | m[0][2] = 0.0f;
372 | m[0][3] = -(right + left) / (right - left);
373 |
374 | m[1][0] = 0.0f;
375 | m[1][1] = 2.0f / (top - bottom);
376 | m[1][2] = 0.0f;
377 | m[1][3] = -(top + bottom) / (top - bottom);
378 |
379 | m[2][0] = 0.0f;
380 | m[2][1] = 0.0f;
381 | m[2][2] = -2.0f / (far - near);
382 | m[2][3] = -(far + near) / (far - near);
383 |
384 | m[3][0] = 0.0f;
385 | m[3][1] = 0.0f;
386 | m[3][2] = 0.0f;
387 | m[3][3] = 1.0f;
388 | }
389 |
390 | void matrix4x4_init_frustum(matrix4x4 m, float left, float right, float bottom, float top, float near, float far)
391 | {
392 | m[0][0] = (2.0f * near) / (right - left);
393 | m[0][1] = 0.0f;
394 | m[0][2] = (right + left) / (right - left);
395 | m[0][3] = 0.0f;
396 |
397 | m[1][0] = 0.0f;
398 | m[1][1] = (2.0f * near) / (top - bottom);
399 | m[1][2] = (top + bottom) / (top - bottom);
400 | m[1][3] = 0.0f;
401 |
402 | m[2][0] = 0.0f;
403 | m[2][1] = 0.0f;
404 | m[2][2] = -(far + near) / (far - near);
405 | m[2][3] = (-2.0f * far * near) / (far - near);
406 |
407 | m[3][0] = 0.0f;
408 | m[3][1] = 0.0f;
409 | m[3][2] = -1.0f;
410 | m[3][3] = 0.0f;
411 | }
412 |
413 | void matrix3x3_normal_matrix(matrix3x3 out, const matrix4x4 m)
414 | {
415 | matrix4x4 m1, m2;
416 |
417 | matrix4x4_invert(m1, m);
418 | matrix4x4_transpose(m2, m1);
419 | matrix3x3_from_matrix4x4(out, m2);
420 | }
421 |
422 | // Code from http://aras-p.info/texts/obliqueortho.html
423 | // and http://www.terathon.com/code/oblique.php
424 | void matrix4x4_oblique_near_plane(matrix4x4 projection, const vector4f *clip_plane)
425 | {
426 | vector4f v;
427 | vector4f q;
428 | vector4f c;
429 | matrix4x4 proj_inv;
430 |
431 | vector4f_init(&v, sgn(clip_plane->x), sgn(clip_plane->y), 1.0f, 1.0f);
432 |
433 | matrix4x4_invert(proj_inv, projection);
434 |
435 | vector4f_matrix4x4_mult(&q, proj_inv, &v);
436 |
437 | vector4f_scalar_mult_dest(&c, clip_plane, 2.0f / vector4f_dot_product(clip_plane, &q));
438 |
439 | // third row = clip plane - fourth row
440 | projection[2][0] = c.x - projection[3][0];
441 | projection[2][1] = c.y - projection[3][1];
442 | projection[2][2] = c.z - projection[3][2];
443 | projection[2][3] = c.w - projection[3][3];
444 | }
445 |
--------------------------------------------------------------------------------
/math_utils.h:
--------------------------------------------------------------------------------
1 | #ifndef MATH_UTILS_H
2 | #define MATH_UTILS_H
3 |
4 | #include
5 |
6 | #ifndef DEG_TO_RAD
7 | #define DEG_TO_RAD(x) ((x) * M_PI / 180.0)
8 | #endif
9 | #define RAD_TO_RAD(x) ((x) * 180.0 / M_PI)
10 |
11 | typedef struct {
12 | float x, y;
13 | } vector2f;
14 |
15 | typedef struct {
16 | union { float x; float r; };
17 | union { float y; float g; };
18 | union { float z; float b; };
19 | } vector3f;
20 |
21 | typedef struct {
22 | union { float x; float r; };
23 | union { float y; float g; };
24 | union { float z; float b; };
25 | union { float w; float a; };
26 | } vector4f;
27 |
28 | typedef float matrix3x3[3][3];
29 | typedef float matrix4x4[4][4];
30 |
31 | void vector3f_init(vector3f *v, float x, float y, float z);
32 | void vector3f_copy(vector3f *dst, const vector3f *src);
33 | float vector3f_length(const vector3f *v);
34 | void vector3f_add(vector3f *v1, const vector3f *v2);
35 | void vector3f_scalar_mult(vector3f *v, float a);
36 | void vector3f_add_mult(vector3f *v, const vector3f *u, float a);
37 | void vector3f_opposite(vector3f *v1, const vector3f *v0);
38 | float vector3f_dot_product(const vector3f *v1, const vector3f *v2);
39 | void vector3f_cross_product(vector3f *w, const vector3f *u, const vector3f *v);
40 | void vector3f_matrix4x4_mult(vector3f *u, const matrix4x4 m, const vector3f *v, float w);
41 |
42 | void vector4f_init(vector4f *v, float x, float y, float z, float w);
43 | void vector4f_scalar_mult_dest(vector4f *u, const vector4f *v, float a);
44 | float vector4f_dot_product(const vector4f *v1, const vector4f *v2);
45 | void vector4f_matrix4x4_mult(vector4f *u, const matrix4x4 m, const vector4f *v);
46 |
47 | void matrix3x3_identity(matrix3x3 m);
48 | void matrix3x3_from_matrix4x4(matrix3x3 dst, const matrix4x4 src);
49 |
50 | void matrix4x4_identity(matrix4x4 m);
51 | void matrix4x4_copy(matrix4x4 dst, const matrix4x4 src);
52 |
53 | void matrix4x4_multiply(matrix4x4 dst, const matrix4x4 src1, const matrix4x4 src2);
54 |
55 | void matrix4x4_init_rotation_x(matrix4x4 m, float rad);
56 | void matrix4x4_init_rotation_y(matrix4x4 m, float rad);
57 | void matrix4x4_init_rotation_z(matrix4x4 m, float rad);
58 |
59 | void matrix4x4_rotate_x(matrix4x4 m, float rad);
60 | void matrix4x4_rotate_y(matrix4x4 m, float rad);
61 | void matrix4x4_rotate_z(matrix4x4 m, float rad);
62 |
63 | void matrix4x4_init_translation(matrix4x4 m, float x, float y, float z);
64 | void matrix4x4_init_translation_vector3f(matrix4x4 m, const vector3f *v);
65 | void matrix4x4_translate(matrix4x4 m, float x, float y, float z);
66 |
67 | void matrix4x4_init_scaling(matrix4x4 m, float scale_x, float scale_y, float scale_z);
68 | void matrix4x4_scale(matrix4x4 m, float scale_x, float scale_y, float scale_z);
69 | void matrix4x4_reflect_origin(matrix4x4 m);
70 |
71 | void matrix4x4_transpose(matrix4x4 out, const matrix4x4 m);
72 | int matrix4x4_invert(matrix4x4 out, const matrix4x4 m);
73 |
74 | void matrix4x4_get_x_axis(const matrix4x4 m, vector3f *x_axis);
75 | void matrix4x4_get_y_axis(const matrix4x4 m, vector3f *y_axis);
76 | void matrix4x4_get_z_axis(const matrix4x4 m, vector3f *z_axis);
77 |
78 | void matrix4x4_init_orthographic(matrix4x4 m, float left, float right, float bottom, float top, float near, float far);
79 | void matrix4x4_init_frustum(matrix4x4 m, float left, float right, float bottom, float top, float near, float far);
80 | void matrix4x4_init_perspective(matrix4x4 m, float fov, float aspect, float near, float far);
81 |
82 | /* Graphics related */
83 |
84 | void matrix3x3_normal_matrix(matrix3x3 out, const matrix4x4 m);
85 | void matrix4x4_build_model_matrix(matrix4x4 m, const vector3f *translation,
86 | const vector3f *rotation);
87 | void matrix4x4_oblique_near_plane(matrix4x4 projection, const vector4f *clip_plane);
88 |
89 | #endif
90 |
--------------------------------------------------------------------------------
/reRescaler.yml:
--------------------------------------------------------------------------------
1 | reRescaler:
2 | attributes: 0
3 | version:
4 | major: 1
5 | minor: 2
6 | main:
7 | start: module_start
8 | stop: module_stop
9 |
--------------------------------------------------------------------------------
/renderer.c:
--------------------------------------------------------------------------------
1 | /*
2 | * This File is Part Of :
3 | * ___ ___ ___ ___ ___ ___
4 | * / /\ ___ /__/\ / /\ /__/\ / /\ / /\ ___
5 | * / /::\ / /\ \ \:\ / /:/ \ \:\ / /:/_ / /::\ / /\
6 | * / /:/\:\ / /:/ \ \:\ / /:/ \__\:\ / /:/ /\ / /:/\:\ / /:/
7 | * / /:/~/:/ /__/::\ _____\__\:\ / /:/ ___ ___ / /::\ / /:/ /:/_ / /:/~/::\ / /:/
8 | * /__/:/ /:/___ \__\/\:\__ /__/::::::::\ /__/:/ / /\ /__/\ /:/\:\ /__/:/ /:/ /\ /__/:/ /:/\:\ / /::\
9 | * \ \:\/:::::/ \ \:\/\ \ \:\~~\~~\/ \ \:\ / /:/ \ \:\/:/__\/ \ \:\/:/ /:/ \ \:\/:/__\/ /__/:/\:\
10 | * \ \::/~~~~ \__\::/ \ \:\ ~~~ \ \:\ /:/ \ \::/ \ \::/ /:/ \ \::/ \__\/ \:\
11 | * \ \:\ /__/:/ \ \:\ \ \:\/:/ \ \:\ \ \:\/:/ \ \:\ \ \:\
12 | * \ \:\ \__\/ \ \:\ \ \::/ \ \:\ \ \::/ \ \:\ \__\/
13 | * \__\/ \__\/ \__\/ \__\/ \__\/ \__\/
14 | *
15 | * Copyright (c) Rinnegatamante
16 | *
17 | */
18 |
19 | #include
20 | #include
21 |
22 | #include
23 | #include
24 | #include
25 | #include
26 |
27 | #include "font.h"
28 |
29 | uint32_t* vram32;
30 | int pwidth, pheight, bufferwidth;
31 | uint32_t color = 0xFFFFFFFF;
32 |
33 | void updateFramebuf(void *fb, int w, int h, int p){
34 | pwidth = w;
35 | pheight = h;
36 | bufferwidth = p;
37 | vram32 = (uint32_t*)fb;
38 | }
39 |
40 | void clearScreen(){
41 | memset(vram32, 0x00000000, (bufferwidth*pheight)<<2);
42 | }
43 |
44 | void setTextColor(uint32_t clr){
45 | color = clr;
46 | }
47 |
48 | void drawCharacter(int character, int x, int y){
49 | for (int yy = 0; yy < 10; yy++) {
50 | int xDisplacement = x;
51 | int yDisplacement = (y + (yy<<1)) * bufferwidth;
52 | uint32_t* screenPos = vram32 + xDisplacement + yDisplacement;
53 |
54 | uint8_t charPos = font[character * 10 + yy];
55 | for (int xx = 7; xx >= 2; xx--) {
56 | uint32_t clr = ((charPos >> xx) & 1) ? color : 0x00000000;
57 | *(screenPos) = clr;
58 | *(screenPos+1) = clr;
59 | *(screenPos+bufferwidth) = clr;
60 | *(screenPos+bufferwidth+1) = clr;
61 | screenPos += 2;
62 | }
63 | }
64 | }
65 |
66 |
67 |
68 | void drawString(int x, int y, const char *str){
69 | for (size_t i = 0; i < strlen(str); i++)
70 | drawCharacter(str[i], x + i * 12, y);
71 | }
72 |
73 | void drawStringF(int x, int y, const char *format, ...){
74 | char str[512] = { 0 };
75 | va_list va;
76 |
77 | va_start(va, format);
78 | vsnprintf(str, 512, format, va);
79 | va_end(va);
80 |
81 | for (char* text = strtok(str, "\n"); text != NULL; text = strtok(NULL, "\n"), y += 20)
82 | drawString(x, y, text);
83 | }
84 |
--------------------------------------------------------------------------------
/renderer.h:
--------------------------------------------------------------------------------
1 | /*
2 | * This File is Part Of :
3 | * ___ ___ ___ ___ ___ ___
4 | * / /\ ___ /__/\ / /\ /__/\ / /\ / /\ ___
5 | * / /::\ / /\ \ \:\ / /:/ \ \:\ / /:/_ / /::\ / /\
6 | * / /:/\:\ / /:/ \ \:\ / /:/ \__\:\ / /:/ /\ / /:/\:\ / /:/
7 | * / /:/~/:/ /__/::\ _____\__\:\ / /:/ ___ ___ / /::\ / /:/ /:/_ / /:/~/::\ / /:/
8 | * /__/:/ /:/___ \__\/\:\__ /__/::::::::\ /__/:/ / /\ /__/\ /:/\:\ /__/:/ /:/ /\ /__/:/ /:/\:\ / /::\
9 | * \ \:\/:::::/ \ \:\/\ \ \:\~~\~~\/ \ \:\ / /:/ \ \:\/:/__\/ \ \:\/:/ /:/ \ \:\/:/__\/ /__/:/\:\
10 | * \ \::/~~~~ \__\::/ \ \:\ ~~~ \ \:\ /:/ \ \::/ \ \::/ /:/ \ \::/ \__\/ \:\
11 | * \ \:\ /__/:/ \ \:\ \ \:\/:/ \ \:\ \ \:\/:/ \ \:\ \ \:\
12 | * \ \:\ \__\/ \ \:\ \ \::/ \ \:\ \ \::/ \ \:\ \__\/
13 | * \__\/ \__\/ \__\/ \__\/ \__\/ \__\/
14 | *
15 | * Copyright (c) Rinnegatamante
16 | *
17 | */
18 |
19 | #ifndef _RENDERER_H_
20 | #define _RENDERER_H_
21 |
22 | #include
23 |
24 | void updateFramebuf(void *fb, int w, int h, int p);
25 | void clearScreen();
26 | void drawCharacter(int character, int x, int y);
27 | void drawString(int x, int y, const char *str);
28 | void drawStringF(int x, int y, const char *format, ...);
29 | void setTextColor(uint32_t clr);
30 |
31 | #endif
--------------------------------------------------------------------------------
/shaders/lcd3x_f.h:
--------------------------------------------------------------------------------
1 | #ifndef __lcd3x_f__
2 | #define __lcd3x_f__
3 |
4 | static unsigned int size_lcd3x_f = 752;
5 | static unsigned char lcd3x_f[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0xf0, 0x02, 0x00, 0x00, 0xd6, 0xb2, 0x4c, 0x9c,
7 | 0x16, 0xc0, 0x4d, 0xd5, 0x05, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x98, 0x02, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x04, 0x00, 0x19, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x25, 0x00, 0x00, 0x00,
10 | 0x90, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x74, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x48, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
13 | 0x17, 0x00, 0x00, 0x00, 0x84, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x02, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0x2c, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x02, 0x00, 0x00,
15 | 0x02, 0x00, 0x00, 0x00, 0x1c, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x01, 0x04, 0x01, 0x00, 0x01, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x09, 0x40, 0x0e,
17 | 0x00, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x18, 0x00, 0x04, 0x90,
18 | 0x86, 0x01, 0xa5, 0x08, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x04, 0xf8, 0x00, 0x00, 0x00, 0x00,
19 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa, 0x00, 0x00, 0x04, 0xe0, 0x84, 0x41, 0xa4, 0x08,
20 | 0xcc, 0x02, 0x14, 0xf0, 0x82, 0x00, 0x80, 0x00, 0x00, 0x20, 0x04, 0xa0, 0x86, 0x00, 0xa4, 0x08,
21 | 0xca, 0x02, 0x40, 0xf0, 0x84, 0x28, 0x80, 0x00, 0x04, 0x81, 0xc1, 0xff, 0x9c, 0x0d, 0xc0, 0x40,
22 | 0xbe, 0x02, 0x00, 0xcf, 0x80, 0x8b, 0x80, 0x00, 0x0c, 0x00, 0x1d, 0x4f, 0x84, 0x8b, 0xa3, 0x18,
23 | 0x3c, 0x2f, 0x04, 0x0f, 0x84, 0x4b, 0xa4, 0x08, 0x09, 0xc6, 0x03, 0x7f, 0x80, 0x2b, 0xa2, 0x00,
24 | 0x41, 0x00, 0x04, 0x00, 0x84, 0x08, 0xa4, 0x08, 0x3c, 0x81, 0x51, 0x0f, 0x80, 0x8b, 0xe1, 0x18,
25 | 0x48, 0x02, 0x00, 0xf0, 0x82, 0x28, 0x80, 0x00, 0x08, 0x00, 0x00, 0x30, 0x8e, 0x08, 0x80, 0x00,
26 | 0x0c, 0x00, 0x00, 0x30, 0x86, 0x08, 0x80, 0x00, 0x01, 0x00, 0x44, 0x80, 0x84, 0x08, 0xa4, 0x08,
27 | 0xc7, 0x01, 0x10, 0xf0, 0x82, 0x08, 0x80, 0x00, 0x06, 0x00, 0x00, 0x30, 0x8e, 0x28, 0x80, 0x00,
28 | 0x06, 0x00, 0x00, 0x30, 0x84, 0x08, 0x80, 0x00, 0x5d, 0xd1, 0x93, 0xdf, 0x80, 0x0b, 0xa1, 0x00,
29 | 0x5e, 0xef, 0x83, 0x1f, 0x88, 0x1b, 0xa1, 0x00, 0x4c, 0xef, 0x83, 0x1f, 0x80, 0x1b, 0xa1, 0x00,
30 | 0x3e, 0x81, 0x11, 0x0f, 0x80, 0x8b, 0xe1, 0x18, 0x44, 0xd1, 0x83, 0xff, 0x80, 0x2b, 0xa0, 0x00,
31 | 0x4d, 0xef, 0x83, 0x1f, 0x88, 0x1b, 0xa1, 0x00, 0x41, 0xef, 0x43, 0x1f, 0x80, 0x3b, 0xa1, 0x00,
32 | 0x01, 0x00, 0x04, 0x00, 0x86, 0x08, 0xa4, 0x08, 0x40, 0x00, 0x00, 0x20, 0x82, 0x08, 0x80, 0x00,
33 | 0x00, 0x00, 0x00, 0xa0, 0x46, 0x0d, 0xc1, 0x40, 0x03, 0x01, 0x00, 0xf0, 0x86, 0x48, 0x80, 0x04,
34 | 0x40, 0x00, 0x44, 0xa0, 0x86, 0x0b, 0xa4, 0x10, 0x3d, 0x81, 0x91, 0x0f, 0x80, 0x8b, 0xe1, 0x18,
35 | 0x3d, 0x21, 0x11, 0x0f, 0x80, 0x83, 0xb1, 0x18, 0x00, 0xbc, 0x01, 0x20, 0x5e, 0x0d, 0x81, 0x40,
36 | 0xc2, 0x00, 0x00, 0xf0, 0x86, 0x42, 0xa0, 0x04, 0x40, 0x00, 0x04, 0xa0, 0x86, 0x43, 0xa4, 0x10,
37 | 0x0f, 0x00, 0x04, 0x90, 0x86, 0x17, 0xc5, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3e,
38 | 0x01, 0x00, 0x00, 0x00, 0xac, 0xaa, 0xaa, 0xbd, 0x02, 0x00, 0x00, 0x00, 0x56, 0x55, 0xd5, 0xbe,
39 | 0x03, 0x00, 0x00, 0x00, 0x62, 0x3b, 0x62, 0x3b, 0x04, 0x00, 0x00, 0x00, 0xec, 0x2c, 0xec, 0x2c,
40 | 0x05, 0x00, 0x00, 0x00, 0xc2, 0x3b, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0xc2, 0x27, 0x00, 0x00,
41 | 0x07, 0x00, 0x00, 0x00, 0xab, 0xaa, 0x2a, 0x3b, 0x08, 0x00, 0x00, 0x00, 0x61, 0x0b, 0xb6, 0xb7,
42 | 0x09, 0x00, 0x00, 0x00, 0x01, 0x0d, 0xd0, 0xb5, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3f,
43 | 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x0c, 0x00, 0x00, 0x00, 0xab, 0xaa, 0x2a, 0x3b,
44 | 0x0d, 0x00, 0x00, 0x00, 0x61, 0x0b, 0xb6, 0xb7, 0x0e, 0x00, 0x00, 0x00, 0xab, 0xaa, 0xaa, 0x3c,
45 | 0x0f, 0x00, 0x00, 0x00, 0x89, 0x88, 0x88, 0x39, 0x10, 0x00, 0x00, 0x00, 0x01, 0x0d, 0xd0, 0xb5,
46 | 0x11, 0x00, 0x00, 0x00, 0xdb, 0x0f, 0x49, 0xc0, 0x12, 0x00, 0x00, 0x00, 0x83, 0xf9, 0x22, 0x3e,
47 | 0x13, 0x00, 0x00, 0x00, 0xdb, 0x0f, 0x49, 0xc0, 0x14, 0x00, 0x00, 0x00, 0xdb, 0x0f, 0xc9, 0x40,
48 | 0x15, 0x00, 0x00, 0x00, 0x83, 0xf9, 0x22, 0x3e, 0x16, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f,
49 | 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x17, 0x00,
50 | 0x20, 0x00, 0x00, 0x00, 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
51 | 0x1d, 0x00, 0x00, 0x00, 0x02, 0x04, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
52 | 0x74, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x73, 0x30, 0x00,
53 | };
54 |
55 | #endif
56 |
--------------------------------------------------------------------------------
/shaders/lcd3x_v.h:
--------------------------------------------------------------------------------
1 | #ifndef __lcd3x_v__
2 | #define __lcd3x_v__
3 |
4 | static unsigned int size_lcd3x_v = 308;
5 | static unsigned char lcd3x_v[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0x34, 0x01, 0x00, 0x00, 0x8e, 0x22, 0x83, 0xb6,
7 | 0xf6, 0x8e, 0xaf, 0xb3, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x08, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x05, 0x00, 0x00, 0x00,
10 | 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00,
13 | 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00,
15 | 0x01, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x06, 0x01, 0x00, 0x00, 0x00,
17 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
18 | 0x00, 0x07, 0x44, 0xfa, 0x80, 0x00, 0x08, 0x83, 0x21, 0x0d, 0x80, 0x38, 0x02, 0x80, 0x99, 0xaf,
19 | 0xbc, 0x0d, 0x80, 0x40, 0x00, 0xa2, 0x11, 0xc0, 0x81, 0x30, 0x90, 0x18, 0x00, 0x00, 0x20, 0xa0,
20 | 0x00, 0x50, 0x27, 0xfb, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x30, 0x00, 0x00, 0x00,
21 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x2a, 0x00, 0x00, 0x00,
22 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00,
23 | 0x01, 0xe4, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x61, 0x50, 0x6f, 0x73,
24 | 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x00, 0x61, 0x54, 0x65, 0x78, 0x63, 0x6f, 0x6f, 0x72, 0x64, 0x00,
25 | 0x77, 0x76, 0x70, 0x00,
26 | };
27 |
28 | #endif
29 |
--------------------------------------------------------------------------------
/shaders/sharp_bilinear_f.h:
--------------------------------------------------------------------------------
1 | #ifndef __sharp_bilinear_f__
2 | #define __sharp_bilinear_f__
3 |
4 | static unsigned int size_sharp_bilinear_f = 748;
5 | static unsigned char sharp_bilinear_f[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0xec, 0x02, 0x00, 0x00, 0xb1, 0x9b, 0x2e, 0x19,
7 | 0xb8, 0x23, 0x6e, 0xf5, 0x05, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x02, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x78, 0x02, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x04, 0x00, 0x17, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x20, 0x00, 0x00, 0x00,
10 | 0xd8, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, 0xc8, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x18, 0x02, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00,
13 | 0x0d, 0x00, 0x00, 0x00, 0xa4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x02, 0x00, 0x00,
14 | 0x04, 0x00, 0x00, 0x00, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x02, 0x00, 0x00,
15 | 0x02, 0x00, 0x00, 0x00, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x01, 0x04, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0f, 0x00, 0x40, 0x0c,
17 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x10, 0x40, 0x0e,
18 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x40, 0x81,
19 | 0x0a, 0x00, 0x80, 0x30, 0x40, 0x80, 0xd0, 0xa2, 0x8a, 0x10, 0xc0, 0x08, 0x00, 0x00, 0x40, 0xa0,
20 | 0x0a, 0x00, 0x81, 0x50, 0xca, 0x02, 0x40, 0xa0, 0x06, 0x11, 0xa4, 0x08, 0x44, 0x00, 0x04, 0xa1,
21 | 0x86, 0x41, 0xa4, 0x08, 0x01, 0x00, 0x20, 0x80, 0x02, 0x00, 0x80, 0x30, 0x02, 0x00, 0x20, 0x80,
22 | 0x0a, 0x00, 0x80, 0x30, 0xcf, 0x83, 0x04, 0x50, 0x8a, 0x17, 0xc3, 0x10, 0x00, 0x00, 0x00, 0x00,
23 | 0x40, 0x01, 0x04, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa,
24 | 0x41, 0x20, 0x04, 0xa1, 0x84, 0x41, 0x24, 0x08, 0x0a, 0x11, 0xc4, 0x30, 0x84, 0x01, 0x24, 0x08,
25 | 0x00, 0x01, 0x04, 0xe0, 0x86, 0x41, 0xa4, 0x08, 0x4c, 0x02, 0x10, 0xd0, 0x86, 0x01, 0xa1, 0x00,
26 | 0x00, 0x20, 0x04, 0xa0, 0x86, 0x41, 0xa4, 0x08, 0x09, 0x06, 0x00, 0x70, 0x84, 0x01, 0xa2, 0x00,
27 | 0x00, 0x00, 0x44, 0x00, 0x84, 0x41, 0xa4, 0x08, 0x1d, 0x12, 0x10, 0xd0, 0x82, 0x01, 0xa1, 0x00,
28 | 0x5e, 0x00, 0x00, 0x10, 0x8e, 0x11, 0xa1, 0x00, 0x4c, 0x00, 0x00, 0x10, 0x86, 0x11, 0xa1, 0x00,
29 | 0x00, 0x00, 0x84, 0x80, 0x84, 0x41, 0xa4, 0x08, 0x07, 0x12, 0x00, 0xf0, 0x82, 0x21, 0xa0, 0x00,
30 | 0x4d, 0x00, 0x00, 0x10, 0x8e, 0x11, 0xa1, 0x00, 0x41, 0x00, 0x40, 0x10, 0x84, 0x31, 0xa1, 0x00,
31 | 0xc7, 0x50, 0x04, 0x30, 0x86, 0x01, 0x24, 0x08, 0x06, 0x60, 0x04, 0xb0, 0x86, 0x11, 0x24, 0x08,
32 | 0x03, 0x10, 0x04, 0x80, 0xa4, 0x41, 0x24, 0x08, 0x01, 0x11, 0x04, 0x20, 0xa6, 0x41, 0x24, 0x08,
33 | 0x80, 0x01, 0x00, 0xe0, 0x82, 0x81, 0x20, 0x00, 0x0c, 0x10, 0x04, 0x90, 0x86, 0x01, 0x25, 0x08,
34 | 0x40, 0x00, 0x04, 0xe0, 0x86, 0x41, 0x24, 0x08, 0x00, 0x01, 0x40, 0xe0, 0x84, 0x84, 0x01, 0xe0,
35 | 0x42, 0x00, 0x04, 0x00, 0x86, 0x41, 0xa4, 0x08, 0x80, 0x10, 0x00, 0x20, 0x82, 0x91, 0xa0, 0x00,
36 | 0x00, 0x00, 0x01, 0xa0, 0x4e, 0x0d, 0x81, 0x40, 0x05, 0x00, 0x04, 0xb0, 0x86, 0xb1, 0xa4, 0x10,
37 | 0x00, 0x70, 0x04, 0xb0, 0x8a, 0x40, 0xc0, 0x10, 0x05, 0x10, 0x00, 0xb0, 0x82, 0x03, 0xa4, 0x10,
38 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xf9, 0x40, 0x00, 0x04, 0xa0, 0x86, 0x43, 0xa4, 0x10,
39 | 0x0f, 0x00, 0x04, 0x90, 0x86, 0x17, 0xc5, 0x10, 0x04, 0x00, 0x00, 0x00, 0x56, 0x0e, 0xc9, 0x40,
40 | 0x05, 0x00, 0x00, 0x00, 0x56, 0x0e, 0x49, 0x40, 0x06, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00,
41 | 0x07, 0x00, 0x00, 0x00, 0x66, 0x2e, 0xcd, 0x30, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa0, 0x3f,
42 | 0x09, 0x00, 0x00, 0x00, 0xcc, 0xcc, 0xcc, 0xbd, 0x0a, 0x00, 0x00, 0x00, 0xcc, 0xcc, 0xcc, 0x3d,
43 | 0x0b, 0x00, 0x00, 0x00, 0xab, 0xaa, 0x2a, 0x3b, 0x0c, 0x00, 0x00, 0x00, 0x61, 0x0b, 0xb6, 0xb7,
44 | 0x0d, 0x00, 0x00, 0x00, 0x01, 0x0d, 0xd0, 0xb5, 0x0e, 0x00, 0x00, 0x00, 0xdb, 0x0f, 0x49, 0xc0,
45 | 0x0f, 0x00, 0x00, 0x00, 0x83, 0xf9, 0x22, 0x3e, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xbf,
46 | 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x00, 0x02, 0x00, 0x03, 0x00, 0x03, 0x00,
47 | 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x13, 0x00, 0x00, 0x00, 0x04, 0x00, 0x11, 0x00,
48 | 0x30, 0x00, 0x00, 0x00, 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
49 | 0x2d, 0x00, 0x00, 0x00, 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
50 | 0x29, 0x00, 0x00, 0x00, 0x02, 0x04, 0x02, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
51 | 0x74, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x6f, 0x75, 0x74,
52 | 0x70, 0x75, 0x74, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x73, 0x30, 0x00,
53 | };
54 |
55 | #endif
56 |
--------------------------------------------------------------------------------
/shaders/sharp_bilinear_simple_f.h:
--------------------------------------------------------------------------------
1 | #ifndef __sharp_bilinear_simple_f__
2 | #define __sharp_bilinear_simple_f__
3 |
4 | static unsigned int size_sharp_bilinear_simple_f = 440;
5 | static unsigned char sharp_bilinear_simple_f[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0xb8, 0x01, 0x00, 0x00, 0xa8, 0x7b, 0x2f, 0x20,
7 | 0x89, 0xaa, 0x83, 0x7e, 0x05, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x02, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x60, 0x01, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x04, 0x00, 0x07, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x10, 0x00, 0x00, 0x00,
10 | 0xa0, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
13 | 0x01, 0x00, 0x00, 0x00, 0xec, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x01, 0x00, 0x00,
14 | 0x04, 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xec, 0x00, 0x00, 0x00,
15 | 0x02, 0x00, 0x00, 0x00, 0xe4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x01, 0x04, 0x02, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0f, 0x10, 0x40, 0x0c,
17 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x20, 0x40, 0x0e,
18 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80,
19 | 0x02, 0x00, 0x80, 0x30, 0x02, 0x00, 0x00, 0x80, 0x0a, 0x00, 0x84, 0x30, 0x00, 0x00, 0x00, 0x00,
20 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa, 0x00, 0x20, 0xc4, 0xa0, 0x84, 0x41, 0x24, 0x08,
21 | 0xc3, 0x10, 0x84, 0x30, 0x84, 0x01, 0x24, 0x08, 0x81, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x30,
22 | 0x82, 0x00, 0x00, 0x80, 0x08, 0x00, 0x00, 0x30, 0x0c, 0x03, 0x40, 0x50, 0xa0, 0x01, 0x23, 0x00,
23 | 0x42, 0x50, 0x04, 0x00, 0x84, 0x41, 0x24, 0x08, 0x40, 0x60, 0x04, 0x00, 0xa4, 0x41, 0x24, 0x08,
24 | 0x02, 0x10, 0x04, 0x00, 0xa4, 0x41, 0x24, 0x08, 0xc0, 0x10, 0x04, 0x20, 0xa6, 0x41, 0x24, 0x08,
25 | 0x00, 0x10, 0x00, 0x20, 0x86, 0x91, 0x20, 0x00, 0x0c, 0x10, 0x04, 0x90, 0x86, 0x01, 0x25, 0x08,
26 | 0x00, 0x00, 0x04, 0xe0, 0x86, 0x41, 0x24, 0x08, 0x80, 0x00, 0x00, 0xe0, 0x84, 0x84, 0x01, 0xe0,
27 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xf9, 0x0f, 0x00, 0x04, 0x90, 0x86, 0x17, 0xc5, 0x10,
28 | 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xbf, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00,
29 | 0x02, 0x00, 0x02, 0x00, 0x03, 0x00, 0x03, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00,
30 | 0x13, 0x00, 0x00, 0x00, 0x02, 0x00, 0x05, 0x00, 0x20, 0x00, 0x00, 0x00, 0x01, 0xe2, 0x00, 0x00,
31 | 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1d, 0x00, 0x00, 0x00, 0x02, 0x04, 0x02, 0x00,
32 | 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x74, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x5f,
33 | 0x73, 0x69, 0x7a, 0x65, 0x00, 0x73, 0x30, 0x00,
34 | };
35 |
36 | #endif
37 |
--------------------------------------------------------------------------------
/shaders/sharp_bilinear_simple_v.h:
--------------------------------------------------------------------------------
1 | #ifndef __sharp_bilinear_simple_v__
2 | #define __sharp_bilinear_simple_v__
3 |
4 | static unsigned int size_sharp_bilinear_simple_v = 448;
5 | static unsigned char sharp_bilinear_simple_v[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0xbd, 0x01, 0x00, 0x00, 0x68, 0x53, 0xfa, 0xa0,
7 | 0x7d, 0xac, 0x25, 0xb6, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x14, 0x01, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x08, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x08, 0x00, 0x00, 0x00,
10 | 0xb4, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xa4, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, 0xcc, 0x00, 0x00, 0x00, 0x14, 0x00, 0x00, 0x00,
13 | 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0xb0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, 0x00, 0x00, 0x00,
15 | 0x01, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x0a, 0x49, 0x00, 0x00, 0x00,
17 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x04, 0x60, 0x81, 0x02, 0x00, 0x80, 0x30,
18 | 0x02, 0x04, 0x60, 0x81, 0x0a, 0x00, 0x80, 0x30, 0x4b, 0x02, 0x84, 0xa2, 0x86, 0x41, 0xa4, 0x08,
19 | 0x8a, 0x22, 0x84, 0xa2, 0x86, 0x41, 0xa4, 0x08, 0xca, 0x92, 0x40, 0xa2, 0x8e, 0x91, 0xa0, 0x00,
20 | 0x41, 0x62, 0x44, 0x92, 0x86, 0x11, 0xa5, 0x08, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x04, 0xf8,
21 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa, 0x00, 0x00, 0x00, 0x00,
22 | 0x40, 0x09, 0x00, 0xf8, 0x02, 0x80, 0x99, 0xaf, 0xbc, 0x0d, 0x80, 0x40, 0x00, 0xa2, 0x11, 0xc0,
23 | 0x81, 0x30, 0x90, 0x18, 0x02, 0x02, 0xc4, 0xe0, 0x85, 0x41, 0xa4, 0x08, 0x80, 0x00, 0x08, 0x83,
24 | 0x21, 0x05, 0x80, 0x38, 0x40, 0x02, 0x10, 0xc3, 0x21, 0x05, 0x80, 0x38, 0x00, 0x00, 0x20, 0xa0,
25 | 0x00, 0x50, 0x27, 0xfb, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x14, 0x00, 0x50, 0x00, 0x00, 0x00,
26 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4a, 0x00, 0x00, 0x00,
27 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00,
28 | 0x01, 0xe4, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00,
29 | 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x35, 0x00, 0x00, 0x00,
30 | 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0x61, 0x50, 0x6f, 0x73,
31 | 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x00, 0x61, 0x54, 0x65, 0x78, 0x63, 0x6f, 0x6f, 0x72, 0x64, 0x00,
32 | 0x77, 0x76, 0x70, 0x00, 0x74, 0x65, 0x78, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65,
33 | 0x00, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x00, 0x00, 0x00,
34 | };
35 |
36 | #endif
37 |
--------------------------------------------------------------------------------
/shaders/sharp_bilinear_v.h:
--------------------------------------------------------------------------------
1 | #ifndef __sharp_bilinear_v__
2 | #define __sharp_bilinear_v__
3 |
4 | static unsigned int size_sharp_bilinear_v = 396;
5 | static unsigned char sharp_bilinear_v[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0x89, 0x01, 0x00, 0x00, 0x56, 0x41, 0x2a, 0x59,
7 | 0x50, 0xdf, 0x81, 0x6d, 0x04, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xfc, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x08, 0x00, 0x14, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x07, 0x00, 0x00, 0x00,
10 | 0x94, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x84, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0xac, 0x00, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00,
13 | 0x01, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, 0x00, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00,
15 | 0x02, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x08, 0x09, 0x00, 0x00, 0x00,
17 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x04, 0x20, 0x81, 0x02, 0x00, 0x80, 0x30,
18 | 0x49, 0x82, 0x68, 0xa2, 0x86, 0x00, 0xc0, 0x08, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x04, 0xf8,
19 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa, 0x00, 0x00, 0x00, 0x00,
20 | 0x40, 0x09, 0x00, 0xf8, 0x02, 0x80, 0x99, 0xaf, 0xbc, 0x0d, 0x80, 0x40, 0x00, 0xa2, 0x11, 0xc0,
21 | 0x81, 0x30, 0x90, 0x18, 0x42, 0x12, 0x90, 0xe0, 0xa5, 0x41, 0xa4, 0x08, 0x02, 0x02, 0xc4, 0xe0,
22 | 0x85, 0x41, 0xa4, 0x08, 0x00, 0x00, 0x20, 0xa0, 0x00, 0x50, 0x27, 0xfb, 0x00, 0x00, 0x00, 0x00,
23 | 0x00, 0x00, 0x80, 0x3e, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x12, 0x00, 0x13, 0x00, 0x00, 0x00,
24 | 0x12, 0x00, 0x01, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
25 | 0x00, 0x00, 0x00, 0x00, 0x3a, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
26 | 0x04, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x01, 0xe4, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00,
27 | 0x00, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x01, 0xe2, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
28 | 0x10, 0x00, 0x00, 0x00, 0x61, 0x50, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x00, 0x61, 0x54,
29 | 0x65, 0x78, 0x63, 0x6f, 0x6f, 0x72, 0x64, 0x00, 0x77, 0x76, 0x70, 0x00, 0x74, 0x65, 0x78, 0x74,
30 | 0x75, 0x72, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x00, 0x00, 0x00, 0x00,
31 | };
32 |
33 | #endif
34 |
--------------------------------------------------------------------------------
/shaders/src/lcd3x_f.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers (untested)
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: Gigaherz
8 | License: Public domain
9 | */
10 |
11 | /* configuration (higher values mean brighter image but reduced effect depth) */
12 | static const float brighten_scanlines = 32.0;
13 | static const float brighten_lcd = 12.0;
14 | static const float3 offsets = 3.141592654 * float3(1.0 / 2.0, 1.0 / 2.0 - 2.0 /3.0, 1.0 / 2.0 - 4.0 / 3.0);
15 |
16 | struct out_vertex
17 | {
18 | float4 vPosition : POSITION;
19 | float2 vTexcoord : TEXCOORD0;
20 | };
21 |
22 | float4 main
23 | (
24 | out_vertex co,
25 | uniform sampler2D s0 : TEXUNIT0,
26 | uniform float2 texture_size
27 | ) : COLOR
28 | {
29 | float3 res = tex2D(s0, co.vTexcoord).xyz;
30 |
31 | float2 omega = 3.141592654 * 2.0 * texture_size;
32 |
33 | float2 angle = co.vTexcoord * omega;
34 |
35 | float yfactor = (brighten_scanlines + sin(angle.y)) / (brighten_scanlines + 1.0);
36 | float3 xfactors = (brighten_lcd + sin(angle.x + offsets)) / (brighten_lcd + 1.0);
37 |
38 | float3 color = yfactor * xfactors * res;
39 |
40 | return float4(color.x, color.y, color.z, 1.0);
41 | }
42 |
--------------------------------------------------------------------------------
/shaders/src/lcd3x_v.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers (untested)
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: Gigaherz
8 | License: Public domain
9 | */
10 |
11 | struct out_vertex
12 | {
13 | float4 vPosition : POSITION;
14 | float2 vTexcoord : TEXCOORD0;
15 | };
16 |
17 | void main
18 | (
19 | float4 aPosition,
20 | float2 aTexcoord,
21 | column_major uniform float4x4 wvp,
22 | out out_vertex co
23 | )
24 | {
25 | co.vPosition = mul(aPosition, wvp);
26 | co.vTexcoord = aTexcoord;
27 | }
28 |
--------------------------------------------------------------------------------
/shaders/src/sharp_bilinear_f.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: Themaister
8 | License: Public domain
9 | */
10 |
11 | struct out_vertex
12 | {
13 | float4 vPosition : POSITION;
14 | float2 vTexcoord : TEXCOORD0;
15 | float2 texel : TEXCOORD1;
16 | };
17 |
18 | #define SCANLINE_BASE_BRIGHTNESS 1.0
19 | #define SCANLINE_SINE_COMP_A 0.1
20 | #define SCANLINE_SINE_COMP_B 0.15
21 | #define SHARP_BILINEAR_PRE_SCALE 1.25
22 |
23 |
24 | float4 main
25 | (
26 | out_vertex co,
27 | uniform sampler2D s0 : TEXUNIT0,
28 | uniform float2 texture_size,
29 | uniform float2 output_size
30 | ) : COLOR
31 | {
32 | float2 texel_floored = floor(co.texel);
33 | float2 s = frac(co.texel);
34 | float region_range = 0.5 - 0.5 / SHARP_BILINEAR_PRE_SCALE;
35 |
36 | // Figure out where in the texel to sample to get correct pre-scaled bilinear.
37 | // Uses the hardware bilinear interpolator to avoid having to sample 4 times manually.
38 |
39 | float2 center_dist = s - 0.5;
40 | float2 f = (center_dist - clamp(center_dist, -region_range, region_range)) * SHARP_BILINEAR_PRE_SCALE + 0.5;
41 | float2 mod_texel = texel_floored + f;
42 |
43 | float3 res = tex2D(s0, mod_texel / texture_size).rgb;
44 |
45 | float2 sine_comp = float2(SCANLINE_SINE_COMP_A, SCANLINE_SINE_COMP_B);
46 |
47 | float2 omega = float2(2.0 * 3.1415 * texture_size.x, 3.1415 * output_size.y * texture_size.y / texture_size.y);
48 |
49 | float3 scanline = res * (SCANLINE_BASE_BRIGHTNESS + dot(sine_comp * sin(co.vTexcoord * omega), float2(1.0, 1.0)));
50 |
51 | return float4(scanline, 1.0);
52 | }
53 |
--------------------------------------------------------------------------------
/shaders/src/sharp_bilinear_simple_f.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: rsn8887 (based on TheMaister)
8 | License: Public domain
9 |
10 | This is an integer prescale filter that should be combined
11 | with a bilinear hardware filtering (GL_BILINEAR filter or some such) to achieve
12 | a smooth scaling result with minimum blur. This is good for pixelgraphics
13 | that are scaled by non-integer factors.
14 |
15 | The prescale factor and texel coordinates are precalculated
16 | in the vertex shader for speed.
17 | */
18 |
19 | struct out_vertex
20 | {
21 | float4 vPosition : POSITION;
22 | float2 vTexcoord : TEXCOORD0;
23 | float2 texel : TEXCOORD1;
24 | float2 prescale : TEXCOORD2;
25 | };
26 |
27 | float4 main
28 | (
29 | in out_vertex co,
30 | uniform sampler2D s0 : TEXUNIT0,
31 | uniform float2 texture_size
32 | ) : COLOR
33 | {
34 |
35 | //co.texel has already been multiplied by texture_size inside vertex shader
36 | float2 texel_floored = floor(co.texel);
37 | float2 s = frac(co.texel);
38 |
39 | //prescale is the largest possible integer scale, calculated in vertex shader
40 | float2 region_range = 0.5 - 0.5 / co.prescale;
41 |
42 | // Figure out where in the texel to sample to get correct pre-scaled bilinear.
43 | // Uses the hardware bilinear interpolator to avoid having to sample 4 times manually.
44 |
45 | float2 center_dist = s - 0.5;
46 | float2 f = (center_dist - clamp(center_dist, -region_range, region_range)) * co.prescale + 0.5;
47 | float2 mod_texel = texel_floored + f;
48 |
49 | return float4(tex2D(s0, mod_texel / texture_size).rgb, 1.0);
50 |
51 | }
--------------------------------------------------------------------------------
/shaders/src/sharp_bilinear_simple_v.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: rsn8887 (based on TheMaister)
8 | License: Public domain
9 |
10 | This is an integer prescale filter that should be combined
11 | with a bilinear hardware filtering (GL_BILINEAR filter or some such) to achieve
12 | a smooth scaling result with minimum blur. This is good for pixelgraphics
13 | that are scaled by non-integer factors.
14 |
15 | The prescale factor and texel coordinates are precalculated
16 | in the vertex shader for speed.
17 | */
18 |
19 | struct out_vertex
20 | {
21 | float4 vPosition : POSITION;
22 | float2 vTexcoord : TEXCOORD0;
23 | float2 texel : TEXCOORD1;
24 | float2 prescale : TEXCOORD2;
25 | };
26 |
27 | void main
28 | (
29 | float4 aPosition,
30 | float2 aTexcoord,
31 | column_major uniform float4x4 wvp,
32 | uniform float2 texture_size,
33 | uniform float2 output_size,
34 | out out_vertex co
35 | )
36 | {
37 | co.vPosition = mul(aPosition, wvp);
38 | co.vTexcoord = aTexcoord;
39 |
40 | //precalculate some values to pass to the fragment shader
41 | co.texel = aTexcoord * texture_size;
42 | co.prescale = max(floor(output_size / texture_size), float2(1.0, 1.0));
43 | }
44 |
--------------------------------------------------------------------------------
/shaders/src/sharp_bilinear_v.cg:
--------------------------------------------------------------------------------
1 | /* COMPATIBILITY
2 | - HLSL compilers
3 | - Cg compilers
4 | */
5 |
6 | /*
7 | Author: Themaister
8 | License: Public domain
9 | */
10 |
11 | struct out_vertex
12 | {
13 | float4 vPosition : POSITION;
14 | float2 vTexcoord : TEXCOORD0;
15 | float2 texel : TEXCOORD1;
16 | };
17 |
18 | void main
19 | (
20 | float4 aPosition,
21 | float2 aTexcoord,
22 | column_major uniform float4x4 wvp,
23 | uniform float2 texture_size,
24 | out out_vertex co
25 | )
26 | {
27 | co.vPosition = mul(aPosition, wvp);
28 | co.vTexcoord = aTexcoord - float2(0.25 / texture_size.x, 0.0);
29 |
30 | co.texel = aTexcoord * texture_size;
31 | }
32 |
--------------------------------------------------------------------------------
/shaders/src/texture2d_f.cg:
--------------------------------------------------------------------------------
1 | float4 main(
2 | float2 vTexcoord : TEXCOORD0,
3 | uniform sampler2D tex
4 | )
5 | {
6 | return tex2D(tex, vTexcoord);
7 | }
8 |
--------------------------------------------------------------------------------
/shaders/src/texture2d_v.cg:
--------------------------------------------------------------------------------
1 | void main(
2 | float3 position,
3 | float2 texcoord,
4 | column_major uniform float4x4 wvp,
5 | float4 out vPosition : POSITION,
6 | float2 out vTexcoord : TEXCOORD0)
7 | {
8 | vPosition = mul(float4(position, 1.f), wvp);
9 | vTexcoord = texcoord;
10 | }
11 |
--------------------------------------------------------------------------------
/shaders/texture2d_f.h:
--------------------------------------------------------------------------------
1 | #ifndef __texture2d_f__
2 | #define __texture2d_f__
3 |
4 | static unsigned int size_texture2d_f = 220;
5 | static unsigned char texture2d_f[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0xdc, 0x00, 0x00, 0x00, 0x4d, 0xd2, 0xb7, 0x2a,
7 | 0x96, 0xfd, 0xd1, 0x0f, 0x01, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00, 0x00,
10 | 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x74, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
13 | 0x00, 0x00, 0x00, 0x00, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00,
15 | 0x00, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x01, 0x04, 0x01, 0x00, 0x01, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0xf9, 0x00, 0x00,
17 | 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
18 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x44, 0xfa, 0x10, 0x00, 0x00, 0x00, 0x02, 0x04, 0x02, 0x00,
19 | 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x74, 0x65, 0x78, 0x00,
20 | };
21 |
22 | #endif
23 |
--------------------------------------------------------------------------------
/shaders/texture2d_v.h:
--------------------------------------------------------------------------------
1 | #ifndef __texture2d_v__
2 | #define __texture2d_v__
3 |
4 | static unsigned int size_texture2d_v = 308;
5 | static unsigned char texture2d_v[] __attribute__((aligned(16))) = {
6 | 0x47, 0x58, 0x50, 0x00, 0x01, 0x04, 0x00, 0x00, 0x32, 0x01, 0x00, 0x00, 0xca, 0x4a, 0xa2, 0x5f,
7 | 0x6d, 0x88, 0xbe, 0xd9, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00,
8 | 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xc4, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
9 | 0x08, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x05, 0x00, 0x00, 0x00,
10 | 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00,
11 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
12 | 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00,
13 | 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00,
14 | 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00,
15 | 0x01, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x37, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
16 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x06, 0x01, 0x00, 0x00, 0x00,
17 | 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
18 | 0x00, 0x07, 0x44, 0xfa, 0x80, 0x00, 0x08, 0x83, 0x21, 0x0d, 0x80, 0x38, 0x02, 0x80, 0x81, 0xaf,
19 | 0x9c, 0x0d, 0x80, 0x40, 0x00, 0xa2, 0x3d, 0xc0, 0x81, 0x30, 0x90, 0x18, 0x00, 0x00, 0x20, 0xa0,
20 | 0x00, 0x50, 0x27, 0xfb, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x30, 0x00, 0x00, 0x00,
21 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x29, 0x00, 0x00, 0x00,
22 | 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x22, 0x00, 0x00, 0x00,
23 | 0x01, 0xe4, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x6f, 0x73, 0x69,
24 | 0x74, 0x69, 0x6f, 0x6e, 0x00, 0x74, 0x65, 0x78, 0x63, 0x6f, 0x6f, 0x72, 0x64, 0x00, 0x77, 0x76,
25 | 0x70, 0x00, 0x00, 0x00,
26 | };
27 |
28 | #endif
29 |
--------------------------------------------------------------------------------