From 54f44439715975d5b6e6e15ad7bad5c20ae625ef Mon Sep 17 00:00:00 2001 From: Jules Blok Date: Sat, 2 May 2015 12:10:40 +0200 Subject: VideoCommon: Implement EFB dumping for both backends. --- Source/Core/VideoCommon/TextureCacheBase.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'Source/Core/VideoCommon/TextureCacheBase.cpp') diff --git a/Source/Core/VideoCommon/TextureCacheBase.cpp b/Source/Core/VideoCommon/TextureCacheBase.cpp index 53168f45e7..251ee54783 100644 --- a/Source/Core/VideoCommon/TextureCacheBase.cpp +++ b/Source/Core/VideoCommon/TextureCacheBase.cpp @@ -873,6 +873,13 @@ void TextureCache::CopyRenderTargetToTexture(u32 dstAddr, unsigned int dstFormat entry->FromRenderTarget(dstAddr, dstFormat, srcFormat, srcRect, isIntensity, scaleByHalf, cbufid, colmat); + if (g_ActiveConfig.bDumpEFBTarget) + { + static int count = 0; + entry->Save(StringFromFormat("%sefb_frame_%i.png", File::GetUserPath(D_DUMPTEXTURES_IDX).c_str(), + count++), 0); + } + textures.insert(TexCache::value_type(dstAddr, entry)); } -- cgit v1.2.3