diff --git a/Source/Plugins/Plugin_VideoDX9/Src/Render.cpp b/Source/Plugins/Plugin_VideoDX9/Src/Render.cpp index b49a9734e0..ad42d6bdb5 100644 --- a/Source/Plugins/Plugin_VideoDX9/Src/Render.cpp +++ b/Source/Plugins/Plugin_VideoDX9/Src/Render.cpp @@ -570,15 +570,17 @@ extern volatile u32 s_swapRequested; void Renderer::RenderToXFB(u32 xfbAddr, u32 fbWidth, u32 fbHeight, const EFBRectangle& sourceRc) { - VideoFifo_CheckEFBAccess(); - XFBWrited = true; if(!fbWidth || !fbHeight) return; + VideoFifo_CheckEFBAccess(); // If we're about to write to a requested XFB, make sure the previous // contents make it to the screen first. - VideoFifo_CheckSwapRequestAt(xfbAddr, fbWidth, fbHeight); + if (g_ActiveConfig.bUseXFB) + { + VideoFifo_CheckSwapRequestAt(xfbAddr, fbWidth, fbHeight); + } FBManager.CopyToXFB(xfbAddr, fbWidth, fbHeight, sourceRc); - + XFBWrited = true; // XXX: Without the VI, how would we know what kind of field this is? So // just use progressive. if (!g_ActiveConfig.bUseXFB) @@ -1291,6 +1293,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight) } D3D::dev->SetRenderTarget(0, FBManager.GetEFBColorRTSurface()); D3D::dev->SetDepthStencilSurface(FBManager.GetEFBDepthRTSurface()); + } // --------------------------------------------------------------------- @@ -1318,6 +1321,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight) D3D::dev->SetDepthStencilSurface(FBManager.GetEFBDepthRTSurface()); UpdateViewport(); VertexShaderManager::SetViewportChanged(); + g_VideoInitialize.pCopiedToXFB(false); XFBWrited = false; } diff --git a/Source/Plugins/Plugin_VideoDX9/Src/main.cpp b/Source/Plugins/Plugin_VideoDX9/Src/main.cpp index baf80d76ac..2bc3b44edc 100644 --- a/Source/Plugins/Plugin_VideoDX9/Src/main.cpp +++ b/Source/Plugins/Plugin_VideoDX9/Src/main.cpp @@ -356,7 +356,7 @@ void VideoFifo_CheckSwapRequestAt(u32 xfbAddr, u32 fbWidth, u32 fbHeight) // Run from the CPU thread (from VideoInterface.cpp) void Video_BeginField(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight) { - if (s_PluginInitialized) + if (s_PluginInitialized && g_ActiveConfig.bUseXFB) { // Make sure previous swap request has made it to the screen if (g_VideoInitialize.bOnThread)