mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-07 14:45:41 +12:00
Better VRAM handling
This commit is contained in:
parent
80f1de728c
commit
950e5da03a
1 changed files with 7 additions and 2 deletions
|
@ -152,8 +152,13 @@ u32 Memory::read32(u32 vaddr) {
|
|||
|
||||
default:
|
||||
if (vaddr >= VirtualAddrs::VramStart && vaddr < VirtualAddrs::VramStart + VirtualAddrs::VramSize) {
|
||||
Helpers::warn("VRAM read!\n");
|
||||
return 0;
|
||||
static int shutUpCounter = 0;
|
||||
if (shutUpCounter < 5) { // Stop spamming about VRAM reads after the first 5
|
||||
Helpers::warn("VRAM read!\n");
|
||||
}
|
||||
|
||||
// TODO: Properly handle framebuffer readbacks and the like
|
||||
return *(u32*)&vram[vaddr - VirtualAddrs::VramStart];
|
||||
}
|
||||
|
||||
Helpers::panic("Unimplemented 32-bit read, addr: %08X", vaddr);
|
||||
|
|
Loading…
Add table
Reference in a new issue