Changes

Jump to navigation Jump to search
1,108 bytes added ,  22:01, 13 September 2015
Created page with "During system boot, the system-font is loaded by NS to LINEAR-memory(in the original 0x14000000 vmem region) which always gets allocated at SYSTEM_memregion+0. Due to it bein..."
During system boot, the system-font is loaded by [[NS]] to LINEAR-memory(in the original 0x14000000 vmem region) which always gets allocated at SYSTEM_memregion+0. Due to it being located there, all of this is GPU accessible. The [[BCFNT]] is loaded from the font title for the system region into that memory. During loading, the font-data is modified: the magic-num at fontdata+0 is changed from "CFNT" to "CFNU", and all file offsets are converted to addresses in this allocated linearmem. Processes can get the sharedmem_handle+vaddr for mapping the sharedmem for this via [[NS and APT Services|APT:GetSharedFont]].

Shared mem structure:
{| class="wikitable" border="1"
|-
! Offset
! Size
! Description
|-
| 0x0
| 0x80
| Header
|-
| 0x80
| Font data size
| The actual font data. There's also unknown data following the original decompressed font data.
|}

Header structure:
{| class="wikitable" border="1"
|-
! Offset
! Size
! Description
|-
| 0x0
| 0x4
| Normally value 0x2?
|-
| 0x4
| 0x4
| Normally value 0x1?
|-
| 0x8
| 0x4
| Decompressed font data size.
|-
| 0xC
| 0x34
| Normally all-zero?
|}

Navigation menu