Icon.bin: Difference between revisions
Some fixes |
|||
| (4 intermediate revisions by 4 users not shown) | |||
| Line 7: | Line 7: | ||
[[Image:icon_5.gif]] | [[Image:icon_5.gif]] | ||
These are converted by a tool | These are converted by a tool blasty wrote. Icon files were supplied by loopy. | ||
== Basic File Structure == | == Basic File Structure == | ||
| Line 17: | Line 17: | ||
|- | |- | ||
| 0x0000 | | 0x0000 | ||
| | | 1 | ||
| | | Number of titles (5+N) | ||
|- | |||
| 0x0001 | |||
| 1 | |||
| Animated (1=contains animated icon at 0x1240) | |||
|- | |- | ||
| 0x0002 | | 0x0002 | ||
| 2*4 | | 2*4 | ||
| 4 CRC checksums ( | | 4 CRC checksums (polynomial 0xA001) | ||
|- | |- | ||
| 0x000A | | 0x000A | ||
| Line 37: | Line 41: | ||
|- | |- | ||
| 0x0240 | | 0x0240 | ||
| 256* | | 256*16 | ||
| Application | | Application Titles, wide chars | ||
|- | |- | ||
| 0x1240 | | 0x1240 | ||
| Line 56: | Line 56: | ||
| Animation Sequence | | Animation Sequence | ||
|} | |} | ||
Languages (in correct order) are: Japanese, English, French, German, Italian, Spanish, | Languages (in correct order) are: Japanese, English, French, German, Italian, Spanish, ?Chinese?, Korean. | ||
== Animation Sequence == | == Animation Sequence == | ||
| Line 95: | Line 95: | ||
The conversion to RGB888 is made like this (C): | The conversion to RGB888 is made like this (C): | ||
<source lang="c"> | |||
u8 r = ((color ) & 0x1f)<<3; | u8 r = ((color ) & 0x1f)<<3; | ||
u8 g = ((color >> 5) & 0x1f)<<3; | u8 g = ((color >> 5) & 0x1f)<<3; | ||
u8 b = ((color >> 10) & 0x1f)<<3; | u8 b = ((color >> 10) & 0x1f)<<3; | ||
</source> | |||
== Checksums == | == Checksums == | ||
The CRC-output is not bitwise inverted after the calculation, but it is byte-swapped to big-endian. | The CRC-output is not bitwise inverted after the calculation, but it is byte-swapped to big-endian. Polynomial used is: 0xA001, same for all. | ||
{| class="wikitable" | {| class="wikitable" | ||