feat: Add frame generation and enhance UE4 game compatibility

- Add frame generation settings (enabled/disabled, interpolation/extrapolation modes)
- Add frame skipping settings (enabled/disabled, adaptive/fixed modes)
- Implement frame skipping logic with adaptive and fixed modes
- Enhance UE4 crash handling with recovery mechanisms
- Add support for signed and float 32-bit image formats across shader backends
- Update Vulkan Validation Layers to v1.4.321.0
- Fix duplicate frame skipping options in Qt UI
- Improve memory handling for UE4 games (Hogwarts Legacy compatibility)
- Add enhanced bindless texture handling with fallback approach
- Update Android build configuration and dependencies

Signed-off-by: Zephyron <zephyron@citron-emu.org>
This commit is contained in:
Zephyron
2025-08-05 19:32:28 +10:00
parent 011a546229
commit 117c467ff3
40 changed files with 1004 additions and 76 deletions

View File

@@ -710,7 +710,20 @@ struct Memory::Impl {
return GetPointerImpl(
GetInteger(vaddr),
[vaddr]() {
LOG_ERROR(HW_Memory, "Unmapped GetPointer @ 0x{:016X}", GetInteger(vaddr));
// Enhanced unmapped memory handling
const u64 addr = GetInteger(vaddr);
// Check if this is a very low address
if (addr < 0x1000) {
LOG_WARNING(HW_Memory, "UE4-style low address read detected @ 0x{:016X}, returning 0 for stability",
addr);
// For UE4 games, we'll return 0 for these reads to prevent crashes
// This is a common pattern in UE4 games where they read from low addresses
return;
}
LOG_ERROR(HW_Memory, "Unmapped Read{} @ 0x{:016X}", sizeof(u8) * 8,
GetInteger(vaddr));
},
[]() {});
}
@@ -737,6 +750,18 @@ struct Memory::Impl {
const u8* const ptr = GetPointerImpl(
GetInteger(vaddr),
[vaddr]() {
// Enhanced unmapped memory handling
const u64 addr = GetInteger(vaddr);
// Check if this is a very low address
if (addr < 0x1000) {
LOG_WARNING(HW_Memory, "UE4-style low address read detected @ 0x{:016X}, returning 0 for stability",
addr);
// For UE4 games, we'll return 0 for these reads to prevent crashes
// This is a common pattern in UE4 games where they read from low addresses
return;
}
LOG_ERROR(HW_Memory, "Unmapped Read{} @ 0x{:016X}", sizeof(T) * 8,
GetInteger(vaddr));
},
@@ -761,6 +786,18 @@ struct Memory::Impl {
u8* const ptr = GetPointerImpl(
GetInteger(vaddr),
[vaddr, data]() {
// Enhanced unmapped memory handling for UE4 games like Hogwarts Legacy
const u64 addr = GetInteger(vaddr);
// Check if this is a very low address that might be used by UE4
if (addr < 0x1000) {
LOG_WARNING(HW_Memory, "UE4-style low address write detected @ 0x{:016X} = 0x{:016X}, ignoring for stability",
addr, static_cast<u64>(data));
// For UE4 games, we'll ignore these writes to prevent crashes
// This is a common pattern in UE4 games where they write to low addresses
return;
}
LOG_ERROR(HW_Memory, "Unmapped Write{} @ 0x{:016X} = 0x{:016X}", sizeof(T) * 8,
GetInteger(vaddr), static_cast<u64>(data));
},