mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-06-03 12:27:21 +12:00
[APT] Add shared font
This commit is contained in:
parent
c8a4c7d7fa
commit
cad046d9a8
7 changed files with 262187 additions and 14 deletions
|
@ -77,7 +77,13 @@ public:
|
|||
}
|
||||
|
||||
void ExceptionRaised(u32 pc, Dynarmic::A32::Exception exception) override {
|
||||
Helpers::panic("Fired exception oops");
|
||||
switch (exception) {
|
||||
case Dynarmic::A32::Exception::UnpredictableInstruction:
|
||||
Helpers::panic("Unpredictable instruction at pc = %08X", pc);
|
||||
break;
|
||||
|
||||
default: Helpers::panic("Fired exception oops");
|
||||
}
|
||||
}
|
||||
|
||||
void AddTicks(u64 ticks) override {
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
#include "helpers.hpp"
|
||||
#include "handles.hpp"
|
||||
#include "loader/ncsd.hpp"
|
||||
#include "services/shared_font.hpp"
|
||||
|
||||
namespace PhysicalAddrs {
|
||||
enum : u32 {
|
||||
|
@ -104,10 +105,11 @@ class Memory {
|
|||
// This tracks our OS' memory allocations
|
||||
std::vector<KernelMemoryTypes::MemoryInfo> memoryInfo;
|
||||
|
||||
std::array<SharedMemoryBlock, 2> sharedMemBlocks = {
|
||||
std::array<SharedMemoryBlock, 3> sharedMemBlocks = {
|
||||
SharedMemoryBlock(0, _shared_font_len, KernelHandles::FontSharedMemHandle), // Shared memory for the system font
|
||||
SharedMemoryBlock(0, 0x1000, KernelHandles::GSPSharedMemHandle), // GSP shared memory
|
||||
SharedMemoryBlock(0, 0x1000, KernelHandles::HIDSharedMemHandle) // HID shared memory
|
||||
};
|
||||
};
|
||||
|
||||
static constexpr u32 pageShift = 12;
|
||||
static constexpr u32 pageSize = 1 << pageShift;
|
||||
|
|
5
include/services/shared_font.hpp
Normal file
5
include/services/shared_font.hpp
Normal file
|
@ -0,0 +1,5 @@
|
|||
#pragma once
|
||||
#include <cstddef>
|
||||
|
||||
extern unsigned char _shared_font_bin[];
|
||||
extern size_t _shared_font_len;
|
Loading…
Add table
Add a link
Reference in a new issue