mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-07-11 01:25:07 +02:00
Remove compat flag AllowDelayedReadback
This commit is contained in:
@@ -142,7 +142,6 @@ void Compatibility::CheckSettings(IniFile &iniFile, const std::string &gameID) {
|
||||
CheckSetting(iniFile, gameID, "Fontltn12Hack", &flags_.Fontltn12Hack);
|
||||
CheckSetting(iniFile, gameID, "LoadCLUTFromCurrentFrameOnly", &flags_.LoadCLUTFromCurrentFrameOnly);
|
||||
CheckSetting(iniFile, gameID, "ForceUMDReadSpeed", &flags_.ForceUMDReadSpeed);
|
||||
CheckSetting(iniFile, gameID, "AllowDelayedReadbacks", &flags_.AllowDelayedReadbacks);
|
||||
CheckSetting(iniFile, gameID, "KernelGetSystemTimeLowEatMoreCycles", &flags_.KernelGetSystemTimeLowEatMoreCycles);
|
||||
CheckSetting(iniFile, gameID, "TacticsOgreEliminateDebugReadback", &flags_.TacticsOgreEliminateDebugReadback);
|
||||
CheckSetting(iniFile, gameID, "FramebufferAllowLargeVerticalOffset", &flags_.FramebufferAllowLargeVerticalOffset);
|
||||
|
||||
@@ -105,7 +105,6 @@ struct CompatFlags {
|
||||
bool Fontltn12Hack;
|
||||
bool LoadCLUTFromCurrentFrameOnly;
|
||||
bool ForceUMDReadSpeed;
|
||||
bool AllowDelayedReadbacks;
|
||||
bool KernelGetSystemTimeLowEatMoreCycles;
|
||||
bool TacticsOgreEliminateDebugReadback;
|
||||
bool FramebufferAllowLargeVerticalOffset;
|
||||
|
||||
@@ -215,9 +215,6 @@ bool FramebufferManagerCommon::ReadbackDepthbuffer(Draw::Framebuffer *fbo, int x
|
||||
|
||||
DepthUB ub{};
|
||||
|
||||
// Setting this to 0.95f eliminates flickering lights with delayed readback in Syphon Filter.
|
||||
// That's pretty ugly though! But we'll need to do that if we're gonna enable delayed readback in those games.
|
||||
const float fudgeFactor = 1.0f;
|
||||
DepthScaleFactors depthScale = GetDepthScaleFactors(gstate_c.UseFlags());
|
||||
ub.u_depthFactor[0] = depthScale.Offset();
|
||||
ub.u_depthFactor[1] = depthScale.Scale();
|
||||
@@ -232,9 +229,9 @@ bool FramebufferManagerCommon::ReadbackDepthbuffer(Draw::Framebuffer *fbo, int x
|
||||
|
||||
// Fullscreen triangle coordinates.
|
||||
static const float positions[6] = {
|
||||
0.0, 0.0,
|
||||
1.0, 0.0,
|
||||
0.0, 1.0,
|
||||
0.0f, 0.0f,
|
||||
1.0f, 0.0f,
|
||||
0.0f, 1.0f,
|
||||
};
|
||||
draw_->DrawUP(positions, 3);
|
||||
|
||||
|
||||
@@ -1064,7 +1064,7 @@ bool FramebufferManagerCommon::ShouldDownloadFramebufferColor(const VirtualFrame
|
||||
}
|
||||
|
||||
bool FramebufferManagerCommon::ShouldDownloadFramebufferDepth(const VirtualFramebuffer *vfb) {
|
||||
// Download depth buffer for Syphon Filter lens flares
|
||||
// Download depth buffer if compat flag set (previously used for Syphon Filter lens flares, now used for nothing)
|
||||
if (!PSP_CoreParameter().compat.flags().ReadbackDepth || GetSkipGPUReadbackMode() != SkipGPUReadbackMode::NO_SKIP) {
|
||||
return false;
|
||||
}
|
||||
@@ -1074,6 +1074,7 @@ bool FramebufferManagerCommon::ShouldDownloadFramebufferDepth(const VirtualFrame
|
||||
void FramebufferManagerCommon::NotifyRenderFramebufferSwitched(VirtualFramebuffer *prevVfb, VirtualFramebuffer *vfb, bool isClearingDepth) {
|
||||
if (prevVfb) {
|
||||
if (ShouldDownloadFramebufferColor(prevVfb) && !prevVfb->memoryUpdated) {
|
||||
// NOTE: This path is ONLY for the Dangan Ronpa hack, see ShouldDownloadFramebufferColor
|
||||
ReadFramebufferToMemory(prevVfb, 0, 0, prevVfb->width, prevVfb->height, RASTER_COLOR, Draw::ReadbackMode::OLD_DATA_OK);
|
||||
prevVfb->usageFlags = (prevVfb->usageFlags | FB_USAGE_DOWNLOAD | FB_USAGE_FIRST_FRAME_SAVED) & ~FB_USAGE_DOWNLOAD_CLEAR;
|
||||
} else {
|
||||
@@ -2192,11 +2193,7 @@ bool FramebufferManagerCommon::NotifyFramebufferCopy(u32 src, u32 dst, int size,
|
||||
if (srcH == 0 || srcY + srcH > srcBuffer->bufferHeight) {
|
||||
WARN_LOG_ONCE(btdcpyheight, Log::FrameBuf, "Memcpy fbo download %08x -> %08x skipped, %d+%d is taller than %d", src, dst, srcY, srcH, srcBuffer->bufferHeight);
|
||||
} else if (GetSkipGPUReadbackMode() == SkipGPUReadbackMode::NO_SKIP && (!srcBuffer->memoryUpdated || channel == RASTER_DEPTH)) {
|
||||
Draw::ReadbackMode readbackMode = Draw::ReadbackMode::BLOCK;
|
||||
if (PSP_CoreParameter().compat.flags().AllowDelayedReadbacks) {
|
||||
readbackMode = Draw::ReadbackMode::OLD_DATA_OK;
|
||||
}
|
||||
ReadFramebufferToMemory(srcBuffer, 0, srcY, srcBuffer->width, srcH, channel, readbackMode);
|
||||
ReadFramebufferToMemory(srcBuffer, 0, srcY, srcBuffer->width, srcH, channel, Draw::ReadbackMode::BLOCK);
|
||||
srcBuffer->usageFlags = (srcBuffer->usageFlags | FB_USAGE_DOWNLOAD) & ~FB_USAGE_DOWNLOAD_CLEAR;
|
||||
}
|
||||
return false;
|
||||
@@ -2743,11 +2740,7 @@ bool FramebufferManagerCommon::NotifyBlockTransferBefore(u32 dstBasePtr, int dst
|
||||
if (tooTall) {
|
||||
WARN_LOG_ONCE(btdheight, Log::G3D, "Block transfer download %08x -> %08x dangerous, %d+%d is taller than %d", srcBasePtr, dstBasePtr, srcRect.y, srcRect.h, srcRect.vfb->bufferHeight);
|
||||
}
|
||||
Draw::ReadbackMode readbackMode = Draw::ReadbackMode::BLOCK;
|
||||
if (PSP_CoreParameter().compat.flags().AllowDelayedReadbacks) {
|
||||
readbackMode = Draw::ReadbackMode::OLD_DATA_OK;
|
||||
}
|
||||
ReadFramebufferToMemory(srcRect.vfb, static_cast<int>(srcX * srcXFactor), srcY, static_cast<int>(srcRect.w_bytes * srcXFactor), srcRect.h, RASTER_COLOR, readbackMode);
|
||||
ReadFramebufferToMemory(srcRect.vfb, static_cast<int>(srcX * srcXFactor), srcY, static_cast<int>(srcRect.w_bytes * srcXFactor), srcRect.h, RASTER_COLOR, Draw::ReadbackMode::BLOCK);
|
||||
srcRect.vfb->usageFlags = (srcRect.vfb->usageFlags | FB_USAGE_DOWNLOAD) & ~FB_USAGE_DOWNLOAD_CLEAR;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1681,9 +1681,6 @@ UCAS40289 = true
|
||||
NPUH10025 = true
|
||||
NPEH00047 = true
|
||||
|
||||
[ReadbackDepth]
|
||||
# Obsolete, SoftwareRasterDepth is a far better solution.
|
||||
|
||||
[BlockTransferDepth]
|
||||
# Iron Man - see issue #16530
|
||||
# Note that this option also requires IntraVRAMBlockTransferAllowCreateFB.
|
||||
@@ -1811,12 +1808,6 @@ UCKS45110 = true
|
||||
ULJS19044 = true
|
||||
NPJH50852 = true
|
||||
|
||||
[AllowDelayedReadbacks]
|
||||
# NOTE: This only affects Vulkan currently.
|
||||
# Added for easy experimentation. Many games using readbacks do not work well delaying them, though.
|
||||
# For example, Motorstorm lighting adaptation goes into self-oscillation (!)
|
||||
# UCES01250 = true
|
||||
|
||||
[TacticsOgreEliminateDebugReadback]
|
||||
ULUS10565 = true
|
||||
ULES01500 = true
|
||||
|
||||
Reference in New Issue
Block a user